Syntax FACTORY_DEF HTTPFactory [FACTORY_NAME ] [INPUT FEATURE_TYPE [ ]* []*]* [TARGET_URL ] [SAVE_FILE ] [OUTPUT_FILENAME ] [TARGET_ATTR ] [HTTP_METHOD ] [UPLOAD_FILE ] [UPLOAD_BODY ] [UPLOAD_CONTENT_TYPE ] [REQUEST_HEADER ]* [AUTH_USERNAME ] [AUTH_PASSWORD ] [AUTH_METHOD ] [SINGLE_SIGN_ON ] [PROXY_URL ] [PROXY_PORT ] [PROXY_USERNAME ] [PROXY_PASSWORD ] [PROXY_AUTH_METHOD ] [TARGET_ATTRIBUTE_ENCODING ||] [RESPONSE_HEADER_LIST_ATTR ] [STATUS_CODE_ATTR ] [ERROR_ATTR ] [USE_COOKIES ] [CONNECTION_TIMEOUT_LENGTH |0] [TRANSFER_TIMEOUT_LENGTH |0] [OUTPUT (OUTPUT|) FEATURE_TYPE [ ]* []*]* Overview Performs an HTTP request on the target URL using either GET, DELETE, POST, or PUT. Currently, only the HTTP GET, POST, DELETE, and PUT operations are available. Other HTTP operations are unsupported at this time. Specifying GET or DELETE will perform the associated operation on the URL and store the results in the target attribute. Specifying POST or PUT will upload the associated message or file as specified and store the results in the target attribute. The HTTP Response status code will be stored in a separate _http_status_code attribute. Any errors that cause the feature's request to fail, will set an attribute on the feature which contains the appropriate error message. If SAVE_FILE is set to Yes, then the HTTP response body will be saved to a temporary file, if OUTPUT_FILENAME is empty, or the file specified by OUTPUT_FILENAME if it is not empty. The filename will populate the TARGET_ATTR attribute, instead of the contents. This is useful to enable when large transfers are being used. The HTTP basic access authentication is supported for servers requiring credentials. The username, password and authentication method may be specified via the HTTP_USERNAME, HTTP_PASSWORD, and HTTP_AUTHMETHOD, respectively. Single sign on is currently unsupported. Custom request headers should follow the REQUEST_HEADER tag, enclosed in quotations. Each header should be separate, following its own REQUEST_HEADER tag. Using key-value pairs, the request header can be set and the response header is stored in the attribute following RESPONSE_HEADER_LIST_ATTR. To specify a file or message for upload, the appropriate fields must be completed. One of either a file or a message can be uploaded per feature. If a file is specified, it becomes the body of the HTTP request sent to the server. The content type provided will override the Content-Type header, regardless if one was provided as a custom header. Multipart uploads are not supported at this time. The TARGET_ATTRIBUTE_ENCODING clause indicates which character encoding the response attribute should be tagged with. If it is set to an empty string, the response attribute will be in the system default encoding. If it is set to auto-detect, the factory will examine the HTTP response headers for an encoding to use. If there is no encoding in the headers, the attribute will be in the 'binary' encoding. The clause may also name an encoding for the response attribute. If the USE_COOKIES parameter is set to YES, then any previously saved cookies whose domain matches that of the requested URL will be sent along with the request. Also, any cookies contained in the response to this request will be saved for sending later. This allows the HTTPFactory to access web resources which have session management. The factory can be used to perform a 'login' or authentication request, and then used again to perform another request which requires the authenticated session id, which is typically stored in a cookie. Output Tags The HTTPFactory supports the following output tags. OUTPUT Successful features that did not produce errors when attempting the request. Invalid requests.