Configuring a Scheduler

Configuring a Scheduler

Feature Availability

Configuring a Scheduler 

A scheduler is triggered at the specified time to complete the defined action. The action to be performed is written as a custom function using Deluge scripts in the scheduler handler. The following attributes are passed to the custom function when the scheduler is triggered: Name 
 
Name
Data Type
Description 
Network 
Map
The details of your network
User
Map
Details of the configuration owner. 
 
Let's consider a scheduler that collects the list of tasks you are assigned to for the day, from Zoho Connect and shares through a bot in Cliq. This scheduler is executed daily (Monday to Friday) at 10 AM to track the task list for the day. First, create the scheduler by giving the name, description followed by the recurring period and the time of execution. 
 
The sample code for this example case is as follows:  
  1. returnMap = Map();

    scopeId = network.get("id");//Network id on which the scheduler getting executed

    //zohoconnectoauth authtentication to fetch data from Zoho Connect

    response = invokeurl

    [

     url :"https://connect.zoho.com/pulse/api/tasks"

     type :GET

     parameters:{"dates":"today","scopeID":scopeId}

     connection:"zohoconnectoauth"

    ];

    info response;

    if(response.containKey("result") && response.get("result") == "failure")

    {

     returnMap.put("status","failure");

    }

    else

    {

     tasks = response.get("tasks").get("tasks");

     formatedDate = response.get("tasks").get("todayFormattedDate");

     rows = list();

     for each task in tasks

        {

      row = map();

      row.put("Title", task.get("title"));

      row.put("Section", "["+task.get("section").get("name")+"] ("+task.get("section").get("url")+")");

      row.put("Board", task.get("partition").get("name"));

      row.put("Status", task.get("taskStatus").get("name"));

      row.put("Priority", task.get("taskPriority").get("name"));

      rows.add(row);

        }

    //Use a message format that is compatible with Cliq

     content = "Task to be completed by "+formatedDate+".";

     message = {"text":content,"card":{"title":"Today's task", "thumbnail":"https://play-lh.googleusercontent.com/_g", "theme":"modern-inline"},"slides":[{"type":"table", "title":"Tasks", "data":{"headers":["Title","Section","Board","Status", "Priority"],"rows":rows}}]};

    info message;

    //post message on the Cliq bot using `zohocliqoauth` `

     

Trail Run

Once the scheduler is created, click the Save & Execute option found in the top-right corner of the code editor to know if the scheduler is working as intended. 
 
In certain cases, the execution of the scheduler may be marked as a 'success' even if the scheduled action is not complete. In the example case given above, the invoking of Zoho Cliq API from the function may have failed because of invalid authentication or a bad request, and the message will not be posted in the bot. However, in the logs, the result is given as 'success'. Therefore, to avoid such discrepancies, the return value of the custom function should be based on the status of the action performed.  

  1. cliqResponse=zoho.cliq.postToBot ("A new task",message, "zohocliqoauth");

    if(cliqResponse == null || cliqResponse.containKey("status") == false || cliqResponse.get("status") != "success")

    {

    returnMap.put("status","failure");

    }


In the above sample code, the scheduler execution is logged as 'success' only when the message is shared in Cliq. 

Execution Failure

If there is a failure in the scheduler execution, the configuration owner will be notified about the failure. They can access the logs and manually run the scheduler if the failure is due to errors in script, connection, or authentication until they resolve the issue. However, if there are 100 continuous failed attempts, the configuration will be automatically disabled. 
 
If you have any questions regarding schedulers, please reach out to us at support@zohoconnect.com.

      Create. Review. Publish.

      Write, edit, collaborate on, and publish documents to different content management platforms.

      Get Started Now


        Access your files securely from anywhere

          Zoho CRM Training Programs

          Learn how to use the best tools for sales force automation and better customer engagement from Zoho's implementation specialists.

          Zoho CRM Training
            Redefine the way you work
            with Zoho Workplace

              Zoho DataPrep Personalized Demo

              If you'd like a personalized walk-through of our data preparation tool, please request a demo and we'll be happy to show you how to get the best out of Zoho DataPrep.

              Zoho CRM Training

                Create, share, and deliver

                beautiful slides from anywhere.

                Get Started Now


                  Zoho Sign now offers specialized one-on-one training for both administrators and developers.

                  BOOK A SESSION







                              Quick LinksWorkflow AutomationData Collection
                              Web FormsEnterpriseOnline Data Collection Tool
                              Embeddable FormsBankingBegin Data Collection
                              Interactive FormsWorkplaceData Collection App
                              CRM FormsCustomer ServiceAccessible Forms
                              Digital FormsMarketingForms for Small Business
                              HTML FormsEducationForms for Enterprise
                              Contact FormsE-commerceForms for any business
                              Lead Generation FormsHealthcareForms for Startups
                              Wordpress FormsCustomer onboardingForms for Small Business
                              No Code FormsConstructionRSVP tool for holidays
                              Free FormsTravelFeatures for Order Forms
                              Prefill FormsNon-Profit

                              Intake FormsLegal
                              Mobile App
                              Form DesignerHR
                              Mobile Forms
                              Card FormsFoodOffline Forms
                              Assign FormsPhotographyMobile Forms Features
                              Translate FormsReal EstateKiosk in Mobile Forms
                              Electronic Forms
                              Drag & drop form builder

                              Notification Emails for FormsAlternativesSecurity & Compliance
                              Holiday FormsGoogle Forms alternative GDPR
                              Form to PDFJotform alternativeHIPAA Forms
                              Email FormsFormstack alternativeEncrypted Forms

                              Wufoo alternativeSecure Forms

                              WCAG



                                        Create. Review. Publish.

                                        Write, edit, collaborate on, and publish documents to different content management platforms.

                                        Get Started Now







                                                          You are currently viewing the help pages of Qntrl’s earlier version. Click here to view our latest version—Qntrl 3.0's help articles.




                                                              Manage your brands on social media


                                                                • Desk Community Learning Series


                                                                • Digest


                                                                • Functions


                                                                • Meetups


                                                                • Kbase


                                                                • Resources


                                                                • Glossary


                                                                • Desk Marketplace


                                                                • MVP Corner


                                                                • Word of the Day


                                                                • Ask the Experts


                                                                  Zoho Sheet Resources

                                                                   

                                                                      Zoho Forms Resources


                                                                        Secure your business
                                                                        communication with Zoho Mail


                                                                        Mail on the move with
                                                                        Zoho Mail mobile application

                                                                          Stay on top of your schedule
                                                                          at all times


                                                                          Carry your calendar with you
                                                                          Anytime, anywhere




                                                                                Zoho Sign Resources

                                                                                  Sign, Paperless!

                                                                                  Sign and send business documents on the go!

                                                                                  Get Started Now




                                                                                          Zoho TeamInbox Resources





                                                                                                    Zoho DataPrep Demo

                                                                                                    Get a personalized demo or POC

                                                                                                    REGISTER NOW


                                                                                                      Design. Discuss. Deliver.

                                                                                                      Create visually engaging stories with Zoho Show.

                                                                                                      Get Started Now









                                                                                                                          • Related Articles

                                                                                                                          • Configuring Workflows in Zoho Connect

                                                                                                                            Feature Availability Overview Workflows allow you to create a set of rules for Zoho Connect modules based on which defined actions would be performed. These rules automate the process of assigning tasks, creating events, and adding users to a Group ...
                                                                                                                          • Configuring email sending task in Custom Functions

                                                                                                                            Overview This guide provides instructions on setting up and verifying email addresses for sending emails via Custom Functions (Deluge) in Zoho Connect. Following these steps ensures secure and successful email delivery. Requirements for using the ...
                                                                                                                          • Configuring the web tab to open in a new browser tab

                                                                                                                            The URLs of websites that don't support loading or embedding their content within another app can still be added as a web tab and configured to be opened in a new browser tab. To do this: Login to your Zoho Connect network. Click the ellipsis (...) ...
                                                                                                                          • Basics of Schedulers

                                                                                                                            Feature Availability Overview Using schedulers in Zoho Connect you can automate your routine tasks without any user input. The schedulers can be set to repeat at certain intervals, such as everyday, weekly or every month. Here are a few ways to use ...
                                                                                                                          • Integrating Vantage Circle with Zoho Connect

                                                                                                                            Feature availability Overview Using Vantage Circle integration for Zoho Connect, you can offer employees timely rewards for their Connect activities via vouchers and wallet credits in Vantage Circle. What is Vantage Circle? Vantage Circle is a ...
                                                                                                                            Wherever you are is as good as
                                                                                                                            your workplace

                                                                                                                              Resources

                                                                                                                              Videos

                                                                                                                              Watch comprehensive videos on features and other important topics that will help you master Zoho CRM.



                                                                                                                              eBooks

                                                                                                                              Download free eBooks and access a range of topics to get deeper insight on successfully using Zoho CRM.



                                                                                                                              Webinars

                                                                                                                              Sign up for our webinars and learn the Zoho CRM basics, from customization to sales force automation and more.



                                                                                                                              CRM Tips

                                                                                                                              Make the most of Zoho CRM with these useful tips.



                                                                                                                                Zoho Show Resources