HTTP adapter request and response for a POST action

The POST operation sends data to a specified URL. The adapter request with a POST action uses the following formats:

  • Single element
  • Parent and child
  • Entry, key-value

When you use a context item as an input for an adapter request, you must enclose the adapter request in the<request-data> elements. However, when you create a static request, <request-data> is not required and the adapter request starts with the <httpadapterrequest> element. 

You can also upload multiple files and data by using the multipart/form-data specified in the <Content-Type> element in the the HTTP request header.

The following table describes the elements of an HTTP adapter request with a POST action.

Use the adapter request XML when you create a custom process by using the Call Adapter activity in TrueSight Orchestration Development Studio.

Elements of an HTTP adapter request with a POST action

Element

Description

Required

<adapter-name>

Specifies the name of the adapter to be used for this request

Default value: HTTPAdapter

No
<action>Specifies the URL of the content to be sentYes

<use-ssl-certificate>

Specifies whether to establish a secure connection 

Set the value of this element to true when <action> uses HTTPS. 

Set the value of this element to false or leave it blank when<action> uses HTTP. 

Valid values: true, false (default)

No

<install-certificate>

Specifies whether to install certificates 

Set the value of this element to true if you prefer to have security certificates installed automatically (a common practice). 

Set the value of this element to false if you prefer to manually export the security certificate from the specified target server and manually import it into the TrueSight Orchestration's local peer's cacerts file (a rare practice). 

Valid values: true, false (default)

No

<allow-unsigned-certificate>

Specifies whether to allow unsigned certificates from trusted zones 

Set the value of this element to true, if you are using self-signed SSL certificates (a common practice). 

On ecommerce sites or military installations, if you need to use signed certificates such as Verisign or Thawte, set the value of this element to false (a rare practice). 

Valid values: true, false (default)

No

<passphrase>

Specifies the Java Standard Trust Key Store passphrase

Warning

  • The value of the <passphrase> element is the passphrase for the cacerts certificate stored on the TrueSight Orchestration local peer (CDP or AP) and not the specified target host.
  • Changing the passphrase can be tricky and might destroy the cacerts security file integrity.

Verify the cacerts passphrase using the following command in UNIX or Linux: 

$ /opt/bmc/ao/cdp/jvm/bin/keytool -list -keystore 
/opt/bmc/ao/cdp/jvm/lib/security/cacerts 

Default value: changeit

No

<data-format>

Indicates the data type for the adapter response 

The JSON string in the response is parsed to XML only if <Content-Type> is set to application/json and <data-format> is set to XML. 

Valid values: XML, HTML (default)

No

<user name>

Specifies the user name to be used for basic authentication

No

<password>

Specifies the password corresponding to the user name provided for basic authentication

No

<http-connection-properties>

Specifies an XML document that includes HTTP connection properties, which contain the <user-name> and <password> elements for basic or NTLM authentication 

The XML document also includes information such as <content-type> in the HTTP request header before executing the HTTP request. 

Example
<http-connection-properties>
   <Content-Type>text/html</Content-Type>
   <Accept>Yes</Accept>
   <Blob></Blob> 
</http-connection-properties>


Example for multiple file upload
<http-connection-properties>
   <Content-Type>multipart/form-data</Content-Type>
</http-connection-properties>

Note: The user name and password properties are not set in the request header and are case sensitive.

Conditional; required if you want to send multiple files in the request. Specify <Content-Type> as multipart/form-data in the HTTP request header.

<user-name>

Specifies the user name required for basic or NTLM authentication specified in <http-connection-properties>

No

<password>

Specifies the password corresponding to the user name specified in <http-connection-properties>

No

<data>

Contains the data to be posted 

Data can be used in three ways:

  • Simple text form
  • Parent and child format
  • Key and entry format

Note: When you specify the <Content-Type> as multipart/form-data in the HTTP request header, you must specify at least one <entry> for the request.

NEW IN 20.19.01 For a multipart/form-data request, you can specify the content type as application/json in the request body.

For a sample adapter request, see Sample adapter request for a multipart/form-data request when the content-type is application/json.

Yes

<character-set>

Specifies the supporting CharSet 

Also called character set, it includes identifiers describing a series of universal characters. 

Note: If you do not specify the supporting character set, the adapter response is parsed based on the character set in the HTTP response header.

No

<signature-properties>

Contains the elements that specify information about the public key (X.509 certificate) and the private key that are used for the digital signature 

Note: If you specify <signature-properties> in the adapter configuration and an adapter request, the values in the request override the values in the configuration. 
The <signature-properties> element can contain the modeattribute that specifies the format in which the public (X.509 certificate) and private keys are provided for signing the HTTP request. 

You can provide the keys using one of the following formats:

  • Java Keystore (JKS)
  • Privacy Enhanced Mail (PEM)
  • Definite Encoding Rules (DER) files
  • Base64-encoded PEM 

    Valid values:
  • <signature-properties mode="keystore"> (default)
  • <signature-properties mode="key-files">
  • <signature-properties mode="key-data">

No

<file-path>

Specifies the file name and local path of the file to be sent to the URL 

Examples: 
For Windows:

C:\\adapters\\testfile.txt


For UNIX or Solaris: //home//user//testfile.txt

No

<file-content-type>

Specifies the content type of the file to be uploaded 

Valid values:

For text: text\plain

For files: application/octet-stream (Required for using multipart/form-data for sending multiple files over the adapter request)

Conditional; used if the adapter request contains a <file-path> element

<ntlm-authentication>

Indicates whether to use NTLM authentication for the target server for the specified user credentials 

The adapter supports both NTLMv1 and NTLMv2 authentication. 

Valid values: true, false (default) 

If the value of the parameter is true, the adapter uses NTLMv1 or NTLMv2 authentication (based on the server configuration) to authenticate the user. Else, the adapter uses basic authentication.

No

<private-key-file>

Specifies the file containing the private key that is used to sign the HTTP request 

The adapter supports the following formats:

  • Base64-encoded PEM
  • DER

Conditional; required when <signature-properties mode="key-files">

<certificate-file>

Specifies the file containing the public key (X509 Certificate) 

The adapter supports the following formats:

  • Base64-encoded PEM
  • DER

Conditional; required when <signature-properties mode="key-files">

<private-key-data>

Contains an XML file specifying the private key in an Base64-encoded PEM format 

For example: 
<private-key-data> --- BEGIN PRIVATE KEY ---- 
MIICdQIBADANBgkqhkiG9w0 
BAQEFAASCAl8wggJbAgEAAo 
GBAKomKro6VbW4PeQtUhNz 
ZpSH26vbBTBtH1r4EjnIv4vnh 
SyyA62ewpROVNn0Spvjo 
BFwE88HcX3tXym/zbVgtd 
Pke9K+SYHP6CWdiLqn 
... 
--- END PRIVATE KEY ---</private-key-data>

Conditional; required when <signature-properties mode="key-data">

<certificate-data>

Contains an XML file specifying the public key (X509 Certificate) in an Base64-encoded PEM format 

For example: 
<certificate-data> --- BEGIN CERTIFICATE --- 
MIICdzCCAeCgAwIBAgIFXseN1xYwDQYJKoZIhvcNAQEFBQ 
AwUzELMAkGA1UEBhMCVVMxEzARBgNVBAoTCkFtYXpvbi5jb20x 
DDAKBgNVBAsTA0FXUzEhMB8GA1UEAxMY 
... 
--- END CERTIFICATE ---</certificate-data>

Conditional; required when <signature-properties mode="key-data">

<keystore-file>

Specifies the path to the JKS that contains the client certificate

Conditional; required when <signature-properties mode="keystore">

<key-password>

Specifies the password of the key contained in the JKS 

Note: If you do not specify <key-password>, then the value of<keystore-password> is used as the key password.

No

<keystore-password>

Specifies the password to the JKS

Conditional; required when <signature-properties mode="keystore">

<alias>

Specifies the name of the alias in the JKS that identifies the Public Key Certificate (PKC) that the web server uses to authenticate the client 

Note: The value of the <alias> element is verified only when<install-certificate> is set to true and <allow-unsigned-certificate> is set to false.

Conditional; required when <signature-properties mode="keystore">

<enable-json-conversion>

Specifies whether the adapter should treat the input data in the request and the data received in the adapter response as a JavaScript Object Notation (JSON) string 

If <enable-json-conversion> is set to true, the input data in the request (XML format) is converted to a JSON string after parsing.  

Valid values: true, false (default) 

Notes:

  • If you specify <enable-json-conversion> in the adapter configuration and the adapter request, the value in the adapter request overrides the value in the configuration.
  • The response maintains the order in which the fields are specified in the request.

No

<enable-redirects>

Specifies whether the adapter redirects a URL request to the changed URL location 

Valid values: true (default), false 

Note: If you specify <enable-redirects> in the adapter configuration and an adapter request, the values in the request override the values in the configuration.

No

<include-expect-header-in-request>

Specifies whether to include the expect header in the adapter request

Note: By default, the expect header is included in the request.

Valid values: true (default), false

No
<request-timeout>Specifies the time (in seconds) to wait when establishing a connection 

Default value: 10 seconds.
No
<ignore-line-break-in-response>

Specifies whether to ignore the line breaks while generating the adapter response

If true, the line break markups are ignored and the response is returned as a single line. If false, the line break markers (if specified in the adapter response) are retained.

Valid values: true (default), false

No

Recommendation

The HTTP adapter supports both <httpAdapterRequest> and <http-adapter-request> tags for an adapter request; however, only the <httpAdapterResponse> tag is supported for an adapter response. 

BMC recommends that you use the <httpAdapterRequest> root tag for the adapter request.

The HTTP adapter generates a response to the HTTP request (URL) defined in the adapter request. The response format depends on <Content-Type> of the HTTP server response.

 Elements of an HTTP adapter response to a request with a POST action

Element

Description

<metadata>

Contains the <status> element

<status>

Specifies the status of the adapter request 

Valid values: success, error

<status-line>

Contains the elements in the <status-line> element

<code>

Specifies the numeric status code for the response 

Code 10000 is returned for a connection and read timeout, or if the web service is down.

<reason>

Specifies the reason associated with the code

<header-lines>

Contains the elements in the <header-lines> element

<field-name>

Specifies the specific field name and value returned from the adapter request 

The element name is variable, dependent on the field returned.

<message-body>

Contains the message body of the HTTP response in CDATA format

The following figure shows a sample adapter request for a multipart/form-data request and when the file content type is application/json.

Adapter request for a multipart/form-data request when the content-type is application/json
<http-adapter-request>
     <http-connection-properties>
         <Content-Type>multipart/form-data</Content-Type>
         <Authorization>AR-JWT eyJhbGciOiJIUzI1NiJ9.eyJzdWI..............</Authorization>
     </http-connection-properties>
     <action>http://clm-abc-123456:8008/api/arsys/v1/entry/sample_attach</action>
     <data>
           <entry>
           <key>entry</key>
           <value><![CDATA[{
                               "values" :
                           {"Submitter__c" : "Allen", "Short Description__c" : "File", "Attachment__c" : "Task.txt"}
           }]]></value>
           <content-type>application/json</content-type>
       </entry>
       <entry>
           <key>attach-Attachment__c</key>
           <value>C:\Shared\Task.txt</value>
           <content-type>application/octet-stream</content-type>
       </entry>
     </data>
</http-adapter-request>


The following figure shows a sample adapter request and the adapter response for uploading an attachment to JIRA (file only).

<http-adapter-request>
   <http-connection-properties>
      <Content-Type>multipart/form-data</Content-Type>
      <Authorization>Basic amFpc2luZ2g6SGluJDE5ODQ=</Authorization>
      <X-Atlassian-Token>nocheck</X-Atlassian-Token>
   </http-connection-properties>
   <action>https://jira.bmc.com/rest/api/2/issue/DRAOC-59805/attachments</action>
   <data>
      <entry>
         <key>file</key>
         <value>C:\jira3.txt</value>
         <content-type>application/octet-stream</content-type>
      </entry>
   </data>
</http-adapter-request> 

The following figure shows the adapter response for uploading an attachment in JIRA (file only).

Adapter response for uploading an attachment in JIRA (file only)
<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Date>Mon, 20 Mar 2017 09:20:42 GMT</Date>
    <X-AREQUESTID>260x329136x2</X-AREQUESTID>
    <X-ANODEID>phx-jiraprd-03</X-ANODEID>
    <X-ASEN>SEN-5981199</X-ASEN>
    <Set-Cookie>JSESSIONID=66843D6E361824E0F92A06FCC7E63497; Path=/; Secure; HttpOnly</Set-Cookie>
    <X-Seraph-LoginReason>OK</X-Seraph-LoginReason>
    <Set-Cookie>atlassian.xsrf.token=BXV8-9FAB-2I0V-4AN7|df08b8af9b9b90342519e22bcdfa9d67b79d7a8b|lin; Path=/; Secure</Set-Cookie>
    <X-ASESSIONID>9oufav</X-ASESSIONID>
    <X-AUSERNAME>jaisingh</X-AUSERNAME>
    <Cache-Control>no-cache, no-store, no-transform</Cache-Control>
    <X-Content-Type-Options>nosniff</X-Content-Type-Options>
    <Content-Type>application/json;charset=UTF-8</Content-Type>
    <Keep-Alive>timeout=5, max=100</Keep-Alive>
    <Connection>Keep-Alive</Connection>
    <Transfer-Encoding>chunked</Transfer-Encoding>
  </header-lines>
  <message-body>[{"self":"https://jira.bmc.com/rest/api/2/attachment/137335","id":"137335",
"filename":"jira3.txt","author":{"self":"https://jira.bmc.com/rest/api/2/user?username=jaisingh",
"name":"jaisingh","key":"jaisingh","emailAddress":"Jaivardhan_Singh_CW@bmc.com",
"avatarUrls":{"48x48":"https://jira.bmc.com/secure/useravatar?avatarId=10122",
"24x24":"https://jira.bmc.com/secure/useravatar?size=small&avatarId=10122",
"16x16":"https://jira.bmc.com/secure/useravatar?size=xsmall&avatarId=10122",
"32x32":"https://jira.bmc.com/secure/useravatar?size=medium&avatarId=10122"},"displayName":"Singh, Jaivardhan","active":true,"timeZone":"America/Chicago"},"created":"2017-03-20T04:20:42.950-0500","size":11,"mimeType":"text/plain","content":"https://jira.bmc.com/secure/attachment/137335/jira3.txt"}]</message-body>
</httpAdapterResponse>


<httpAdapterRequest>
    <http-connection-properties/>
    <action>http://10.128.249.21:8080/httpclientoperations/HttpClientServlet
    </action>
    <use-ssl-certificate>false</use-ssl-certificate>
    <install-certificate>false</install-certificate>
    <allow-unsigned-certificate>false</allow-unsigned-certificate>
    <passphrase>changeit</passphrase>
    <character-set>shift_jis</character-set>
    <data>This is the sample String.</data>
    <include-expect-header>false</include-expect-header>
</httpAdapterRequest>

<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Server>Apache-Coyote/1.1</Server>
    <Content-Type>text/plain;charset=ISO-8859-1</Content-Type>
    <Content-Length>391</Content-Length>
    <Date>Mon, 05 Apr 2010 09:32:22 GMT</Date>
  </header-lines>
  <message-body>
   <Html>
    <Title>Testing Application for HTTP Adapter</Title>
     <Head></Head>
    <Title>Testing Application for HTTP Adapter</Title>
     <Head></Head>
      <Body>Hi, I am inside the doPost() Method of the EchoServlet,
        <br><br><br><br> <br><br>
         Query String : null<br><br><BR><BR>
         XML Text : This is the sample String.
        <Center> Copyrights &copy;, Developed By Test User </Center>
     </Body>
   </Html>
 </message-body>
</httpAdapterResponse>

<httpAdapterRequest>
    <http-connection-properties>
      <ntlm-authentication>true</ntlm-authentication>
    <http-connection-properties/>
    <action>http://10.128.249.21:8080/httpclientoperations/HttpClientServlet
    </action>
    <use-ssl-certificate>false</use-ssl-certificate>
    <install-certificate>false</install-certificate>
    <allow-unsigned-certificate>false</allow-unsigned-certificate>
    <passphrase>changeit</passphrase>
    <character-set>shift_jis</character-set>
    <data>
      <parent>
        <child1>Child 1 Data</child1>
        <child2>Child 2 Data</child2>
      </parent>
    </data>
</httpAdapterRequest>

<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Server>Apache-Coyote/1.1</Server>
    <Content-Type>text/plain;charset=ISO-8859-1</Content-Type>
    <Content-Length>444</Content-Length>
    <Date>Mon, 05 Apr 2010 09:33:50 GMT</Date>
  </header-lines>
  <message-body>
   <Html>
   <Title>Testing Application for HTTP Adapter</Title>
   <Head></Head>
    <Title>Testing Application for HTTP Adapter</Title>
   <Head></Head>
    <Body>Hi, I am inside the doPost() Method of the EchoServlet,
    <br><br>
    <br><br>
    <br><br> Query String : null
    <br><br><BR><BR>
    XML Text :
    <parent>
     <child1>Child 1 Data</child1>
     <child2>Child 2 Data</child2>
    </parent>
     <Center> Copyrights &copy;, Developed By Test User </Center>
    </Body>
  </Html>
 </message-body>
</httpAdapterResponse>


Note

<script> and <style> elements are deleted from the HTTP response for XHTML data format.


<httpAdapterRequest>
  <action>https://${Https_RemoteMachine}:${httpsPort}/HttpTestApp//EchoServlet
  </action>
  <use-ssl-certificate>true</use-ssl-certificate>
  <install-certificate>true</install-certificate>
  <allow-unsigned-certificate>true</allow-unsigned-certificate>
  <character-set>shift_jis</character-set>
  <data-format>xhtml</data-format>
  <data>
   <entry>
     <key>Name</key>
     <value>
       <foo>
         <bar>1</bar>
         <bar>2</bar>
       </foo>
     </value>
   </entry>
   <entry>
     <key>Credit Card</key>
     <value>1234</value>
   </entry>
   <entry>
     <key>Debit Card</key>
     <value>12345</value>
   </entry>
  </data>
  <http-connection-properties>
    <user-name>admin</user-name>
    <password>admin123</password>
  </http-connection-properties>
</httpAdapterRequest>

<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Server>Apache-Coyote/1.1</Server>
    <Content-Type>text/plain;charset=ISO-8859-1</Content-Type>
    <Content-Length>385</Content-Length>
    <Date>Mon, 05 Apr 2010 11:35:06 GMT</Date>
  </header-lines>
  <message-body>
  <Html>
   <Title>Testing Application for HTTP Adapter</Title>
    <Head></Head>
   <Title>Testing Application for HTTP Adapter</Title>
   <Head></Head>
   <Body>Hi, I am inside the doPost() Method of the EchoServlet, <br>
    <br><br><br> <br><br>
    Query String : null<br><br>Key 1    Value 1<BR>
    <BR> XML Text : <Center> Copyrights &copy;, Developed By Test User </Center>
   </Body>
  </Html>
 </message-body>
</httpAdapterResponse>

<httpAdapterRequest>
  <use-ssl-certificate>true</use-ssl-certificate>
  <install-certificate>true</install-certificate>
  <signature-properties>
    <keystore-file>server.jks</keystore-file>
    <keystore-password>changeit</keystore-password>
    <alias>1</alias>
  </signature-properties>
  <action>https://10.128.249.45:8087/</action>
</httpAdapterRequest>

<httpAdapterRequest>
      <use-ssl-certificate>false</use-ssl-certificate>
      <install-certificate>true</install-certificate>
      <allow-unsigned-certificate>true</allow-unsigned-certificate>
      <enable-json-conversion>true</enable-json-conversion>
      <data-format>xml</data-format>
      <strip-namespace-from-response>true</strip-namespace-from-response>
      <action>http://10.128.249.29:8089/</action>
</httpAdapterRequest>


<httpAdapterResponse>
   <metadata>
     <status>success</status>
   </metadata>
   <status-line>
     <code>200</code>
     <reason>OK</reason>
   </status-line>
   <header-lines>
     <Transfer-encoding>chunked</Transfer-encoding>
     <Content-type>text/html</Content-type>
   </header-lines>
   <message-body>
     <html lang="en-US">
       <head>
         <title>BBDA API</title>
         <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
       </head>
       <body>
         {"job-approval":{"result":"approve","detail":"dsd"}}
         <h1>Accepted request</h1>
       </body>
     </html>
   </message-body>
 </httpAdapterResponse>

Note

The JSON string is processed only if it is contained in the <body><message-body>, or <non-xml-data-response> elements.

<httpAdapterResponse>
      <metadata>
        <status>success</status>
      </metadata>
      <status-line>
        <code>200</code>
        <reason>OK</reason>
      </status-line>
      <header-lines>
        <Transfer-encoding>chunked</Transfer-encoding>
        <Content-type>text/html</Content-type>
      </header-lines>
      <message-body>
        <html lang="en-US">
          <head>
            <title>BBDA API</title>
            <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
          </head>
          <body>
            <job-approval>
              <detail>dsd</detail>
              <result>approve</result>
            </job-approval>
            <h1>Accepted request</h1>
          </body>
        </html>
      </message-body>
</httpAdapterResponse>
<http-adapter-request>
    <http-connection-properties>
      <User-Agent>TrueSight Orchestration</User-Agent>
    </http-connection-properties>
    <action>http://mail.google.com/mail/</action>
    <use-ssl-certificate>false</use-ssl-certificate>
    <install-certificate>false</install-certificate>
    <allow-unsigned-certificate>true</allow-unsigned-certificate>
    <passphrase>changeit</passphrase>
    <data-format>html</data-format>
    <data>
      <data>
        <entry>
          <key>Email</key>
          <value>somename@gmail.com</value>
        </entry>
        <entry>
          <key>Passwd</key>
          <value>_Mypassword_</value>
        </entry>
      </data>
    </data>
    <enable-redirects>true</enable-redirects>
</http-adapter-request>
<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Content-Type>text/html; charset=UTF-8</Content-Type>
    <Set-Cookie>GAPS=1:q7MOXHxImy7wEWqMqPxCo43uo2u_zA:qdzE-EQA_RmHPXA-;Path=/accounts;Expires=Wed, 24-Jul-2013 11:10:48 GMT;Secure;HttpOnly</Set-Cookie>
    <Set-Cookie>GALX=gqHGKTY632o;Path=/accounts;Secure</Set-Cookie>
    <Cache-control>no-cache, no-store</Cache-control>
    <Pragma>no-cache</Pragma>
    <Expires>Mon, 01-Jan-1990 00:00:00 GMT</Expires>
    <X-Frame-Options>Deny</X-Frame-Options>
    <X-Auto-Login>realm=com.google&args=service%3Dmail%26continue%3Dhttp%253A%252F%252Fmail.google.com%252Fmail%252F%253Fui%253Dhtml%2526zy%253Dl</X-Auto-Login>
    <Date>Mon, 25 Jul 2011 11:10:48 GMT</Date>
    <X-Content-Type-Options>nosniff</X-Content-Type-Options>
    <X-XSS-Protection>1; mode=block</X-XSS-Protection>
    <Content-Length>18700</Content-Length>
    <Server>GSE</Server>
  </header-lines>
  <message-body><html lang="en" dir="ltr"><head><meta http-equiv="Content-Type" content="text/html; 
charset=UTF-8"><meta name="description" content="7+ GB of storage, less spam, and 
mobile access. Gmail is email that's intuitive, efficient, and useful. And maybe even fun.">
...
</html></message-body>
</httpAdapterResponse>
<http-adapter-request>
    <http-connection-properties>
      <User-Agent>TrueSight Orchestration</User-Agent>
    </http-connection-properties>
    <action>http://mail.google.com/mail/</action>
    <use-ssl-certificate>false</use-ssl-certificate>
    <install-certificate>false</install-certificate>
    <allow-unsigned-certificate>true</allow-unsigned-certificate>
    <passphrase>changeit</passphrase>
    <data-format>html</data-format>
    <data>
      <data>
        <entry>
          <key>Email</key>
          <value>somename@gmail.com</value>
        </entry>
        <entry>
          <key>Passwd</key>
          <value>_MyPassword_</value>
        </entry>
      </data>
    </data>
    <enable-redirects>false</enable-redirects>
 </http-adapter-request>
<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>302</code>
    <reason>Moved Temporarily</reason>
  </status-line>
  <header-lines>
    <Content-Type>text/html; charset=UTF-8</Content-Type>
    <Cache-Control>no-cache, no-store, max-age=0, must-revalidate</Cache-Control>
    <Pragma>no-cache</Pragma>
    <Expires>Fri, 01 Jan 1990 00:00:00 GMT</Expires>
    <Date>Mon, 25 Jul 2011 11:06:29 GMT</Date>
    <Location>https://www.google.com/accounts/ServiceLogin?service=mail&passive=true&rm=false&continue=http%3A%2F%2Fmail.google.com%2Fmail%2F%3Fui%3Dhtml%26zy%3Dl&bsv=llya694le36z&scc=1&ltmpl=default&ltmplcache=2&from=login</Location>
    <X-Content-Type-Options>nosniff</X-Content-Type-Options>
    <X-Frame-Options>SAMEORIGIN</X-Frame-Options>
    <X-XSS-Protection>1; mode=block</X-XSS-Protection>
    <Server>GSE</Server>
    <Content-Length>423</Content-Length>
    <Connection>Keep-Alive</Connection>
  </header-lines>
  <message-body><HTML><HEAD><TITLE>Moved Temporarily</TITLE></HEAD><BODY BGCOLOR="#FFFFFF" TEXT="#000000"><H1>Moved Temporarily</H1>The document has moved <A HREF="https://www.google.com/accounts/ServiceLogin?service=mail&amp;passive=true&amp;rm=false&amp;continue=http%3A%2F%2Fmail.google.com%2Fmail%2F%3Fui%3Dhtml%26zy%3Dl&amp;bsv=llya694le36z&amp;scc=1&amp;ltmpl=default&amp;ltmplcache=2&amp;from=login">here</A>.</BODY></HTML></message-body>
</httpAdapterResponse>


<httpAdapterRequest>
  <action>http://localhost:6080/baorepo/resources</action>
  <file-path>C:\bmc-workspace\ao\rel\20.11.03.00-R\adapters\adapter-http\target\aroar\ro-adapter-http_20.11.03.00.aroar</file-path>
  <file-content-type>application/java-archive</file-content-type>
  <data-format>XML</data-format>
  <http-connection-properties>
    <Authorization>Basic YWRtaW46YWRtaW4xMjM=</Authorization>
    <Content-Type>application/java-archive</Content-Type>
    <Resource-Type>ADAPTER</Resource-Type>
    <Slug>ro-adapter-http_20.11.03.00.aroar</Slug>
  </http-connection-properties>
</httpAdapterRequest>

<httpadapterRequest>
  <enable-json-conversion>true</enable-json-conversion>
  <action>http://10.128.249.76:8080/DemoJSONNew/JSONServlet2</action>
  <data-format>xml</data-format>
  <data>
    <Demo>
      <employees>
	<employee>
	  <name>User1</name>
	  <age>23</age>
	</employee>
	<employee>
	  <name>User2</name>
	  <age>22</age>
	</employee>
	<employee>
	  <name>User3</name>
	  <age>22</age>
	</employee>
	<employee>
	  <name>User4</name>
	  <age>22</age>
	</employee>
      </employees>
      <testing1>testing 1</testing1>
      <testing2>testing 2</testing2>
      <testing3>testing 3</testing3>
    </Demo>
  </data>
</httpadapterRequest>

<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Server>Apache-Coyote/1.1</Server>
    <Content-Type>application/json</Content-Type>
    <Content-Length>128</Content-Length>
    <Date>Tue, 31 Jul 2012 09:53:05 GMT</Date>
  </header-lines>
  <message-body>
    <employees>
      <e>
        <age>23</age>
        <name>User1</name>
      </e>
      <e>
        <age>22</age>
        <name>User2</name>
      </e>
      <e>
        <age>22</age>
        <name>User3</name>
      </e>
      <e>
        <age>22</age>
        <name>User4</name>
      </e>
    </employees>
  </message-body>
</httpAdapterResponse>

<httpadapterRequest>
  <enable-json-conversion>true</enable-json-conversion>
  <action>http://10.128.249.76:8080/DemoJSONNew/JSONServlet2</action>
  <data>
    <Test-Head>
      <child-1>
	This is the data that needs to be POSTED to the
	site that handles POST requests. This data cant
	be sent in the GET due to various reasons.
      </child-1>
      <child-2>This is way too lengthy.</child-2>
      <child-3>
	This has the following creditcard number that i
	cant afford to be exposed out in the public.
      </child-3>
      <child-4>
	Lastly it is my damn code and i will do what
	ever i want to do with it. Well not really.
      </child-4>
    </Test-Head>
  </data>
</httpadapterRequest>

<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Server>Apache-Coyote/1.1</Server>
    <Content-Type>application/json</Content-Type>
    <Content-Length>128</Content-Length>
    <Date>Tue, 31 Jul 2012 09:59:20 GMT</Date>
  </header-lines>
  <message-body>{"employees":[{"name":"User1","age":"23"},{"name":"User2","age":"22"},{"name":"User3","age":"22"},{"name":"User4","age":"22"}]}</message-body>
</httpAdapterResponse>

<httpadapterRequest>
  <enable-json-conversion>false</enable-json-conversion>
  <action>http://10.128.249.76:8080/DemoJSONNew/JSONServlet2</action>
  <data-format>xml</data-format>
  <data>
    <Test-Head>
      <child-1>
	This is the data that needs to be POSTED to the
	site that handles POST requests. This data cant
	be sent in the GET due to various reasons.
      </child-1>
      <child-2>This is way too lengthy.</child-2>
      <child-3>
	This has the following creditcard number that i
	cant afford to be exposed out in the public.
      </child-3>
      <child-4>
	Lastly it is my damn code and i will do what
	ever i want to do with it. Well not really.
      </child-4>
    </Test-Head>
  </data>
</httpadapterRequest>

<httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Server>Apache-Coyote/1.1</Server>
    <Content-Type>application/json</Content-Type>
    <Content-Length>128</Content-Length>
    <Date>Tue, 31 Jul 2012 10:02:22 GMT</Date>
  </header-lines>
  <message-body>
    <employees>
      <e>
        <age>23</age>
        <name>User1</name>
      </e>
      <e>
        <age>22</age>
        <name>User2</name>
      </e>
      <e>
        <age>22</age>
        <name>User3</name>
      </e>
      <e>
        <age>22</age>
        <name>User4</name>
      </e>
    </employees>
  </message-body>
</httpAdapterResponse>


<httpAdapterRequest>
     <action>http://xxx.yy.zzz.123:38080/test.txt</action>
     <ignore-line-break-in-response>false</ignore-line-break-in-response>
     <data-format>XML</data-format>
  <html-syntax-correction>false</html-syntax-correction>
</httpAdapterRequest>
 <httpAdapterResponse>
  <metadata>
    <status>success</status>
  </metadata>
  <status-line>
    <code>200</code>
    <reason>OK</reason>
  </status-line>
  <header-lines>
    <Server>Apache-Coyote/1.1</Server>
    <Accept-Ranges>bytes</Accept-Ranges>
    <ETag>W/"23-1374582955568"</ETag>
    <Last-Modified>Tue, 23 Jul 2013 12:35:55 GMT</Last-Modified>
    <Content-Type>text/plain</Content-Type>
    <Content-Length>23</Content-Length>
    <Date>Mon, 10 Aug 2015 06:52:27 GMT</Date>
  </header-lines>
  <message-body>one
two
three
four
</message-body>
</httpAdapterResponse>
Was this page helpful? Yes No Submitting... Thank you

Comments