Kaizen #126 - Circuits in Zoho CRM - Part 1

Kaizen #126 - Circuits in Zoho CRM - Part 1

Hello everyone!
Welcome back to another week of Kaizen!
Today, we will discuss an exciting topic—Circuits in Zoho CRM.

For starters, we will discuss what Circuits are, how beneficial they are for businesses, different views of a Circuit, and the different states and flow controls.

In the next post, we will discuss associating a Circuit to a blueprint, workflow, and a button, testing and execution, and see a Circuit in action with an interesting use case.

What are Circuits in Zoho CRM?

We use different microservices to accomplish our business needs, but most of the time, we are forced to switch over to multiple places.

With Circuits in Zoho CRM, you can integrate multiple microservices in a single platform and create automated workflows, all within your CRM!

For example, consider that you have an e-commerce application that involves multiple processes like tracking inventory, payment processing, fulfilling and tracking orders, generating receipts and reports, etc.
Typically, you would code this entire logic and use it to fulfill your business needs. But, with Functions in Zoho CRM, you can write the logic for each of these individual processes and simply orchestrate them using Circuits.

So, for the above example, you can simply create an automated workflow using Circuits and use the functions in the right order. That's not just it! You can re-use these functions elsewhere, too.

Another simple example of a Circuit is when you want to automating sending SMS alerts to users when an event occurs. How this is different from a workflow is that in this circuit, you can have a function that triggers an SMS alert, and also a function that sends an email to the user when the SMS alert ails. This involves circuit's functional states and a decision making state.
Like this, the use cases of circuits are endless.

Advantages of Circuits

  • Automate your routines
    Convert all your manual routines to automated workflows to save time. Avoid the need to trigger or interrupt applications to control the system flow, as you can create smooth-sailing, smart workflows that control themselves.
  • Scale fast
    Handle any number of requests hassle free as your workflows get executed on cloud. While Zoho Circuit dynamically allocates resources on need, you can focus more on building your applications rather than managing them.
  • Update in minutes
    Building the business logic of your applications in workflows empowers you to update the applications quickly. Swap or reorganize the components easily and build the modified applications in minutes.
  • Low-code
    Create a circuit effortlessly with the visual drag-and-drop interface, which makes it easier for the users with minimum coding knowledge.
  • Developer-friendly
    Circuits help you manage parallel processes, service integrations, spot failures, retry, and view logs, within minutes. Developers can focus on the business logic and not worry about these factors.
  • Orchestrate CRM Functions
    Use various CRM functions on your circuit to integrate multiple third-party apps and Zoho CRM seamlessly. Write functions once, and orchestrate them in circuits to solve different business needs.
  • Automate IT and business processes within CRM
    Create a circuit, associate it with a workflow, blueprint, or button, and automate your entire business process. With high availability, scalability, and fault tolerance, circuits ensure the performance of your workflow remains consistent even with changing states and an increase in frequency.
  • Diagnose errors and view audit logs
    A detailed log of each execution provides the status of each state's task execution, the payload and parameters passed, and the responses and exceptions generated.
  • Use Existing Functions
    From picking functions you've already tried, tested, and are up and running in your CRM account, to using a circuit within another circuit, this flexibility opens up possibilities of handling so much of your out-of-the-box requirements in a single space.

How are Circuits different from Workflow Rules and Blueprints?

Circuits is simply an orchestration of functions with powerful state management capabilities, along with in-built flow controls to automate the business process.

Workflow rules help us automate repetitive tasks and standardize business processes within the CRM system.
Workflow rules are useful in simple automations that the sales person does on a regular basis, like sending an email after record creation.

Builder View and Code View of a Circuit

Builder View


This view offers an easy drag-and-drop interface to build your circuit. The left pane in this view comprises all the states that can be added to a circuit.
The right pane comprises Configuration and Input/Output.

The Configuration tab lets you give a name to the state, choose its type, and select its next state.



The Input/Output tab allows you to control how JSON data must flow from one state to another through Paths.
Paths are strings beginning with $ that identify the components within the JSON. Specific parts of a JSON can be accessed by denoting their attributes in Input Path, Result Path, and Output Path.


This tab contains the following.

1. Input Path
Input path selects parts of the input JSON to pass to the state. You can also pass parameters to the input as a collection of key-value pairs. The values of Parameters can either be static or parts of the input JSON selected as a Path. For example, if your state's input is
{
"Entry1": {...},
"Entry2": {...}
}
then, you can apply the input path as $.Entry2 within the state definition. So, only the data inside the "Entry2" object will be passed as input to the state.

2. Result Path
After the input is processed by the state, Result Path selects what combination of the state result and the actual state input has to be passed to the output.

3. Output Path
Output Path further filters the data from the Result Path to pass it as state output.

Code View of a Circuit


In Code View, you can define your state machine in a simple JSON-based, structured language. Once a circuit is created, a sample workflow with the pass state as 'State 1' is created by default.

States of a Circuit and Flow Controls

Circuits offer a cascading structure to different states in a business process, allowing you to write functions that each feed their output into the next one, or any other one you pre-define, individually. You can also reroute, pause for a certain period, or feed it in batches to enable just about any sort of action.
Simply put, Circuits have different 'functional states' and 'flow controls' that allow you to automate execute your business process.

Flow Controls

Flow Controls let you control the flow of your circuit. To achieve this, Circuits make use of different states that allow you to make the execution, 'Wait' for another state, 'Pass' the input of a state to another, use 'Success' and 'Failure' to stop the execution of the Circuit.



The different states available are:
  • Pass: Transfers the input from one state to another.
  • Branch: Decides between branches of execution based on input.
  • Parallel: Performs simultaneous executions.
  • Wait: Inserts a delay for a specific time. The maximum wait time is 30 days.
  • Batch: Implements multiple group executions. You can have a maximum of 10 jobs per batch.
  • Success: Terminates an execution, returning 'Success'.
  • Failure: Terminates an execution, returning 'Failure'.
For more details on states, refer to this article.

Zoho CRM

Zoho CRM states help you execute business logic in circuits with respect to the data available in CRM.



You can write functions in the built-in editor or orchestrate existing ones, get the details of a record as an input to other the states, get the details of your org, user, CRM variables and use them in your Circuit.
You can also trigger another Circuit within a Circuit using the 'Circuit' flow control.

'Function' State
Use this state in your Circuit to use an existing function in CRM. Depending on your need, you can configure the input and output, and control data flow in your circuit. Only the functions that are REST API-enabled are shown here.



'Circuit' State
You can use another Circuit in one of the states and configure the flow accordingly.



'Record' State
This state fetches the details of a particular record in a module in CRM. You can choose to pass a portion or all of this state's result as an input to the next state in the circuit. Note that the information displayed will be based on the scope provided to the user.
Depending on where the Circuit is associated(Blueprint, Workflow, Button - Create/Clone/Details/Edit View pages, individual record, mass action), the response of the Record State differs.

'Org' State
This state gives you the details of your CRM org that you can use in your circuit.

'User' State
Use this state in your circuit to get the details of the current user in your org and process this information in other states.

'Org Variable'
This state gives you the details of all CRM Variables in your org.

Error Handling

When you use any of the Zoho CRM states, you can also perform error handling as these functional states tend to have runtime errors.

On TimeOut

When a functional state runs longer than the expected time, timeout errors occur. For handling timeout errors in code view, the field value "errorType": "Error.TimeOut" will be added.

On Execution Failure

When a state's execution fails due to some exception that cannot be processed, it can be handled using execution failure. In code view, key-value "errorType": "Error.ExecutionFailure" is appended.

Custom Error

You can also have custom error handling for your states.
Configure Exception Type and Exception Value to set the error handling options based on the error code or error message delivered by the state's output.
Retry the function in case of failure or timeout, set the Attempt (number of retries) and Delay (wait time after failure for every retry attempt).
In case of failure, if the retries fail to fix the error, the State will Fallback the error output to the Next state in the Result field.

We hope you found this post useful. Stay tuned for part 2!
Let us know if you have any questions or suggestions.


Cheers!
Shylaja S



    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





                                                          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

                                                                                            Get Started. Write Away!

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

                                                                                              Zoho CRM コンテンツ






                                                                                                Nederlandse Hulpbronnen


                                                                                                    ご検討中の方




                                                                                                          • Recent Topics

                                                                                                          • Live webinar: Mastering data migration, organization, and team collaboration

                                                                                                            Hello everyone, We’re excited to invite you to our upcoming live webinar! Discover how to seamlessly migrate your data, optimize file organization, and boost team collaboration using Zoho WorkDrive’s powerful features. This is a fantastic opportunity
                                                                                                          • BARCODE PICKLIST

                                                                                                            Hello! Does anyone know how the Picklist module works? I tried scanning the barcode using the UPC and EAN codes I added to the item, but it doesn’t work. Which barcode format does this module use for scanning?
                                                                                                          • Join our live webinar: Explore the WorkDrive TrueSync application!

                                                                                                            Hello everyone, We are thrilled to invite you to a live webinar focused on mastering the WorkDrive TrueSync application. Discover how to seamlessly sync your content between the cloud and your computer, ensuring smooth and efficient file management. Our
                                                                                                          • Bug tracking

                                                                                                            Hi, does anyone know how to track errors during picking or packing? This way I can keep track and see how to improve and prevent errors in this area.
                                                                                                          • Can the Product Image on the Quote Template be enlarged

                                                                                                            Hello, I am editing the Quote Template and added ${Products.Product Image} to the line item and the image comes up but it is very tiny. Is there anyway that you can resize this to be larger? Any help would be great! Thanks
                                                                                                          • Zoho Creator customer portal limitation | Zoho One

                                                                                                            I'm asking you all for any feedback as to the logic or reasoning behind drastically limiting portal users when Zoho already meters based on number of records. I'm a single-seat, Zoho One Enterprise license holder. If my portal users are going to add records, wouldn't that increase revenue for Zoho as that is how Creator is monetized? Why limit my customer portal to only THREE external users when more users would equate to more records being entered into the database?!? (See help ticket reply below.)
                                                                                                          • Script Editor not an option

                                                                                                            I am trying to apply a script to a sheet and Script Editor is not an option. I don't want to go outside Sheets to do this (like Creator) if it can be done inside Sheets.
                                                                                                          • Send Automated WhatsApp Messages and Leverage the Improved WhatsApp Templates

                                                                                                            Greetings, I hope all of you are doing well. We're excited to announce a major upgrade to Bigin's WhatsApp integration that brings more flexibility, interactivity, and automation to your customer messaging. WhatsApp message automation You can now use
                                                                                                          • Envio de mails

                                                                                                            Hola! No puedo enviar mails pero si recibirlos. No se como solucionarlo! Mi dominio es chidobebes.com.ar
                                                                                                          • ERROR CODE :554 - Your access to this mail system has been rejected due to poor reputation of a domain used in message transfer

                                                                                                            In my email configuration: The domain's MX Records are pointed to Zoho The domain's SPF Records have been pointed out successfully DKIM is enabled. DMARC Record is pointed for the domain. The domain name is digioorja.in. Still facing the issue of Error:
                                                                                                          • This Operation has been restricted. Please contact support-as@zohocorp.com for further details

                                                                                                            l tried to verify my domain (casalimpaeperfumada.com.br) and its shows this error: This Operation has been restricted. Please contact support-as@zohocorp.com for further details.
                                                                                                          • SLOW EMAILS

                                                                                                            Is there an issue with the Zoho server? For two days now I've been having issues with very long buffering. Please advise. Thank you.
                                                                                                          • POP3 authentication error - SOLVED

                                                                                                            Just in case others are as forgetful as me ... As Zoho has changed the POP server for personal and free organisational users, I needed to change the POP server on my email client. This failed persistently but eventually I remembered that I had chosen
                                                                                                          • Solution to Import PST File into Office 365.

                                                                                                            MailsDaddy OST to Office 365 Migration Tool is an outstanding solution to recover OST files and migrate them into Office 365 without any hassle. Using this software users can multiple OST files into Office 365 with complete data security. It offers users
                                                                                                          • Add Zoho One Groups/Departments to Shared Mailbox Access

                                                                                                            Hi, I hope you're doing well. Currently, in Zoho Mail, I can manually add specific users or the entire organization to a shared mailbox. However, there is no option to add Zoho One groups or departments. Feature Request: We would like the ability to assign
                                                                                                          • Allow Filters with Only Special Characters in Zoho Mail

                                                                                                            Hi Zoho Mail Team, I hope you're doing well. We have noticed that currently, Zoho Mail does not allow creating filter criteria using only special characters, such as = or #. However, there are scenarios where such a filter is necessary. For example: Filtering
                                                                                                          • How to save email as PDF?

                                                                                                            I saw 2 previous threads about this. One is from 14 years ago. The other was closed as "answered" a year ago but the feature was never implemented: https://help.zoho.com/portal/en/community/topic/how-to-download-save-emails-as-pdf Is the "save as PDF"
                                                                                                          • Flexible plans

                                                                                                            Hi, I have a Workplace Standard subscription. On Zoho's website, it mentions that with the annual plan it's possible to have multiple plans under the same organization—for example, Workplace Standard and Mail Lite. However, I can’t find a way to do this
                                                                                                          • Weekly Tips : Teamwork made easy with Multiple Assignees

                                                                                                            Let's say you are working on a big project where different parts of a single task need attention from several people at the same time—like reviewing a proposal that requires input from sales, legal, and finance teams. Instead of sending separate reminders
                                                                                                          • Cannot give public access to Html Snippet in Zoho Creator Page

                                                                                                            Hi, I created a form in Zoho Creator and published it. The permalink works but I want to override the css of the form. (style based URL parameters is not good enough) So I created a page and added an Html snippet. I can now override the css, which is
                                                                                                          • Weekly Tips : Customize your Compose for a smoother workflow

                                                                                                            You are someone who sends a lot of emails, but half the sections in the composer just get in your way — like fields you never use or sections that clutter the space. You find yourself always hunting for the same few formatting tools, and the layout just
                                                                                                          • Unable to confirm Super Admin assignment — confirmation button not working

                                                                                                            I’m trying to change the roles within my organization. I am currently a super admin and would like to add another user as a super admin. When I attempt to confirm the action, a screen appears asking for my password to verify my identity. However, when
                                                                                                          • Installing EMAIL Setup in New Domain

                                                                                                            Respected Support team, I'm facing an issue with cloudflare in Pakistan, I want to setup Zoho Mail Setup but I Don't know how to enable Zoho mail setup without cloudflare. My Website https://stumbleguyzzapk.com/, https://fakservices.com/ is using CF,
                                                                                                          • Will I Get a Refund If I Downgrade Zoho Mail?

                                                                                                            Hello, We upgraded an email account for our new employee. However, the employee left after one month, and now I've reduced the number of Zoho Mail users from 7 to 6. Can we get a refund for the remaining portion of our annual payment?
                                                                                                          • Accounting on the Go Series-43:Enhancing Your Reporting Efficiency with Dashboard Filter State Retention

                                                                                                            Hello everyone! Welcome back to our series on Zoho Books mobile app features. Today, we will talk about a feature that yet again helps you focus on work that really matters-Dashboard Filter State Retention. Imagine you're working on your Zoho Books dashboard,
                                                                                                          • Zoho books/payroll tax payment

                                                                                                            I accidentally made a second payment to my taxes for $300 which is reflected in my bank account and therefore on Zoho books but I can not match it to any transactions because its not reflected in payroll as a tax payment. Is there a way to add an extra
                                                                                                          • I can't renew the Finance Plus subscription

                                                                                                            I tried to renew the Finance Plus subscription but it keeps reloading the same page over and over when ever I click on "Renew Subscription" button
                                                                                                          • Estimate vs Quote

                                                                                                            they are different. Quote is for 1 piece price + other charges. Estimate is for total quantity to be ordered. The gross total amount of the Estimate is the amount payable. Replacing Estimate as Quote is not understandable because they are different. In
                                                                                                          • Accounting on the Go Series-47: Effortless GSTIN Management- Auto Populate TaxPayer Details in Zoho Books Mobile App

                                                                                                            Hello everyone, Welcome back! Today, we're focusing on a feature specifically designed for our Indian users in the Zoho Books-Indian edition, particularly those who deal with GST compliance regularly. We understand the importance of accurate and efficient
                                                                                                          • Accounting on the Go Series-48: Enhance Accuracy with Custom Work Week Start Days in Zoho Books iOS app

                                                                                                            Hello everyone, Welcome back! We’re here with another feature spotlight that might seem small but can have a big impact on your daily routine: setting the first day of the work week in the Zoho Books iOS app. Imagine this: You’re a business owner who
                                                                                                          • Time to Get Paid Report in ZBooks

                                                                                                            Hello, One of our customers who has 25 different companies around the world gets 60 days to make payments. Unfortunately, the subject report does not report an average time to get paid (in days) or the ability to look at a custom period of time. Currently
                                                                                                          • How to prepare a balance sheet for a company that has no operations yet?

                                                                                                            .
                                                                                                          • Project Billing Method from Zoho People

                                                                                                            Normaly our customers use Zoho Projects to manage projects and timesheet that are being charge to the customer. Using the integration from Zoho Project we can have projects base on different billing method. For example most of our customer use Hourly
                                                                                                          • Zoho Books-Accounting on the Go Series!

                                                                                                            Dear users, Continuing in the spirit of our 'Function Fridays' series, where we've been sharing custom function scripts to automate your back office operations, we're thrilled to introduce our latest initiative – the 'Zoho Books-Accounting on the Go Series'.
                                                                                                          • Zoho Books | Product updates | July 2025

                                                                                                            Hello users, We’ve rolled out new features and enhancements in Zoho Books. From plan-based trials to the option to mark PDF templates as inactive, explore the updates designed to enhance your bookkeeping experience. Introducing Plan Based Trials in Zoho
                                                                                                          • Zoho Books | Product updates | August 2025

                                                                                                            Hello users, We’ve rolled out new features and enhancements in Zoho Books. From the right sidebar where you can manage all your widgets, to integrating Zoho Payments feeds in Zoho Books, explore the updates designed to enhance your bookkeeping experience.
                                                                                                          • Apply Payment Received Amount Zoho Books Invoice

                                                                                                            Hello team here is the sample code How can apply the payment received record over a unpaid zoho books invoice. //......................... paymentID = customer_payment.get("payment_id"); organizationID = organization.get("organization_id"); paymentmaplist
                                                                                                          • Update or Upsert Records Using Unique Custom Fields

                                                                                                            Hello customers, We've enhanced the process of updating records via API. You can now: Update records using unique custom fields Upsert records using unique custom fields Note: Both the features are available in the Zoho Books and Zoho Inventory apps.
                                                                                                          • [Webinar] Understanding the New Invoice Management Systems

                                                                                                            Join industry expert CA Pritam Mahure as he discusses the importance of the new Invoice Management System (IMS) and its impact on taxpayers. Topics Covered: - Concept of IMS and pre-requisites - Applicability and Restrictions on Invoices/Records for IMS
                                                                                                          • Accounting on the Go Series-51: Effortless Transactions: Create and Manage Directly from Uploaded Documents

                                                                                                            Hello everyone, We’re back with another useful feature that makes working with Zoho Books even easier! This time, we’re simplifying the process of creating transactions directly from uploaded documents. Imagine you’re out meeting clients, and you receive
                                                                                                          • Next Page