Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

JSON Request in query parameters

harishdasari
Tera Guru

Hi,

How to pass this JSON request in query parameters of REST API

"comment":   { "body": "The smoke is very colorful." },

find_real_file.png

Thank you.

1 ACCEPTED SOLUTION

Hi Harish,



http://wiki.servicenow.com/index.php?title=RESTMessageV2_API#setRequestBody.28String_body.29



You can use setRequestBody method for setting this "request body"



eg,



setRequestBody(JSON.stringify(myObj));


View solution in original post

5 REPLIES 5

Hi Harish,



http://wiki.servicenow.com/index.php?title=RESTMessageV2_API#setRequestBody.28String_body.29



You can use setRequestBody method for setting this "request body"



eg,



setRequestBody(JSON.stringify(myObj));