I need to store the data from the Zoho CRM to the Catalyst datastore. I am not sure how to hit the Catalyst API from Deluge to send data from CRM functions to Catalyst.
Did some tried this?
You can find the deluge code sample below to hit the Catalyst datastore insert row API from Zoho CRM.
//Deluge code to download file from filestore and pass it to the Catalyst API in order to perform OCR
//create the headers for the Catalyst API's
headerMap = Map();
headerMap.put("Authorization","Zoho-oauthtoken {access_token}"); //You should create an access token for the scope ZohoCatalyst.tables.rows.CREATE
headerMap.put("Environment","Development"); //Production incase if you need to hit your production environment
// pass the data to the datastore Insert Row API
jsondata = {"EmpId":1234,"EmpName":"John Smith"};
inputdata = List();
inputdata.add(jsondata.toList());
postData = invokeurl
[
url :"https://api.catalyst.zoho.com/baas/v1/project/{project_id}/table/{table_Id}/row"
type :POST
headers:headerMap
content-type:"application/json"
parameters: inputdata.toString()
];
info postData;
return "";
You have to replace the .com to .eu if you are in EU DC and .in if you are using IN DC and you have to replace it depending on your DC.