on 09-23-2015 5:12 AM
Hi,
My scenario is to send a CSV file to an external system as a HTTP attachment.
I do not have a mapping for this scenario, so created a File adapter in Sender and a HTTP_AAE adapter at the receiver with only Configuration objects.
When i run the scenario, i can see that the CSV file gets into the Payload Body and is transmitted to the end system.
My requirement is to send the CSV file as an attachment itself.
I have even tried using the Payload swap bean, but still the payload gets into the body and is being passed.
Any help on this would be much appreciated.
Can you tell me, what you mean by "http attachment"? In other words: How should the http stream look like? I think you have to clarify this with the responsible guys from end system.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Stefan,
I am trying to do HTTP POST to an end point URL along with passing a few parameters. Please find the below HTML code which works perfectly fine using a browser and i need to achieve the same using PI.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=ISO-8859-1">
<title>Direct access - File upload</title>
</head>
<body>
<h1>Direct access - File upload</h1>
<form method="post"
enctype="multipart/form-data"
action="https://XYZ.ariba.com">
Event: <input type="text" name="event" value="Import Batch Data"><br>
<input type="radio" name="fullload" value="true">Full Load<br>
Password: <input type="password" name="sharedsecret" value="XYZXYZ"><br>
Client Type: <input type="text" name="clienttype" value="DataTransferTool"><br>
Client Info: <input type="text" name="clientinfo" value="Custom ITK Download Form"><br>
Client Version: <input type="text" name="clientversion" value="1.0"><br>
File: <input type="file" name="content"><br>
<input type=submit value="Submit Post">
</form>
</body>
There is no standard why to achieve this. If you want to use exactly the same access to post your data, you have to simulate the whole HTTP stream with multipart/form-data Here is an example how this could look like: http://stackoverflow.com/questions/4526273/what-does-enctype-multipart-form-data-mean The HTTP stream can be created with Java Mapping. A had a similar task for mail adapter, described here: http://scn.sap.com/community/pi-and-soa-middleware/blog/2015/09/04/create-email-with-body-and-attach...
Hello Sherin,
I doubt this bean wont work for HTTP_AAE Adapter
only for mail adapter
http://help.sap.com/saphelp_nw73/helpdata/en/2e/bf37423cf7ab04e10000000a1550b0/content.htm
Please share the screenshot of your bean config
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sherin,
I think payloadSwapBean is not working because there is nothing to swap to You need to use mapping for this.
Regards,
Mark
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.