When working with Zoho CRM automation, records created, updated, or deleted via Deluge do not trigger workflow or assignment rules automatically. This is expected behavior. Zoho CRM separates backend actions from UI-triggered automation to prevent loops and unintended executions.
If you want workflows to run during script execution, you must explicitly pass the correct parameters. This guide explains how to trigger workflows properly for create, update, and delete actions.
To trigger workflow rules while creating a record using Deluge, include the trigger parameter inside the createRecord() function.
leadMap = {
"Last_Name":"Kumar",
"Email":"jitender@kalkillp.com",
"Phone":"+91XXXXXXXXXX"
};
response = zoho.crm.createRecord(
"Leads",
leadMap,
{"trigger" : ["workflow"]}
);
This ensures all workflows configured for the "On Create" trigger will execute.
To execute an assignment rule during record creation, pass the assignment rule ID using the lar_id parameter. You can find the assignment rule ID in the CRM URL while editing the rule.
response = zoho.crm.createRecord(
"Leads",
leadMap,
{"lar_id":"4409363000012741244"}
);
response = zoho.crm.createRecord(
"Leads",
leadMap,
{
"trigger":{"workflow"},
"lar_id":"4409363000012741244"
}
);
Using zoho.crm.updateRecord() will NOT trigger workflows. To execute workflows on update, you must use the CRM API via invokeurl.
dataList = List();
updateMap = Map();
updateMap.put("Lead_Status","Qualified");
dataList.add(updateMap);
triggerList = List();
triggerList.add("workflow");
requestMap = Map();
requestMap.put("data", dataList);
requestMap.put("trigger", triggerList);
response = invokeurl
[
url :"https://www.zohoapis.com/crm/v2/Leads/"+leadId
type :PUT
parameters:requestMap.toString()
connection:"zoho_crm"
];
This forces Zoho CRM to process update-trigger workflows correctly.
To trigger workflows during record deletion, append wf_trigger=true to the delete API URL.
response = invokeurl
[
url: "https://www.zohoapis.com/crm/v2/Leads?ids="+leadId+"&wf_trigger=true"
type: DELETE
connection:"zoho_crm"
];
Without this parameter, delete-trigger workflows will not execute.
| Action | Method to Trigger Workflow |
|---|---|
| Create Record | {"trigger":["workflow"]} |
| Assignment Rule | "lar_id":"AssignmentRuleID" |
| Update Record | invokeurl with "trigger":["workflow"] |
| Delete Record | wf_trigger=true |
If your Zoho CRM workflows are not triggering during Deluge execution, it is not an error — it is expected system behavior.
Once you explicitly control workflow execution, your automation becomes predictable and stable.