As with all agents, HTTP agents are configured in agentsConfig.xml - its default settings are specified in the <ActionAgent> section and generally do not need to be changed.
File format
Create the <DMSRoot>/apps/<application ID>/ HTTPagent.xml file in the Admin Server agent directory.
A sample file is displayed below
<HTTPAgent> <HTTPBaseURL method="POST" followRedirects="true">{{Field HTTP_URL}}</HTTPBaseURL> <va name="Content-Type">text/xml; charset=UTF-8</HTTPHeaderParams> <HTTPHeaderParams name="User-Agent">I- HTTP Agent </HTTPHeaderParams> <HTTPHeaderParams name="accept-charset">UTF-8 </HTTPHeaderParams> <QueryParams name= "ParamName"> Param value</QueryParams> <HTTPRequestUDA>HTTP_REQUEST</HTTPRequestUDA> <HTTPResponseUDA>HTTP_RESPONSE</HTTPResponseUDA> <HTTPAgentStatusUDA>HTTP_STATUS</HTTPAgentStatusUDA> </HTTPAgent>
The table below describes the tags:
Item | Description |
---|---|
<HTTPBaseURL> | URL end point invoked by the HTTP agent. This tag specifies a servlet or other external service. Attributes:
|
<HTTPHeaderParams> | Specifies HTTP header properties such as the encoding style and contents type. HTTP headers are used to define various Web object properties, such as request and response object properties for the current HTTP session, for example. Attributes:
|
<QueryParams> | Value passed to external services as the query string (this tag is required if the HTTP agent uses the "GET" method). Note that the UDA value specified in <HTTPRequestUDA> is not used if the "GET" method is used. This tag's syntax is as follows:
During execution of the HTTP agent, this is converted to:
Any valid string can be specified as the name attribute. |
<HTTPRequestUDA> | UDA which value will be part of the HTTP request query string. Note that the value of the specified UDA is not used if the "GET" method is used. |
<HTTPAgentStatusUDA> | UDA that saves the status of the HTTP service. |
<HTTPResponseUDA> | UDA that saves HTTP responses. |