Episode I : Exploring the World of Custom Functions in Zoho Desk

Episode I : Exploring the World of Custom Functions in Zoho Desk


Hello Again!
Welcome to an Automation Adventure in the World of Zoho Desk
Join us on a journey to explore how custom functions can enhance and extend the capabilities of Zoho Desk.
Automation is everywhere. From robotic arms assembling products on factory floors to automating tasks in the software world, automation has revolutionized how we work out stuff. But what does this have to do with Zoho Desk? 
Anline, a curious resident in the Zoho Desk world, is exploring how automation can transform her workflow.

Anline’s Quest in the Zoho Desk World  

Anline is building her own world within Zoho Desk, but she’s hit a few roadblocks. She wants to perform specific operations; like updating ticket statuses, fetching data from external services, and automate repetitive tasks. She knows Zoho Desk has the tools she needs, but where does she start?
DeskAutomate Services is here as a guide to the Automation City. The citizens of Zoho Desk World operate based on their licenses. Each license unlocks different levels of automation capabilities.
Anline has the Enterprise edition, which grants her the access to the most powerful tools: Custom Functions. How can this empower Anline?

The Power of Custom Functions  

Custom Functions are like magic spells in the Zoho Desk world. They give users flexibility to tailor automation to their exact needs. While basic automation features are available to all license holders, Custom Functions are exclusive to Enterprise users. These functions let Anline go beyond the basics and create automations that meet her unique requirements. What makes them even more accessible is Deluge, Zoho’s in-house scripting language.
But there’s a catch: Anline isn’t a coding expert in Deluge. How can she harness the power of Custom Functions without getting lost in complex scripts? DeskAutomate guides Anline to the prebuilt functions and a user-friendly framework, simplifying the coding process.
Whether you’re new to coding or an experienced developer, Deluge simplifies the process of creating Custom Functions with its intuitive interface and drag-and-drop functionality.

The Deluge Script Editor: Your Coding Playground  

To access the Custom Function window, go to Setup (S) >> Developer Space >> Functions >> New Function.
When you open the Custom Function window in Zoho Desk, you’ll find a user-friendly interface designed to help you build scripts using drag-and-drop options. Here’s what you’ll discover: Each section has predefined variables which you can drag and use based on your requirements.
1. Basic Commands
The Basic section includes essential commands like setting variables, adding comments, and inserting informational text into your script. These foundational elements help you structure your Custom Function logically.
          Example: businessDaysCount = 5; //<variable> = <expression>;
2. Conditional Logic
The Condition section allows you to add conditional operators such as if, else if, and else. These operators let you program decision-making logic into your Custom Function.
Example:
  1. if (TicketStatus == "Open")
  2. {
  3.     info "This ticket is still open.";
  4. }
3. Notifications
The notifications section lets you enter values to send emails or post messages via Cliq.
Example:
  1. sendmail
  2. [
  3. from : zoho.userid
  4. to   : support@zylker.com
  5. subject : "Ticket is created"
  6. message : "Thank you for your enquiry. A ticket has been created and our experts will respond to you."
  7. ]; 
4. Integrations
Zoho Desk makes coding easy for integrations. With drag-and-drop options, you can create webhook integrations and API calls without writing complex code from scratch. The Custom Function window provides all the necessary code snippets, so you can customize them to fit your requirements.
Example: contactRecord = zoho.crm.getRecordbyId("Contacts",9876787);
5. Collections
The Collections feature lets you gather and manage strings of data or specific information within your Custom Function. This is particularly useful when you need to process or analyze multiple data points.
Example:
  1. myList = Collect();
  2. myList.insert("ID1");
  3. myList.insert("ID2");
  4. myList.insert("ID3");
  5. for each ID in myList
  6. {
  7.    info ID;
  8. }
You can also enable the Syntax Builder within your Coding playground. Enabling this option will help you choose variables from the drop-down windows having prebuilt variables/Fields.

Mapping Parameters and Testing Your Script  

Once you’ve built your Custom Function, the next step is to map it to your Zoho Desk environment:
1. Edit Arguments
The Edit Arguments option lets you map params within your Custom Function to fields in your tickets. For example, you can link the Ticket ID, Ticket Owner, or Case ID to the corresponding fields in your Zoho Desk setup. This ensures that your Custom Function interacts seamlessly with your data.
2. Authentication and Connections
Zoho Desk uses OAuth tokens to establish secure connections for Custom Functions. Commonly, this involves using Zoho OAuth to make API calls within Zoho's scope. You can choose the appropriate scopes during authorization to ensure your Custom Function has access to the necessary data and functionalities.
Note: If you choose third-party applications, please create a connection using the required default or custom services.
3. Save and Test
After saving your script, use Save & Execute Script to test it with sample inputs. This lets you test the function, ensuring functionality, debug, and refine your code before deployment.
In the upcoming episodes, we'll dive into how Custom Functions work and contribute to expanding the capabilities within Zoho Desk.
See you in the next episode,
Regards,
Lydia | Zoho Desk. 

    Access your files securely from anywhere







                        Zoho Developer Community





                                              Use cases

                                              Make the most of Zoho Desk with the use cases.

                                               
                                                

                                              eBooks

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

                                               
                                                

                                              Videos

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

                                               
                                                

                                              Webinar

                                              Sign up for our webinars and learn the Zoho Desk basics, from customization to automation and more

                                               
                                                
                                              • Desk Community Learning Series


                                              • Meetups


                                              • Ask the Experts


                                              • Kbase


                                              • Resources


                                              • Glossary


                                              • Desk Marketplace


                                              • MVP Corner


                                                        • Sticky Posts

                                                        • Register for Zoho Desk Beta Community

                                                          With the start of the year, we have decided to take a small step in making the life of our customers a little easier. We now have easy access to all our upcoming features and a faster way to request for beta access. We open betas for some of our features
                                                        • Share your Zoho Desk story with us!

                                                          Tell us how you use Zoho Desk for your business and inspire others with your story. Be it a simple workflow rule that helps you navigate complex processes or a macro that saves your team a lot of time; share it here and help the community learn and grow with shared knowledge. 
                                                        • Tip #1: Learn to pick the right channels

                                                          Mail, live chat, telephony, social media, web forms—there are so many support channels out there. Trying to pick the right channels to offer your customers can get pretty confusing. Emails are most useful when the customer wants to put things on record. However, escalated or complicated issues should not be resolved over email because it's slow and impersonal.  When you need immediate responses, live chat is more suitable. It's also quick and convenient, so it's the go-to channel for small issues. 
                                                        • Welcome to Zoho Desk Community - Say hello here!

                                                          Hello everyone! Though we have been here for a while, it’s time to formally establish the Zoho Desk Community; we’re really happy to have you all here! This can be the place where you take a moment to introduce yourself to the rest of the community. We’d love to hear all about you, what you do, what company or industry you work for, how you use Zoho Desk and anything else that you will like to share! Here’s a little about me. I am Chinmayee. I have been associated with Zoho since 2014. I joined here
                                                        • Webinar 1: Blueprint for Customer Service

                                                          With the launch of a host of new features in Zoho Desk, we thought it’ll be great to have a few webinars to help our customers make the most of them. We’re starting off with our most talked about feature, Blueprint in Zoho Desk. You can register for the Blueprint webinar here: The webinar will be delivered by our in-house product experts. This is a good opportunity to ask questions to our experts and understand how Blueprint can help you automate your service processes. We look forward to seeing


                                                        Manage your brands on social media



                                                              Zoho TeamInbox Resources



                                                                  Zoho CRM Plus Resources

                                                                    Zoho Books Resources


                                                                      Zoho Subscriptions Resources

                                                                        Zoho Projects Resources


                                                                          Zoho Sprints Resources


                                                                            Qntrl Resources


                                                                              Zoho Creator Resources



                                                                                  Zoho CRM Resources

                                                                                  • CRM Community Learning Series

                                                                                    CRM Community Learning Series


                                                                                  • Kaizen

                                                                                    Kaizen

                                                                                  • Functions

                                                                                    Functions

                                                                                  • Meetups

                                                                                    Meetups

                                                                                  • Kbase

                                                                                    Kbase

                                                                                  • Resources

                                                                                    Resources

                                                                                  • Digest

                                                                                    Digest

                                                                                  • CRM Marketplace

                                                                                    CRM Marketplace

                                                                                  • MVP Corner

                                                                                    MVP Corner







                                                                                      Design. Discuss. Deliver.

                                                                                      Create visually engaging stories with Zoho Show.

                                                                                      Get Started Now


                                                                                        Zoho Show Resources


                                                                                          Zoho Writer Writer

                                                                                          Get Started. Write Away!

                                                                                          Writer is a powerful online word processor, designed for collaborative work.

                                                                                            Zoho CRM コンテンツ






                                                                                              Nederlandse Hulpbronnen


                                                                                                  ご検討中の方




                                                                                                        • Recent Topics

                                                                                                        • How to turn off ability to share Knowledge-base article with social networks

                                                                                                          Is there a way to deactivate the link at the bottom of a Knowledge-base article so that it can not be shared via Facebook or Twitter?
                                                                                                        • Automatically Hide Unauthorized Sections from Agent Interface in Zoho Desk

                                                                                                          Hello Zoho Desk Team, We hope you're doing well. We’d like to submit a feature request regarding the user experience for agents in Zoho Desk who do not have permission to access certain sections of the system. 🎯 Current Behavior At present, when an agent
                                                                                                        • Is there a way to prevent a user from removing a payment method on a live, recurring subscription?

                                                                                                          As it stands, if you allow users to remove payment methods, they can do so on live subscriptions. This leaves the sub without a payment method. The user should be able to REPLACE the card with a new one, but not remove all payment methods. We have had
                                                                                                        • Assistance Required: Report Export to Excel and WorkDrive Upload via Deluge

                                                                                                          I'm working on automating a scheduled workflow in Zoho Creator that needs to run weekly. The goal is to: Export a report from Zoho Creator in Excel (.xls or .xlsx) format, and Upload the exported file to a specific folder in Zoho WorkDrive using a Deluge
                                                                                                        • Kanban View for Projects.

                                                                                                          At our organization, we describe active projects with various statuses like "In Proofing" or "Printing" or "Mailing". In the Projects view, one can set these project statuses by selecting from the appropriate drop-down. While this works, it's difficult to view and comprehend the progress of all of your projects relative to each other in a table. Creating a Kanban view for projects where I can move them from one status to another allows me to see where each project is in the order of our workflow.
                                                                                                        • Zoho Projects - Q2 Updates | 2025

                                                                                                          Hello Users, With this year's second quarter behind us, Zoho Projects is marching towards expanding its usability with a user-centered, more collaborative, customizable, and automated attribute. But before we chart out plans for what’s next, it’s worth
                                                                                                        • Useful enhancements to Mail Merge in Zoho CRM

                                                                                                          Dear Customers, We hope you're well! We're here with a set of highly anticipated enhancements to the Mail Merge feature in Zoho CRM. Let's go! Mail Merge in Zoho CRM integrates with Zoho Writer to simplify the process of customizing and sharing documents
                                                                                                        • Send Whatsapp with API including custom placeholders

                                                                                                          Is is possible to initiate a session on whatsapp IM channel with a template that includes params (placeholders) that are passed on the API call? This is very usefull to send a Utility message for a transactional notification including an order number
                                                                                                        • How can I see the actual copy sent to the specific contact?

                                                                                                          I have setup a journey in Marketing Automation and created addition of contact in a specific list as the trigger, emails are sending to the contacts, but I can't see the actual copy sent to any specific contact in the list. Please guide me, where can
                                                                                                        • Client Script for Task Module

                                                                                                          When do we expect the client script for the tasks module?
                                                                                                        • Automating Employee Birthday Notifications in Zoho Cliq

                                                                                                          Have you ever missed a birthday and felt like the office Grinch? Fear not, the Cliq Developer Platform has got your back! With Zoho Cliq's Schedulers, you can be the office party-cipant who never forgets a single cake, balloon, or awkward rendition of
                                                                                                        • Empowered Custom Views: Cross-Module Criteria Now Supported in Zoho CRM

                                                                                                          Hello everyone, We’re excited to introduce cross-module criteria support in custom views! Custom views provide personalized perspectives on your data and that you can save for future use. You can share these views with all users or specific individuals
                                                                                                        • Product and Service

                                                                                                          Hi guys, there is a difference between layout of product and service if Long Description field have some kind of text. Please see screenshot 1 for Service here: https://prnt.sc/7xWwPKd29nWP for Product here: https://prnt.sc/LGmtVd_U6H7q As you can see
                                                                                                        • Create Project while winning potentials - Projects v3 api updated code

                                                                                                          Hi all, I've been using the built in function to create a project while a deal is closed won and noticed it had some missing fields when trying to reference the zoho projects v3 api documentation. Specifically the project group had some issues when adding
                                                                                                        • Formula Fields inside of Blueprint Transitions

                                                                                                          We would like to have formula fields inside of blueprint transitions. We type in currency fields and would like to see the result inside of a formula field. Our use case: Send out a price for XY 1. Filling out cost fields 2. See gross profit
                                                                                                        • ZOHOBOOK Sales_QUOTE: To Add Discount At Each Line Item Table

                                                                                                          Hi, Our quote need to display with discount at each line item level as well. Try to edit template, >CUSTOMISE>EDIT TEMPLATE> Table, I can see template view with discount column, but when hit SAVE the template, view in PDF the discount column not shown.
                                                                                                        • inventory based on bills and not physical stock

                                                                                                          Hello, I have noticed a very annoying issue with zoho books/inventory. I use composite items. If I have an sub assembly item on back order, I am unable to make up the composite item, even when I have received the goods and it is in my stock. I have to convert the PO into a BILL in order for the item to show as 'Accounting Stock'. The problem is that the supplier Invoice is not shipped with the goods, but can follow even a week later. So I have to make the bill have a 'dummy name and number' until
                                                                                                        • Sort, filter & save views for BOOKS PROJECTS

                                                                                                          Thanks for all the updates. Our firm uses the module for simple internal project accountancy. This means we do everything from the Projects Section but this isn't user friendly at all. You can't do anything with customized your own fields which basically
                                                                                                        • Using Zoho Inventory for managing Item compatibilities

                                                                                                          Use case: Using Zoho Inventory for managing (as an example) aftermarket car parts, where a single part can suit many makes, models and years. How do most businesses assign and manage compatibility for each part? Do ZI users typically do this using multi-select
                                                                                                        • Unable to enter manual journal entries in AR/AP.

                                                                                                          Hi there, i am facing some problem relating to AR/AP. I want to make some entries in AR/AP through manual journal. for example. some time I send cash 500 to Mr. A (Customer) for any purpose and then after 2 or 3 days Mr. A returned back 700 to me and
                                                                                                        • Questions regarding WorkDrive

                                                                                                          Here are my questions regarding WorkDrive: Does WorkDrive have a limit on the number of downloads? What will happen if a file is downloaded excessively? Does WorkDrive have any restrictions on download speeds? Are there any limitations on downloading
                                                                                                        • How to record tips from customers

                                                                                                          I run a cleaning service business and on occasion customers include a tip with their check payment. How can I record the amount paid for service and the tip separately? Any amount over the invoice is looked at as an overpayment and suggest a credit note
                                                                                                        • Multi-currencies in Zoho Books

                                                                                                          I'd like to request multiple currencies in Zoho Books. I have customers paying in USD, CAD, CNY. I need to bill customers in these currencies too. I can set up a base currency, and then set up a exchange-rate table to convert these currencies.
                                                                                                        • Facturation électronique 2026 - obligation dès le 1er septembre 2026

                                                                                                          Bonjour, Je me permets de réagir à divers posts publiés ici et là concernant le projet de E-Invoicing, dans le cadre de la facturation électronique prévue très prochainement. Dans le cadre du passage à la facturation électronique pour les entreprises,
                                                                                                        • I want refund of Zoho standard subscription on WEB payment

                                                                                                          Hi, Kindly help to refund the WEB payment made on 13/07/2025 for Zoho standard annual subscription. I didn't find the software useful for my project. Regards
                                                                                                        • Is Conditional display of field(s) possible in a Canvas Customer Portal?

                                                                                                          Is Conditional display of field(s) possible in a Canvas Customer Portal? How?
                                                                                                        • How do I set users up to only send emails using org emails?

                                                                                                          We run marketing campaigns for multiple clients and strictly send emails using the official organization addresses provided by each client. However, we've encountered several instances where users unintentionally send emails from their own company accounts—a
                                                                                                        • Pick List Issues

                                                                                                          I have created a pick list that looks at a table in a sheet, it selects the column I want fine. Various issues have come along. The option to sort the pick list is simplistic, only allows an ascending alphabetical sort. Bad luck if you want it descending.
                                                                                                        • Automate Backups

                                                                                                          This is a feature request. Consider adding an auto backup feature. Where when you turn it on, it will auto backup on the 15-day schedule. For additional consideration, allow for the export of module data via API calls. Thank you for your consideration.
                                                                                                        • View Linked Subscription on Invoice list

                                                                                                          When looking at the list of invoices in billing is it possible to see the subscription that an invoice is for. This would allow you to see if it's a subscription a customer is behind on, or they simply haven't paid a one time invoice.
                                                                                                        • Customer Payment

                                                                                                          Seprate voucher required for cash and bank .You can not authorized any one to enter cash payment .In statement clearly shown is it bank receipt or cash recipt .
                                                                                                        • Recording Credit Card Fees when Recording Payment for Bills

                                                                                                          It seems I am unable to record credit card fees when paying a bill. I pay close to 100% of my bills with a company credit card via online portals. I'm happy for the CC fess to be recorded as Bank Charges but it will not allow that field to be used if
                                                                                                        • Workerly/Zoho One Pricing

                                                                                                          Hi What is the pricing model that is suppose to be as a Zoho One user? If i use the services of a freelancers or temp workers (Sometimes for a few hours a week/month), I need to purchase a zoho one license for each of them as well as workerly licenc
                                                                                                        • DKIM

                                                                                                          I have my DKIM in Titan, which is another email service provider. I get this notification on my portal. What shall I do? ( Improve the deliverability of emails sent from Zoho Social by adding DKIM (DomainKeys Identified Mail) records to your DNS settings.
                                                                                                        • Update Lead Status in Zoho CRM When a Meeting is Booked via Microsoft Bookings

                                                                                                          Hi everyone, I’m trying to streamline our lead management process and would like to automatically update the Lead Status in Zoho CRM whenever a meeting is booked through Microsoft Bookings. Has anyone successfully implemented this kind of integration
                                                                                                        • Show All Notes For A Single Record

                                                                                                          I would like to be able to view a list of all Notes for a particular record. We can add several (unlimited) Notes for the Leads, Contacts, Accounts and Potentials records. The subject line and some of the note content for up to 10 notes is visible on the first page. You can select the arrow to view additional notes in the list. I would like a button next to the New Note button that says View All. This would bring up a printable list of all notes listed in descending order by Modified Time (newest
                                                                                                        • Zoholics Europe 2025: Build Smarter with the Zoho Creator Low-code Workshop!

                                                                                                          Why should you attend? This year, Zoholics Europe 2025, Zoho’s official user conference, is your opportunity to connect directly with the teams behind the tools you use every day. Don’t miss one of the most requested sessions: dedicated, hands-on workshop
                                                                                                        • Assigning multiple roles to a user in Creator

                                                                                                          Hi I find we can assign only one role and permission to an user in creator. There is a requirement to assign multiple roles and corresponding permission to one user. Is there any solution or workaround for this? Refer the screenshot below
                                                                                                        • 【Zoho CRM】ウィザード機能のアップデート:セクション要素の追加

                                                                                                          ユーザーの皆さま、こんにちは。コミュニティチームの中野です。 今回は「Zoho CRM アップデート情報」の中から、ウィザード機能のアップデートをご紹介します。 ウィザード機能に新たに「セクション要素」が追加されました。 各ウィザード画面内で項目、テキスト、サブフォーム、ウィジェット要素などをより柔軟に整理できるようになりました。 セクション要素とは? ウィザードの中で、関連する項目や要素をひとつの「サブエリア」 としてまとめられる新しい構成要素です。 セクション要素活用メリット 入力内容やプロセスによっては、より細かな構造や階層化が求められる場合があります。
                                                                                                        • Edit PDFs from within your web app using Zoho Office Integrator

                                                                                                          Hi users, We are excited to introduce PDF editing capabilities in Zoho Office Integrator. You can now open, edit, and collaborate on PDFs from within your web app—in addition to documents, spreadsheets, and presentations—and save them in your configured
                                                                                                        • Next Page