HTTP Method Content format

booher04
Tera Guru

Having some trouble getting the correct format on the content section for a REST HTTP Method.  Trying to send data to MS Dynamics CRM, everything is correct with the end point and headers.  The issue is the format they are receiving the data.  The format they requested is attached.  I have done multiple of these for an Ansible POST however, this one is not working when setup the same.  I've tried multiple ways and here is the last:

{
"entity": "Note",
"message": "Create",
"description": "${description}",
"caseid": "${caseid}",
"ritm": "${ritm}"
}

 

I've also tried to use just { "lc_payload": "${content}" }.  The format didn't send correctly either. ANY help on this would  be greatly appreciated. 

7 REPLIES 7

Hi,

Can you please share the payload generated when you make a request. Previous payload was the response your received from another system. I would like to see what is the request body your code is generating .

Please appreciate the efforts of community contributors by marking appropriate response as correct answer and helpful, this may help other community users to follow correct solution in future.
Thanks
Anil Lande

payload to crm.JPG

If I setup the Content as follows and hit the "Test" :

{
"lc_payload": "${content}"
}

 

I get the 200 Result with: {"@odata.context":"https://loancaretemp.crm.dynamics.com/api/data/v9.2/$metadata#Microsoft.Dynamics.CRM.lc_crmsnow_inbo...","lc_response":"success"}

 

But they report the payload is not formatted correctly and it comes in like:

crm response.jpg