How to pass any json to REST API(POST Method) - Mendix Forum

How to pass any json to REST API(POST Method)

0

Hi,

I am new to mendix and exploring REST API. I am consuming one REST API which is of method POST. How to pass json to the REST API?

I am using Desktop Modeler V 7.21.0

Thank You.


 

asked
2 answers
2

Hi,

Check out this documentation and the movie: https://docs.mendix.com/refguide/consumed-rest-services

It will explain the basics of REST with Mendix

answered
1

Hi,

 

To pass JSON to a REST API via a POST method, you have to use export mapping instead of import mapping for the GET method, since you are 'translating' mendix objects to JSON. Check this documentation on how to do that: https://docs.mendix.com/refguide/export-mappings

Hope this helps

answered