Json invalid error while calling a REST HTTP request API

Hello there,

I am using the HTTP request command to call an API from Monkey learn website service for extracting keywords from a DATA or TEXT. It takes input as a JSON value and returns an output, But while POSTing the request I am getting an error stating-

{ status_code: 422, error_code: REQUEST_PARAM_PARSE, detail: This endpoint requires a JSON object body. }

JSON input I am giving-

{“data”:[“Elon Musk has shared a photo of the spacesuit designed by SpaceX. This is the second image shared of the new design and the first to feature the spacesuit’s full-body look.”]} .

I have checked and validated JSON object in an online validator and found it a valid one.

Please help me out resolving this issue.


Try to use the Body property of the activity:

Also, note that you need to specify the JSON as a string, so you need to escape the quotes of the JSON itself: "{""data"": [""Elon Musk has Shared a photo Of the spacesuit designed By SpaceX. This Is the second image Shared Of the New design And the first To feature the spacesuit’s full-body look.""]}"

Hello Shubham,
In this video I do a lot of stuff with complex JSONs:

Cristian negulescu