Posted: 6 Feb 2020 5:14 EST Last activity: 25 May 2020 6:22 EDT
How to implement Form Data Request in Pega
I need to submit a file and a few text properties to an API(Form-Data), when i am using Postman(attached) it is working fine, even I used apache multipart feature to implement the same in Java which is also working fine, But now in Pega, I have to implement this, so far i have implemented Rest connectors to send data in JSON format, can some body help me to implement Form-data(Multipart) using pega..
To construct multipart form data requests, you need to send the parts as "attachments". Check these articles. These apply to both SOAP and REST connectors and services. In your specific case, you need to send two parts - one with mimetype application/x-www-form-urlencoded for your form data and the other with mime type corresponding to your file.
Thanks Praneeth, I have implemented the request as per the instructions but getting below error
"Failed to parse multipart servlet request; nested exception is java.io.IOException: org.apache.tomcat.util.http.fileupload.FileUploadException: the request was rejected because no multipart boundary was found"
Can you please go through attachments and let me know if i am missing anything