How do I convert a Postman body statement into a 3cx CRM template

Status
Not open for further replies.

greychain

Gold Partner
Advanced Certified
Joined
Jul 13, 2018
Messages
779
Reaction score
122
I am using Postman to test the SuiteCRM V8 API. For lead creation it produces the following request:

Post {{suitecrm.url}}/V8/module

with the body details

{
"data": {
"type": "Leads",
"attributes": {
"phone_work": "0123456"
}
}
}

How do I encode this into the Template generator format?
 
In the XML template you can use the following request:
XML:
<Request Url="{{suitecrm.url}}/V8/module" RequestType="Post" RequestEncoding="Json" ResponseType="Json">
  <PostValues>
    <Object Key="data">
      <Value Key="type" Type="String">Leads</Value>
        <Object Key="attributes">
          <Value Key="phone_work" Type="String">0123456</Value>
        </Object>
    </Object>
  </PostValues>
</Request>
 
Thanks for that it seems to be working now. Plus I now know how to format post to xml
 
Status
Not open for further replies.

Latest Posts

Forum statistics

Threads
112,325
Messages
591,898
Members
165,478
Latest member
postmaster@studiolegaleda