Automation#18: Automatically Fetch Values from Contacts to the Tickets Module

Automation#18: Automatically Fetch Values from Contacts to the Tickets Module



Hello Everyone,

Welcome to this week's edition, where you can seamlessly sync fields from the Contacts to the Tickets module. For efficient business operations, it's crucial to have details mapped across different modules.
Zylker Secure offers antivirus services with various pricing plans for its customers. Each plan purchased is stored in the Customer module. Every time a customer submitted a query, it was challenging to refer to the plan and process the requirements accordingly. Zylker Secure solved this by mapping pricing plan data from the customer record to the tickets module. This automatic sync streamlined their business operations. Let's see how to implement this automation in your Desk portal.

Prerequisites
1. Create a custom field in the Ticket and Contact layout.
    1.1 Go to Setup >> Customization >> Layouts and Fields.
    1.2 Choose the required Department and select the Ticket layout under it.
    1.3 Create a
custom field in the Ticket layout. Click Save.
    1.4 In Layouts, choose Contacts from the drop-down list for the same department.
    1.5 Click on the Contact layout and create the same custom field type in the Contacts layout.
          Click Save.  
Note: The field type in the Contacts layout must match the field type in the Tickets layout. For example, if one layout has a single line field, the other must also have a single line field. Similarly, if one has a picklist field, the other must have a matching custom picklist field.

Create a Workflow Rule
1. Go to Setup, choose Workflows under Automation.
2. Under Workflows, click Rules >> Create Rule.
In the Basic Information section,
3. Select Tickets from the drop-down menu under Module.
4. Enter a Rule Name and Description for the rule.
5. If you want to activate the rule right away, select the Active checkbox. Else, create the rule and activate it later.
6. Click Next.
In the Execute on section, follow these steps:
7. Select the Create checkbox to execute this rule every time a new ticket is created.  
8. Click Next.
9. Leave the Criteria blank and click Next.
10. In the Actions section, click the + icon and select New next to Custom Functions.
11. Enter a Name and Description for the custom function.
12. In the script window, insert the Custom Function given below:
  1. orgId = "6*********0"; // replace orgId
  2. ticketAPIName = "cf_name"; // replace API name of the custom field in Tickets layout
  3. contactAPIName = "cf_name"; // replace API name of the custom field in Contacts layout
  4. getContact = zoho.desk.getRecordById(orgId,"contacts",ContactID);
  5. customFields = getContact.getJSON("cf");
  6. updateTicket = zoho.desk.update(orgId,"tickets",TicketID,{"cf":{ticketAPIName:customFields.getJSON(contactAPIName)}});
  7. info updateTicket;
Note: In line 1, place your OrgId. To access your OrgId, go to Setup >> Developer Space >> API.
In line 2, replace the value with the API name of the custom field created in the Tickets layout.
In line 3, replace the value with the API name of the custom field created in the Contacts layout.
 
To access API name of the custom field, Go to Setup>>Customization>>Layouts and Fields >> Fields List. Select the module, and you can find the API name of the custom field created.
13. Click Edit Arguments and include the argument mapping as below: 
13.1. In the Name field type ContactID, and from the Value drop-down list select Contact Id under Contact Sections.
13.2. In the Name field type TicketID, and from the Value drop-down list select Ticket Id under Ticket Sections.
14. Click Save to save the custom function.
15. Click Save again to save the workflow.

Implementation
When a ticket is created, the custom field in the Tickets layout is updated automatically by fetching the value from the custom field in the Contacts layout.
 
See you next week with another custom function coming your way!

    Access your files securely from anywhere


            Zoho Developer Community





                                      • Desk Community Learning Series


                                      • Digest


                                      • Functions


                                      • Meetups


                                      • Kbase


                                      • Resources


                                      • Glossary


                                      • Desk Marketplace


                                      • MVP Corner


                                      • Word of the Day


                                      • Ask the Experts



                                          Zoho Marketing Automation
                                                  • Sticky Posts

                                                  • Zoho Desk Virtual Meetup: US Central, October 5 - 7, 2021

                                                    After the interactive Virtual Meetups in the other regions, we are starting with the US Central and Midwest regions from October 5 to October 7, 2021. The dates for other regions will be announced soon.  At this event, we will explore the topics which
                                                  • 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. 
                                                  • Zoho Desk Community Meetups 2019 - Canada

                                                    Hey there!  ​ Are you making the best use of Zoho Desk? Do you think meeting and learning from other Zoho users in your city would help? If yes, then Zoho User Group Meetups is the right place for you! We're happy to announce our first Zoho Desk User Group meetups in Toronto, Montreal, Quebec City, Calgary, and Vancouver. These meetups are a great place to meet local Zoho users, Zoho Desk product experts and partners, all under one roof.    Join us as we discuss some key Zoho Desk features and share
                                                  • 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. 


                                                  Manage your brands on social media



                                                        Zoho TeamInbox Resources

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

                                                                                                  • Remove Special Characters "\" using Zoho Deluge

                                                                                                    Who needs this? I don't know! I did, and I sure did not find any helpful information out there, not with this keyword though. So, if you find this article because you searched the same thing as I do, then hey, you're in luck! And do note that I am not
                                                                                                  • How do you apply field validation to a date field?

                                                                                                    We are using Sign for remote e-signature of liability waivers. The signer must enter a date of birth, and if they are a minor their legal guardian must sign for them. However we have had numerous problems with signers returning an invalid date of birth
                                                                                                  • Why is this an Invalid Collection String Error?

                                                                                                    Here's the code snippet: Enddate = EventEnd.toDate("yyyy-MM-dd"); EventCollection = Collection(); EventCollection = zoho.crm.searchRecords("Events", "(End_DateTime:starts_with:"+Enddate+")"); for each eventday in EventCollection { //create a list of events
                                                                                                  • Confirmation prompt before a custom button action is triggered

                                                                                                    Have you ever created a custom button and just hoped that you/your users are prompted first to confirm the action? Well, Zoho knows this concept. For example, in blueprint, whenever we want to advance to the next state by clicking the transition, it is
                                                                                                  • Login for test case

                                                                                                    Had a few questions regarding authentication test cases and couldn't find an answer in the the docs. 1. If an app like Zoho Creator requires authentication before providing access, do I need to create a login function and add it to each test case? 2.
                                                                                                  • Merge Tickets Directly from Contact Page in Zoho Desk

                                                                                                    Dear Zoho Desk Support Team, We are writing to request a new feature that would allow users to easily merge tickets directly from the contact page in Zoho Desk. Currently, the only option to merge tickets is from the Tickets list view page, which can
                                                                                                  • Zoho Error: This Operation has been restricted. Please contact support-as@zohocorp.com for further details

                                                                                                    Hello There, l tried to verify my domain (florindagoreti.com.br) and its shows this error: This Operation has been restricted. Please contact support-as@zohocorp.com for further details. Screenshot Given Below -  please check what went wrong. Thanks
                                                                                                  • Separate Triggers and Enhanced Information for Zoho One Departments and Groups in Zoho Flow

                                                                                                    Dear Zoho Flow Team, I hope this message finds you well. Currently, there seems to be a mix-up between zoho one departments and groups in Zoho Flow, which causes some challenges in handling triggers effectively. For instance, when using the "User added
                                                                                                  • Create Quote does not show the "Product Description" entered as part of the Product setup.

                                                                                                    The product description created as part of the product setup page, does not show in the Create Quote module; The module allows for an additional description to be added but without access to the original stored description. By selecting the product from the "Product Name Lookup" pop-up, the "Product Description" part should be populated from the product record where the user is allowed to further modify it.
                                                                                                  • Add bank transfers via a webhook or API

                                                                                                    Hello ZOHO Books Community, is there anyway to add single transactions to bank accounts via an API or webhook? I found in docs to upload a bank statement. But i want to add a transaction from an external (unsupported bank) in the moment there is a transaction
                                                                                                  • Which WhatsApp API works seamlessly with Zoho CRM?

                                                                                                    I’m exploring WhatsApp API solutions that integrate seamlessly with Zoho CRM for customer communication, lead nurturing, and automation. I would love to hear insights from those who have successfully implemented WhatsApp within Zoho CRM. My Requirements:
                                                                                                  • Multi Select Between Modules

                                                                                                    Hi, I'm not sure if this is possible, but I want to "import" or "mirror" the multi select options from one module to another. For example... I have Module "Clients" with a Multi Select Field of "Enrolled Services" I also have a Module "Services" with
                                                                                                  • Zoho Desk View Open Tickets and Open Shared Tickets

                                                                                                    Hi, I would like to create a custom view so that an agent can view all the open tickets he has access to, including the shared tickets created by a different department. Currently my team has to swich between two views (Open Tickets and Shared Open Tickets).
                                                                                                  • Is a record ID in Zoho Books always numeric?

                                                                                                    Hi Support Team, For storing Zoho Books' contact, invoice and other record IDs in an external app, I wanted to know if the IDs are always numeric. As far as I can see in Books, they are all numeric and while fetching a record via the Zoho Books API, passing
                                                                                                  • Using IMAP configuration for shared email inboxes

                                                                                                    Our customer service team utilizes shared email boxes to allow multiple people to view and handle incoming customer requests. For example, the customer sends an email to info@xxxx.com and multiple people can view it and handle the request. How can I configure
                                                                                                  • Work Orders / Bundle Requests

                                                                                                    Zoho Inventory needs a work order / bundle request system. This record would be analogous to a purchase order in the purchasing workflow or a sales order in the sales cycle. It would be non-journaling, but it would reserve the appropriate inventory of
                                                                                                  • Resubmit for Approval for Zoho Books Module in CRM

                                                                                                    The integration between CRM and Books is great, but it is incomplete in many areas. One of them is if an estimate/invoice/sales order is rejected, the users in CRM cannot resubmit it for approval. Let's face it, sales people will mostly be in CRM and
                                                                                                  • Automatically add a retainer to every estimate

                                                                                                    Hi all, I've been trying to find a way to automatically add a retainer at a set % to every estimate we create and send. So far I haven't been successful, does anyone know of a way to do this? Thanks,
                                                                                                  • New in WorkDrive: WorkDrive Genie, a quick-editing app for desktop (Beta)

                                                                                                    The WorkDrive Genie app lets you open and edit any of your WorkDrive files on the web with your default desktop applications. For example, you can open and edit files such as documents, images, and videos with Microsoft Word, CorelDRAW, and Adobe Premiere
                                                                                                  • This domain is not allowed to add. Please contact support-as@zohocorp.com for further details

                                                                                                    I am trying to setup the free version of Zoho Mail. When I tried to add my domain, theselfreunion.com I got the error message that is the subject of this Topic. I've read your other community forum topics, and this is NOT a free domain. So what is the
                                                                                                  • Kaizen #78 : How to disable clone record?

                                                                                                    Hello everyone! Welcome back to another interesting Kaizen post. In this post, let us discuss a workaround solution for the use case - How to disable clone record for a user. Requirement Consider that you want to disable the clone option for the Deals
                                                                                                  • Client Script | Update - Introducing Subform Events and Actions

                                                                                                    Are you making the most of your subforms in Zoho CRM? Do you wish you could automate subform interactions and enhance user experience effortlessly? What if you had Client APIs and events specifically designed for subforms? We are thrilled to introduce
                                                                                                  • Add Serial Number Zoho CRM Subform

                                                                                                    Hi Guys, I need to add Serial Number in Zoho CRM Subform table. In addition of an row we can easily create in Zoho Creator. But in Zoho CRM how we can do that? Any suggestion would be very helpful.
                                                                                                  • Suddenly Can't Send Outgoing Mail (SMTP)

                                                                                                    Suddenly I can't send mail anymore from my phone mail app. I have Zoho OneAuth MFA set up and an app specific password set up. It has been working correctly for a while. Has something changed with your servers or setup for SMTP? No settings have changed
                                                                                                  • Sent emails not going and showing "Processing"

                                                                                                    Hello Team, Could you please assist with sent emails showing "processing" and not actually going through? Many thanks and regards, Cycology
                                                                                                  • Shared Mailbox - Mark as read for all users

                                                                                                    Hi all, Maybe someone can help me out. At the moment we have a shared mailbox without streams. When a users reads an mail or marks it as read other users will not see this. How can we resolve this? We now archive the mails when read and followed up. However
                                                                                                  • Domain verification is in progress... (How long do I need to wait?)

                                                                                                    Trying to setup my first email domain by connecting with GoDaddy. Have been here for quite some time and the screen is not changing. How long should this take?Send DataSend Data
                                                                                                  • Multiple workflows based on stage?

                                                                                                    I am trying to have multiple things happen when I close a deal. First, I would like to send a thank you/coupon email to all deals that are closed. Second, I would like to create connected records in a separate pipeline for certain projects that qualify.
                                                                                                  • discount on total amount

                                                                                                    i want to add discount on total value of my purchase order instead of applying line by line.my customer will not accept the discount on line by line.
                                                                                                  • Important update in Zoho Forms: Enhancements for improved email deliverability

                                                                                                    Hello, form builders! We would like to inform you about some changes we're making in Zoho Forms to ensure the deliverability of your outbound emails. Changes to Gmail policies Gmail has updated its DMARC policy which quarantines emails sent with gmail.com
                                                                                                  • payment voucher, receipt printing feature

                                                                                                    Why dont ZOHO add the voucher printing feature in zoho book with authorised signatory and receiver's signature
                                                                                                  • Inventory asset or cost of goods sold ?

                                                                                                    We can only choose inventory asset for items but lots of bills for items are posted with cost of goods sold - is this all balanced correctly or should it be entered differently ?
                                                                                                  • Stock reservation in zoho for upcoming delivery

                                                                                                    Hi, Is there any option available in zoho for reserve item for a upcoming delivery. So that we can avoid the item should duplicated on another order. Means needs to deduct the item from zoho before making invoice.
                                                                                                  • Banking: Transfer from another account without base currency

                                                                                                    Scenario: A banking line item shall be categorised as an "internal transfer" from another bank account. This is a USD to EUR transfer. Our base currency is CHF. What we tried: Category: "Transfer from another account" From: Our USD account To: Our EUR
                                                                                                  • How to search records in integration task in creator?

                                                                                                    How to search using integration task in creator searchString = {"zcrm_account_id:4050082000001001499"}; contactData = zoho.books.getRecords("Contacts","xxxxxx",searchString); I get an error that third argument needs to be string, I tried to convert it
                                                                                                  • Show my cost or profit while creating estimate

                                                                                                    Hi, While creating estimate it becomes very important to know exact profit or purchased price of the products at one side just for our reference so we can decide whether we can offer better disc or not .
                                                                                                  • Outgoing emails to btinternet blocked.

                                                                                                    ERROR_CODE :421, ERROR_CODE :Too many messages (1.5.6.1) from 74.201.84.163I have been having problems sending to btinternet.com and btopenworld.com for the past week.  First 'email delayed' message, and then 'delivery failed', as above. Looks as though someone is spamming from the ZOHO email server 'sender163-mail.zoho.com' Surely this is abuse of your system, and you should be able to trace who it is (if it is a registered user of Zoho mail?) and block their account. An email system is really no
                                                                                                  • single user access to the CRM suits

                                                                                                    I am currently using Zoho CRM Plus, where the pricing for a single user is ₹3,500 INR, and it includes access to multiple applications. However, I would like to add an additional user but restrict their access to only two specific applications within
                                                                                                  • Mixed order: stock item and business purchase

                                                                                                    Hi, I'm just getting started with Inventory, and I haven't been able to find an answer to this. I am a small service business, and am just starting to sell products (in very low numbers). From my vendor, I purchase both items that I will on-sell, which
                                                                                                  • Facebook Professional Account

                                                                                                    Zoho social says there is nothing to be added when I try to add my Facebook and Instagram accounts. Both are Professional profiles. How do I go about adding them? They are not Pages or Groups, they are simply Professional accounts.
                                                                                                  • Next Page