1. Create a new workflow
2. Instant action should be a new function -> WRITE YOUR OWN
4. The function should be as below:
Lead = zoho.crm.getRecordById("Leads",LeadID);
if(Lead.get("id") != null)
{
LeadOwner = Lead.get("Owner");
FirstName = ifnull(Lead.get("First_Name"),"");
Owner = zoho.crm.getRecordById("users", LeadOwner.get("id"));
AccountId = "";
if (Owner.get("users") != null){
AccountId = Owner.get("users").get(0).get("RC_Account_ID");
}
ExtensionId = ""; // Extension ID if needed (optional)
FromNumber = ""; // If different from account phone number (optional)
ToNumber = Lead.get("Mobile");
MsgText = "Hi there " + FirstName + " testing it"; // TODO: Customize the message text
//Important - if you received the extension from the Zoho Marketplace the below line changes to mpmultiuserringcentralsmsmessaging.sendRcSms(AccountId,ExtensionId,FromNumber,ToNumber,MsgText);
resp = multiuserringcentralmessagingextension.sendRcSms(AccountId,ExtensionId,FromNumber,ToNumber,MsgText);
info resp;
}