PLease can someone Help, I have written a script that will automatically add a scheduled call on a trigger, hoever it keep sadding the scheduled call as a closed activity. I cant seem to find the error
contactDetails = zoho.crm.getRecordById("Contacts",contactId);
createdtime = ifnull(contactDetails.get("Created_Time"),"").toTime("yyyy-MM-dd'T'HH:mm:ss").addDay(1);
mp = Map();
mp.put("Subject","Schedule Calls Test");
mp.put("Owner",ifnull(contactDetails.get("Owner"),"").get("id"));
mp.put("Call_Type","Outbound");
mp.put("$se_module","Contacts");
mp.put("Who_Id",contactId);
mp.put("Call_Start_Time",createdtime.toString("yyyy-MM-dd'T'HH:mm:ss+05:30"));
mp.put("$which_call","ScheduleCall");
create = zoho.crm.createRecord("Calls",mp);
info mp;
info create;