Custom Functions for Tasks

Custom Functions for Tasks

Automate your tasks workflow using Custom Functions.  A custom function is a software code that can be used to automate a process. In Deluge, you can write your own function and call it from one or more  Workflow  rules. It is similar to Javascript's built-in functions such as DATE, CONCAT, REPLACE, and so on. Custom functions allow you to automate a notification, call a webhook, or perform logic immediately after a workflow rule is triggered.

For e.g., a custom function can be used to create a successor task for a parent task. To achieve this, you will need to create a custom function as given below:

Add the parameters as shown:

Enter the below code in the Deluge editor:
  1. dependencyType = "FS";
    values_map = Map();
    values_map.put("description","Sample Deluge Script For Sub task Creation");
    createTaskResponse = zoho.projects.create(portalId,projectId,"tasks",values_map);
    if(createTaskResponse != null && createTaskResponse.get("tasks") != null)
        taskInfo = createTaskResponse.get("tasks").get(0);
        newTaskId = taskInfo.get("id_string");
        dependencyParam = Map();
        info dependencyParam;
        info "------------------";
        projectsAPIEndPoint = "";
        dependency = invokeurl
            url :projectsAPIEndPoint + "/portal/" + portalId + "/projects/" + projectId + "/taskdependency/"
            type :POST
        info dependency;
        info "-------------------------------------";
    return "success";
Click Save and Execute to run this custom function. You must now associate this function to a Workflow rule and save the rule.

When the criteria is met, the Custom Function will be triggered an a successor task will be created.
Feature Availability: Latest Enterprise plan.


  1. Integrate with Zoho Apps or third party apps.
  2. Automate repetitive task functions.
  3. Associate with workflow rules to set conditions

Add a Custom Function

  1. Click  in the top navigation bar.
  2. Navigate to Marketplace and click Custom Functions under Developer Space.
  3. Select Tasks  from the dropdown box.
  4. Click Create Custom Function.
  5. Enter a Function Name and a Description.
  6. Select a Layout and set the Arguments.
  7. Type in your code in the Deluge script editor or drag and drop the parameters available in the left panel of the editor and customize them.
  8. Click Save.
  9. Click Save and Execute to execute the custom function immediately.
  10. Enter a task ID or search and fetch the task ID to execute the custom function.

If an error occurs while mapping or executing a Custom Function to a Blueprint or Workflow Rule, it can be viewed in the Failure Log.  Click and select Failure Log.

Associate a Custom Function to a Workflow Rule

  1. Click   in the top navigation bar.
  2. Navigate to Task Automation and click Workflow Rules.
  3. Select a rule.
  4. Under Add Actions, click Associate Custom Function.
  5. You can associate an existing Custom Function or create a new one.
  6. Click Save Rule.

Associate a Custom Function to a Blueprint

  1. Click   in the top navigation bar.
  2. Navigate to Task Automation and click Blueprint.
  3. Select a Blueprint.
  4. Under After, click on Custom Function.
  5. Click Add to associate a custom function or to create a new one.
  6. Click the Publish button.

  1. You can add upto 25 custom functions per layout.
  2. When creating a custom function, a maximum of 25 parameters is allowed.
  3. The maximum number of custom function failure per day is 20. If a custom function's failure count is reached, it will be disabled automatically, and the user who created the custom function will be notified via email.
  4. In a portal, a maximum of 5000 custom functions can be executed per day by Workflow Rule/Blueprint.
We have a few pre-defined gallery functions that are ready to use.
  1. Click  in the top navigation bar.
  2. Navigate to Marketplace and click Custom Functions under Developer Space.
  3. Select Tasks  from the drop-down box.
  4. Click on the drop-down next to the Create Custom Function button.
  5. Click Gallery Function.
  6. Hover over any of the listed functions and click Create.

  7. Change the description and arguments if needed.
    The deluge code is prefilled. The TODO lets users know the edits to the code before it can be executed.

  8. Click Save or Save and Execute to run the custom function.
  1. Milestone Autocomplete
  2. Push Due Date change to Analytics
  3. Send message in Slack channel
  4. Send message in Cliq channel
  5. Update project status
  6. Change the successor tasks status
  7. Create successor task
  8. Create subtask
  9. Create an issue for the task
  10. Push status timeline to analytics

Other Actions

Users can edit, delete, clone, or enable REST APIs for a custom function.
  1. Hover over a custom function and then click icon.

  2. Select the required option and make the necessary changes.
    Edit: Modify the existing custom function
    Delete: Deleted the existing custom function
    Clone: Create a copy of the custom function
    Rest API: Enable the REST API url for the custom function.

See Also

    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

                                    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

                                          Zoho Desk Resources

                                          • Desk Community Learning Series

                                          • Digest

                                          • Functions

                                          • Meetups

                                          • Kbase

                                          • Resources

                                          • Glossary

                                          • Desk Marketplace

                                          • MVP Corner

                                          • Word of the Day

                                            Zoho Marketing Automation

                                              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 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

                                                                                                      • Tasks

                                                                                                        The Overview - Tasks section provides a comprehensive view of all open tasks across all projects in a portal. Users can customize their view using a drop-down menu and choose between List, Gantt, or Kanban views. The List and Gantt views allows to ...
                                                                                                      • Tasks

                                                                                                        The Tasks section displays a comprehensive list of tasks within a project. By default, the section shows users all open tasks in the List view. Users have the option to switch between different views—either default or custom—through a drop-down menu. ...
                                                                                                      • Custom Functions for Projects

                                                                                                        Automate your project workflow using Custom Functions. A custom function is a software code that can be used to automate a process. In Deluge, you can write your own function and call it from one or more Workflow rules. It is similar to Javascript's ...
                                                                                                      • Custom Functions for Issues

                                                                                                        Automate your issues workflow using Custom Functions. A custom function is a piece of code that can be used for automating a process. You can write your own function in Deluge and call it from one or more business rules. It is similar to the built-in ...
                                                                                                      • Workflow Rules for Tasks

                                                                                                        Workflow rules help you to organize the tasks more efficiently by setting criteria and actions that meet your project requirements. For the Workflow Rule to work, you need a trigger that executes the rule and an action that is carried out ...
                                                                                                        Wherever you are is as good as
                                                                                                        your workplace



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


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


                                                                                                          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