loops = {1,2,3,4,5,6,7,8,9,10,11,12};
// create a custom view with criteria Phone contains ( OR Phone contains -
// copy the custom view ID from the URL
CUSTOM_VIEW_ID = IDGOESHERE;
for each loop in loops
{
leads_with_phone = zoho.crm.getRecords("Leads",loop,200,{"cvid":CUSTOM_VIEW_ID});
for each lead in leads_with_phone
{
mobile = lead.get("Mobile");
//mobile = lead.get("Mobile");
//update_payload = {"Phone":phone.replaceAll("[^\d+]*",""),"Mobile":mobile.replaceAll("[^\d+]*","")};
update_payload = {"Mobile":mobile.replaceAll("[^\d+]*","")};
update_resp = zoho.crm.updateRecord("Leads",lead.get("id"),update_payload);
info update_resp;
}
}