Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

REST Client using POST JSON Arguments Containing Objects

I'm trying to implement a REST API where the arguments contain a JSON object.

 

I've tried both tREST and tRESTClient without success.

 

Example :

{

   "SessionToken": "",

   "ClientToken": "",

    "AdditionalInformation" : {

        "StartDate" : "",

        "EndDate" : ""

    }

}

Labels (4)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Try with a tRest component, with http method post and place your json in the corps http

Don't forget to put the header : Content-Type = "application/json"

View solution in original post

3 Replies
nfz11
Creator III
Creator III

Are you "implementing a REST API" or consuming a REST API?   tREST and tRESTClient are only for the latter.

 

What error are you getting?  Are you able to POST to the same web service using another tool like Postman?

Anonymous
Not applicable
Author

Try with a tRest component, with http method post and place your json in the corps http

Don't forget to put the header : Content-Type = "application/json"

Anonymous
Not applicable
Author

Thank you! I must have done something wrong when I tried it previously.

 

Is there a way to use programmatic, instead of fixed, arguments?