Custom functions

Custom functions

Automate your issues workflow using Custom Functions.

What Is a Custom Function?

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 functions in Javascript like DATE, CONCAT, REPLACE, etc. In Zoho Projects, you can update the issue fields automatically using business rules. With the help of custom functions, you can automate a notification, call a webhook, or perform logic right after a business rule is triggered.

Feature Availability: Enterprise plan only

Business Scenarios

  • When an issue is escalated, its project manager can be notified via an SMS, an email or a Zoho Chat using custom functions.
  • When an issue's severity is updated, a relevant comment can be added to the issue via a custom function.
  • Integration can be done with Zoho Apps and third party apps in a custom function.

Add a Custom Function

  1. Click in the top navigation bar.
  2. Navigate to Issue Settings and click Automation.
  3. Select Custom Functions from the left panel.
  4. Click New Custom Function in the upper-right corner of the page.
  5. Enter a Function Name and a Description.
  6. 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.

Helen wants to notify a set of users in her project about the change of issue owner for a specific issue upon escalation. She might have to send the notification very often to the same set of users on this subject in the future as well. So, Helen decides to create a custom function and get it called through one of the business rules. This is how her custom function will look.

 Associate a Custom Function With a Business Rule

  1. Click  in the top navigation bar.
  2. Navigate to Issue Settings and click Automation.
  3. Select Business Rules from the left panel.
  4. Select a rule and navigate to Rule details -> Criteria -> Actions.
  5. In Actions, click Call Custom Function.
  6. Click the plus icon  to create a new custom function or click the chain icon  to call an existing function from the business rule.
  7. Click Save Rule.

Learn More about configuring business rules.

Execute a Custom Function

  1. Navigate to Issue Settings->Automation->Custom Functions.
  2. Click the function that you would like to execute. Here, Helen tries to execute the function "Send_Mail".
  3. Click Save and Execute at the bottom.
  4. Enter the Issue ID (i.e, the argument).
  5. Click Execute.

 Test Custom Function Integration

  1. Add test data in Zoho Projects that match your business rule criteria.
  2. Check for updates received from Zoho Projects in your application via a notification triggered through your custom function.
  3. If there is an error, modify your custom function in Zoho Projects and retest.
  4. Continue testing until you get the correct output. Here, John Marsh, Victor Young, and Lin Brenn receive a notification from Helen on the change in issue ownership.
You can add upto 10 arguments.


    • Related Articles

    • Custom Functions

      Custom functions help in automation where procedural logic is required, which cannot be implemented with the default actions such as, Tasks, Webhooks, etc. With custom functions you can automatically update the data in the related Zoho Recruit ...
    • Manage Custom Functions

      Custom functions allow users to develop and execute user-defined functions using Deluge. You can execute simple program snippets to automate processes, or integrate with third-party or Zoho applications.    Business Uses for Custom Functions Custom ...
    • Custom Functions

      The Manage Business icon in the top menu bar is your go-to for managing all of your booking preferences. This page discusses Custom Functions. Aside from the default flow of a customer booking, you can define additional workflows at each stage of the ...
    • Functions

      Functions are the building blocks for developing an extension. They come handy for all server side customization. Sigma executes functions without additional infrastructure cost. External function calls can be done using rest APIs. You have to ...
    • Custom Functions

      Zoho Recruit Custom functions help you to update data in related Recruit modules or third-party applications by executing simple program scripts. When a record matches the workflow criteria, workflow engine automatically triggers the custom ...