Adapter for SAP 10.1 | webMethods Adapter for SAP Documentation | webMethods Adapter for SAP Installation and User’s Guide Documentation | Routing Messages Through Adapter for SAP | Routing IDocs Through Adapter for SAP | Posting an IDoc-XML Document from an HTTP Client
 
Posting an IDoc-XML Document from an HTTP Client
Use the following guidelines to submit an IDoc-XML document via any HTTP client:
POST /invoke/pub.sap.transport.ALE/InboundProcess HTTP/1.1\r\n
Host: <hostname of client>\r\n
Content-Type: application/x-sap.idoc\r\n
Authorization: Basic <base64-encoded user:password>\r\n
Content-Length: <number of bytes in XML document>\r\n
\r\n
<?>xml version="1.0"?>
<MATMAS02>
...
</MATMAS02>
Note:
The value for the content length has to be replaced by the actual length of content.
*To simulate an HTTP client for testing purposes, you can use the service pub.client:http
1. Using Designer, navigate to the service pub.client:http.
2. Select Test \>Run.
3. Specify the URL of the IDoc-XML handler service. For example: http://localhost:5555/invoke/pub.sap.transport.ALE/InboundProcess.
4. Specify Post as the method.
5. Add one entry in the field headers:
Name:Content-type
Value:application/x-sap.idoc
6. Copy a sample Idoc-XML document into the field data > string.