on 11-09-2015 5:09 AM
I need to call a REST service that accepts only form-data . In POSTMAN, I am able to to call the service by using the POST operation, entering the service end point , and in the BODY tab, I select "form-data" and pass the values to the key that the service expects . This service does not accept XML or JSON in the Request body .
How do I configure this in the Receiver REST adapter?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@maheswarareddykonda : Can you please share solution. I've a requirement to send data over REST using form-data. Able to perform same using POSTMAN as mention above, but with PO, I keep getting BAD request error.
Any help will be appreciated.
Thank you,
Nilesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Simple java map , construct the request as a String and write it to the OutputStream. Map it to any dummy message type.
Also, in the REST Receiver need to configure Content-Type as application/x-www-form-urlencoded . But simply setting in the Header fields didnt work.
Using your suggestion, set it using MTB Transform.ContentType parameter. And that worked, thanks.. Seems like a bug in the Receiver REST adapter.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Also, in the REST Receiver need to configure Content-Type as application/x-www-form-urlencoded. But simply setting in the Header fields didnt work.
check this
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.