I can't auto-scheduling calls down - the code does not change anything

I can't auto-scheduling calls down - the code does not change anything

Hi,

I was trying to set a function that auto-schedules calls based on their call result; i.e "Requested more info". I had also included a reminder to send an email in the code. I logged a test call and nothing changed. Is there anything wrong with the code I used?

void automation.FollowUp_Call_Function(String callId)
{
// Retrieve 'callId' from function arguments
callId = ifnull(input.callId,"");
// Ensure callId is present
if(callId == "")
{
info "Error: callId is missing. Make sure it's being passed from the workflow.";
return;
}
// Fetch the call record details
callDetails = zoho.crm.getRecordById("Calls",callId);
if(callDetails.isEmpty())
{
info "Error: No call record found with the given callId.";
return;
}
callResult = callDetails.get("Call Result");
callDate = zoho.currentdate;
// Initialize follow-up date and time
followUpDate = null;
followUpTime = null;
if(callResult == "Requested call back")
{
followUpDate = callDate.addDay(1);
// Default: Next day
followUpTime = "10:00 AM";
// Default time
}
else if(callResult == "Requested more info")
{
followUpDate = callDate.addDay(7);
followUpTime = "10:00 AM";
reminderTask = Map();
reminderTask.put("Subject","Follow-up: Send Email");
reminderTask.put("Due Date",callDate.toString() + " 2:00 PM");
reminderTask.put("Task Owner",callDetails.get("Owner"));
reminderTask.put("Description","Reminder: Send an email for more info.");
reminderTask.put("$se_module","Calls");
reminderTask.put("What_Id",callId);
zoho.crm.createRecord("Tasks",reminderTask);
}
else if(callResult == "No response/Busy")
{
followUpDate = callDate.addDay(7);
followUpTime = "10:00 AM";
// Default time
}
else if(callResult == "Invalid number")
{
reminderTask = Map();
reminderTask.put("Subject","Follow-up on Invalid Number");
reminderTask.put("Due Date",callDate.addDay(7).toString());
reminderTask.put("Task Owner",callDetails.get("Owner"));
reminderTask.put("Description","Reminder: Follow up on the invalid number.");
reminderTask.put("$se_module","Calls");
reminderTask.put("What_Id",callId);
zoho.crm.createRecord("Tasks",reminderTask);
}
// Create follow-up call
if(followUpDate != null)
{
callData = Map();
callData.put("Subject","Follow-up Call");
callData.put("Call Type","Outbound");
callData.put("Call Result","Scheduled");
callData.put("Call Start Time",followUpDate.toString() + " " + followUpTime);
callData.put("Who_Id",callDetails.get("Who_Id"));
zoho.crm.createRecord("Calls",callData);
}
}

    • Sticky Posts

    • Zoho CRM Functions 53: Automatically name your Deals during lead conversion.

      Welcome back everyone! Last week's function was about automatically updating the recent Event date in the Accounts module. This week, it's going to be about automatically giving a custom Deal name whenever a lead is converted. Business scenario Deals are the most important records in CRM. After successful prospecting, the sales cycle is followed by deal creation, follow-up, and its subsequent closure. Being a critical function of your sales cycle, it's good to follow certain best practices. One such
    • User Tips: Auto-Create Opportunity/Deal upon Quote Save (PART 1)

      Problem: We use quotes which convert to sales orders but Users / Sales Reps do not create opportunities / deals and go straight to creating a quote. This leads to poor reporting. Implementing this solution improves reporting and makes it easier for users.
    • Custom Function : Automatically send the Quote to the related contact

      Scenario: Automatically send the Quote to the related contact.  We create Quotes for customers regularly and when we want to send the quote to the customer, we have to send it manually. We can automate this, using Custom Functions. Based on a criteria, you can trigger a workflow rule and the custom function associated to the rule and automatically send the quote to customer through an email. Please note that the quote will be sent as an inline email content and not as a PDF attachment. Please follow
    • Function #50: Schedule Calls to records

      Welcome back everyone! Last week's function was about changing ownership of multiple records concurrently. This week, it's going to be about scheduling calls for records in various modules. Business scenario Calls are an integral part of most sales routines.. Sales, Management, Support, all the branches of the business structure would work in cohesion only through calls. You could say they are akin to engine oil, which is required by the engine to make all of it's components function perfectly. CRM
    • Function #37: Create a Purchase Order from a Quote

      Welcome back everyone! Last week, we learnt how to calculate the total number of activities for a lead and further take note of the activity count for particular dates. For instance, from the period of Demo to Negotiation. This week, let's look at a function that lets you create a Purchase Order instantly from a Quote. Business scenario: In any form of business, one of the most important things to do is to document the transactions. Naturally, negotiation, signing an agreement, placing an order,
    • Recent Topics

    • Font Size 11 - Zoho CRM Email Templates

      Our company communicates with our vendors exclusively using Calibri Font Size 11, as this is the standard formatting for professional emails. Since the CRM only allows for the selection of font sizes 10 & 12, we have been unable to utilize the CRM email
    • BANK FEED - MAYBANK , provider from YODLEE IS NOT WORKING

      As per topic, the provider YODLEE is not working for the BANK FEED. It have been reported since 2023 Q3, and second report on 2023 Q4. now almost end of 2024 Q1, and coming to 2024 Q2. Malaysia Bank Maybank is NOT working. can anyone check on this issue?
    • Customer Grouping

      Hi, how can I group multiple customers into single group. So that I can have idea of accounts receivables of all the customers in single group. Like if there are multiple subsidiaries of same company we have having a business with, and want to view the
    • Enable / show scroll bar when Mega Menu is opened

      Hey there I am using the mega menu add-on and experience a "flicker" whenever the mega menu opens. The reason is, that the scrollbar, which has a width of a few pixels, stops showing when the mega menu opens. As the scrollbar disappears the whole page
    • Elevate your CX delivery using CommandCenter 2.0: Simplified builder; seamless orchestration

      Most businesses want to create memorable customer experiences—but they often find it hard to keep them smooth, especially as they grow. To achieve a state of flow across their processes, teams often stitch together a series of automations using Workflow
    • Item images

      Can we get an "On hover" expanded image for items please ?
    • Free webinar—Redefining workforce security with Zoho Vault: Passwords, passkeys, and multi-factor authentication

      Hi everyone! Did you know that in Q2 alone, 94 million data records were leaked globally? Behind every breach is a combination of poor password habits, phishing attacks, privilege misuse, and simple human error. The fallout—including reputational damage,
    • Zoho Sign product updates - Q3 2025

      Hello everyone! Q3 was all about AI. Here's the list of features and enhancements that have gone live, along with a list of what we have in pipeline for the last quarter: AI-powered agreement management Sending documents and authenticating recipients
    • Feature Suggestion for Zoho Websites – Inspired by Squarespace Systems

      Dear Zoho Team, I’m a Zoho user and also a Squarespace Platinum Circle member, and I recently noticed the launch of Zoho Websites in India. I wanted to share some ideas for features that could enhance the platform for professional users and agencies.
    • Zoho sites header

      Good day, Im stuck with this situation. I choose a template for my website creation. I have tweaked every instance of the visual editor, regarding the header, I have created created customize fonts presets... I have followed every single step. and my
    • Zoho Books Sandbox environment

      Hello. Is there a free sandbox environment for the developers using Zoho Books API? I am working on the Zoho Books add-on and currently not ready to buy a premium service - maybe later when my add-on will start to bring money. Right now I just need a
    • Quick Create needs Client Script support

      As per the title. We need client scripts to apply at a Quick Create level. We enforce logic on the form to ensure data quality, automate field values, etc. However, all this is lost when a user attempts a "Quick Create". It is disappointing because, from
    • Kaizen #152 - Client Script Support for the new Canvas Record Forms

      Hello everyone! Have you ever wanted to trigger actions on click of a canvas button, icon, or text mandatory forms in Create/Edit and Clone Pages? Have you ever wanted to control how elements behave on the new Canvas Record Forms? This can be achieved
    • DNS set up

      I want to create an email with my company domain. When I tried to add new record with cloudflare it didn't work. The DNS record can't be manually added. I followed the instruction but still can't add it. Could you help?
    • Pocket from Mozilla is closing shop. Don’t lose your favorites . Move them to Zoho Mail Bookmarks now! 📥🔖

      The end of Pocket shouldn't mean the end of your important links and content. Easily import them into Zoho Mail's Bookmarks and continue right where you left off. You can bring over your entire Saves, Collections, and tags just the way they are. Bookmarks
    • How to Send Email from within a custom module (with or without an email template)

      It is possible to send an email from the Deals module. However, I can't find a way to send an email from any of our custom modules. I have tried adding an email field to the modules (even though we don't really want one or need it there). That doesn't
    • General suggestions

      Hello, I've picked this forum as it is at the top of the list! :) First suggestion: A general forum for issues and comments that are not specific to a particular Zoho application. Second suggestion: Put a link on the home page to "Zoho Identity Access Manager" The first suggestion came about because I didn't know where to post the second! ;) Regards Mark
    • All new Address Field in Zoho CRM: maintain structured and accurate address inputs

      The address field will be available exclusively for IN DC users. We'll keep you updated on the DC-specific rollout soon. It's currently available for all new sign-ups and for existing Zoho CRM orgs which are in the Professional edition. Managing addresses
    • Can't upload attachments.

      I can't upload attachment in Zoho Mail.
    • Need Guidance on SPF Flattening for Zoho Mail Configuration

      Hi everyone, I'm hoping to get some advice on optimizing my SPF record for a Zoho Mail setup. I use Zoho Mail along with several other Zoho services, and as a result, my current SPF record has grown to include multiple include mechanisms. My Cloudflare
    • How use

      Good morning sir I tried Zoho Mail
    • Zoho Mail Desktop App Not Loading + Can’t Manage Multiple Accounts

      Hi everyone, I’ve been having ongoing issues with the Zoho Mail desktop app for the past few weeks. The app starts to load but gives up midway and never actually opens — there’s no error message, it just stops loading. The main reason I use the desktop
    • not able to convert pdf to jpg and other forms and vice versa.

      i want to change my pdf to jpg, word, etc and some times jpg to pdf. i don't know how to do in this.
    • Feature Request: Tag, Search, and Report on Individual Private Comments

      Zoho Desk Team, First, I want to say that we are extensive users of Zoho Desk and it is a core part of our support operations. We rely heavily on the private comments feature for internal communication, knowledge sharing, and maintaining a clear history
    • Connecting two modules - phone number

      Hi, I’d like some guidance on setting up an automation in Zoho CRM that links records between the Leads module and a custom module called Customer_Records whenever the phone numbers match. Here’s what I’m trying to achieve: When a new Lead is created
    • Changing an agents email address

      How do you change an agent's email address? I keep getting a red circle even though I am an admin. And on one of my agents he has two email addresses? How is that possible?
    • Creator Change History: Ways to improve

      Hi Everyone, Recently been working in developing this change history(an idea from Zoho Forms) - unlike forms that you can this with a click but using Creator, we can use "old" keyword. The concept I come up with is to put the result in a table however,
    • Error when sending emails from Zoho

      Hello, When trying to send an email from Zoho CRM I keep getting the below error: javax.mail.AuthenticationFailedException: 535 5.7.139 Authentication unsuccessful, the user credentials were incorrect. Any support on this will be much appreciated. Thanks,
    • Zoho Tables is now live in Australia & New Zealand!

      Hey everyone! We’ve got some great news to share — Zoho Tables is now officially available in the Australian Data Center serving users across Australia and New Zealand regions! Yes, it took us a bit longer to get here, but this version of Zoho Tables
    • Zoho Inventory - How to pay a supplier up front then receive multiple deliveries

      How do we manage situations where we pay a supplier up front, then the receive the products in increments? Example Workflow: Create Purchase Order > Receive Bill for full amount > Receive Items 2 or more deliveries. Currently, once a Bill is created against
    • Not all emails from outlook365 migrated to my new zoho account

      I recently setup a new email address hosted by zoho. I migrated all my folders and email from my Outlook365 account to my new zoho account, but not all my emails migrated. Looks like only the past 12 months, or so, made the move. How do I get the rest
    • Zoho Inventory - Composite Items - Assembly - Single Line Item Quantity of One

      Hi Zoho Inventory Team, Please consider relaxing the system rules which prevent an assembly items from consisting of a single line item and outputting a quantity of 1. A client I'm currently working with sells cosmetics and offers testers of their products
    • Clients not receiving emails

      I've been informed that my emails are not being received. Is there anything that I should look into to rectify this? Many thanks!
    • Max numbr of IMAP Accounts in Zoho Mail?

      In Zoho mail, you can manage the inboxes of other accounts using IMAP (and POP, actually) https://www.zoho.com/mail/help/external-imap-accounts.html Is there a max to the number of inboxes we can add?
    • Formula Fields Trouble

      Hi,  I can't get even a simple formula field to work and must be doing something dumb. This formula: If(Len(Trim(${Quotes.Subject}))=0,1,2) Gives the error: You used the wrong type of data in an argument. Check what you entered between the parentheses of your functions to make sure you put the right kind of data in the right place. This formula: Len(Trim(${Quotes.Subject}))=0 Gives the error: Syntax Error. Check the examples for any functions you're using to see if you formatted them correctly. Make
    • OPTED FOR STORAGE BY DESCRIPTIVE MISGUIDANCE

      We've opened a domain with three mail ids and payment has also been processed now the bill raised is for single use ID with additional storage capacity. Kindly request you to modify the purchase.
    • How can I add a new organization on Zoho Campaign

      I want to create a new organization with my Zoho Campaign
    • White Label certificate

      Hi all, About 72 hours ago, we fulfilled all steps for white labeling (CNAME to point to mail.cs.zohohost.eu), but since then the configuration page is now stuck at "generating certificate" since 3 days. When I execute an NSLOOKUP mail.webfoundry.be it
    • www.abc.com is working but abc.com is not

      I have my domain in godaddy. I have created a website using zoho sites and now I want to publish it and I tried doing it. Mapped the domain www.abc.com, abc.com. In godaddy changed the CNAME values. A, @ was parked and updated with zoho's IP address.
    • Split my account

      Hello, I recently bought an email service for a friend. But, looks like I used my personal account to buy the plan. Please split the account so that the email service stays in a different account than my personal account.
    • Next Page