Frequently Asked Questions on GraphQL APIs | Kaizen Series | Zoho CRM

Frequently Asked Questions on GraphQL APIs | Kaizen Series | Zoho CRM

🎊 Nearing 200th Kaizen Post – We want to hear from you!
Do you have any questions, suggestions, or topics you would like us to cover in future posts? Your insights and suggestions help us shape future content and make this series better for everyone. 

Hi all,
Hello and welcome to another week of Kaizen!
In this post, we will be discussing Frequently Asked Questions on Zoho CRM GraphQL APIs.  GraphQL is a query language that provides a more flexible and efficient way to access data and metadata within your Zoho CRM organization. 

Why should I try GraphQL APIs?

 Using GraphQL with Zoho CRM allows you to fetch exactly the data you need in a single request, reducing over-fetching and under-fetching. It also enables you to combine multiple operations in one request, which can improve performance and reduce network overhead.

How do I authorize GraphQL requests?

Similar to Zoho CRM REST APIs, GraphQL APIs use OAuth 2.0 for authorization.
For self-clients, you can use the self-client option in the API console to get an authorization grant code. This code can be exchanged for an access token and a refresh token. Once you receive the access token, send the token in your HTTP authorization header with the value "Zoho-oauthtoken {access_token}" for each request. Check out our Postman collection for GraphQL APIs for examples.

Are GraphQL APIs available for all Zoho CRM editions?

GraphQL APIs are available in Enterprise, Zoho One Enterprise, CRM Plus and Ultimate edition of Zoho CRM. Note that it is not available in any trial editions.

What is the difference between REST APIs and GraphQL APIs?

REST APIs let clients talk to servers using standard HTTP methods such as GET, POST, PUT, PATCH, and DELETE. Instead of fetching a fixed dataset like with REST, GraphQL APIs allows you to ask for precisely the data you want. We have covered this topic in detail in our previous Kaizen post that compares REST APIs and GraphQL APIs

Do I need to do any initial setup to start using GraphQL APIs?

To start using GraphQL APIs, you have to enable GraphQL APIs for your Zoho CRM profile through the enable GraphQL API call. 
  • Request URL : {api-domain}/crm/graphql/actions/enable
  • Method : POST
  • Scope: ZohoCRM.GraphQL.UPDATE
This API call generates the GraphQL schema. GraphQL schema defines the capabilities of a server, the data it contains and the actions that can be done on it. Note that it is sufficient to invoke this API call once for each profile

What are the operations supported in Zoho CRM GraphQL APIs?

   Currently, Zoho CRM GraphQL APIs support only query operations. Query operation is analogous to the GET method in REST APIs.

How do I configure requests for Zoho CRM’s GraphQL APIs?

How do I write a basic query in GraphQL? 

The below query can be used to fetch Last_Name in Leads module.

Request body 

query {

    Records {

        Leads {_data {Last_Name {value}}}

    }

}

 

Output 

{"data":{"Records":{"Leads":{"_data":[

  {"Last_Name":{"value":"Kitzman"}},

  {"Last_Name":{"value":"Frey"}}

  // ...

]}}}}


What are the supported metadata types that can be fetched using GraphQL APIs?

Using GraphQL APIs you can fetch metadata from Modules, Users, KanbanView, UserProperties, ProfilePermissions, Profiles, Rolesand Widgets

Can I fetch metadata and data of a particular module in a single query using GraphQL APIs?

Yes, using GraphQL it is possible to fetch both metadata and data in a single query. 
 For example, the below query can be used to fetch Last_Name from Leads module and metadata information of the Last_Name field in the Leads module.

Request body

{

  Records {

    Leads { _data { Last_Name { value } } }

  }

  Meta {

    Modules(filter: { api_name: "Leads" }) {

      _data {

        fields(filter: { api_names: "Last_Name" }) {

_data {

                        id

                        api_name

                        display_label

                        json_type

                        data_type

}}}}}}

 

 Output 

{

  "data": {

    "Records": {

      "Leads": {

        "_data": [

          { "Last_Name": { "value": "Kitzman" } },

          { "Last_Name": { "value": "Frey" } }

          // ...

        ]

      }

    },

    "Meta": {

      "Modules": {

        "_data": [

          {

            "fields": {

              "_data": [

                {

                  "id": "6660682000000002595",

                  "api_name": "Last_Name",

                  "display_label": "Last Name",

                  "json_type": "string",

                  "data_type": "text"

   }]}}]}}}}

 

We have covered this in detail in this Kaizen post: Using GraphQL APIs to fetch data in a consolidated way.

Are there any limits applicable for a GraphQL API query?

Yes, Zoho CRM imposes certain limits on the GraphQL API to ensure fair usage. 
  • Credits: A single query can consume up to a maximum of 10 credits
  • Complexity: Complexity is a measure of workload a query exerts on the server based on the number of fields and depth of the query. The maximum complexity allowed for a single query is 1000. 
  • Depth: The nesting level of a queried field is referred to as depth. The limit for metadata is seven, and for data is three.
Refer to the official documentation on GraphQL credits.

Is it possible to retrieve selective data using GraphQL APIs?

Records

You can use the where argument to filter records from each module.  Each field can support type specific operators and can be combined with Boolean logic and wildcards.

For example. to fetch Email, Last_Name, ID, Phone and Mobile of  contacts where last name starts with "Ni" and mobile contains the digit 5 or phone number equals 555-678-9999

Request body

{

  Records {

    Contacts(where: {

      and: [

        { Last_Name: { like: "Ni%" } },

        {

          or: [

            { Phone: { equals: "555-678-9999" } },

            { Mobile: { like: "%5%" } }

          ]

        }

      ]

    }) {

      _data {

        Email { value }

        Last_Name { value }

        id { value }

        Phone { value }

        Mobile { value }

  }}}}

 

Introspecting the GraphQL schema in Postman will reveal the details of fields and supported operators for each module. Check out our previous Kaizen, where we explained this using videos.

Metadata

You can use the filter argument to filter metadata resources.

For example, the query below fetches metadata of Deals module and api_name of its layouts and fields

Request body

query {

  Meta {

    Modules(filter: { api_name: "Deals" }) {

      _data {

        id

        singular_label

        plural_label

        layouts {

          _data {

            id

            api_name

          }

        }

        fields {

          _data {

            api_name

     }}}}}}

How do I paginate results in GraphQL?

In GraphQL, we use the offset and limit argument to paginate results.
You can use offset to fetch the next page of results by passing the value from your previous response, starting with null for the initial set.  For each page, the number of records has a limit: up to 100 records for root queries or 10 for nested data.
The value to be passed in offset is obtained by querying for previous_offset and next_offset inside _info object.

Is it possible to sort records in GraphQL? 

The order_by argument can be used to sort the response set after fetching records to ascending or descending order.

For example, the below query fetches the fields Deal_Name, Expected_Revenue, and Probability from Deals module in descending order of probability.


Request body

query {

  Records {

    Deals(order_by: { Probability: { order: DESC } }) {

      _data {

        Deal_Name { value }

        Expected_Revenue { value }

        Probability { value }

}}}}

When should I choose Zoho CRM GraphQL APIs over Zoho CRM REST APIs, and vice versa? 

Use Zoho CRM GraphQL APIs when:

  • You need to fetch complex, nested data from multiple resources (e.g., accounts with linked contacts and deals) in a single request and avoid under-fetching of required data/metadata.

  • You need to minimize over-fetching of data/metadata by selecting only specific resources, fields of the resources, and relationships of the resources.

  • You need to query data and metadata together efficiently. 

Use Zoho CRM REST APIs when :

  • You need to perform simple CRUD operations (e.g., fetch/update a single product).

  • Your use case involves straightforward endpoints without nested data/metadata.

  • You need to do add/update/delete operations.

We trust that this post addressed your doubts on GraphQL APIs. If you have any questions please let us know in the comment section or reach out to us at support@zohocrm.com.

    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

                                                        • Kaizen #198: Using Client Script for Custom Validation in Blueprint

                                                          Nearing 200th Kaizen Post – 1 More to the Big Two-Oh-Oh! Do you have any questions, suggestions, or topics you would like us to cover in future posts? Your insights and suggestions help us shape future content and make this series better for everyone.
                                                        • Kaizen #197: Frequently Asked Questions on GraphQL APIs

                                                          🎊 Nearing 200th Kaizen Post – We want to hear from you! Do you have any questions, suggestions, or topics you would like us to cover in future posts? Your insights and suggestions help us shape future content and make this series better for everyone.
                                                        • Celebrating 200 posts of Kaizen! Share your ideas for the milestone post

                                                          Hello Developers, We launched the Kaizen series in 2019 to share helpful content to support your Zoho CRM development journey. Staying true to its spirit—Kaizen Series: Continuous Improvement for Developer Experience—we've shared everything from FAQs
                                                        • Kaizen #193: Creating different fields in Zoho CRM through API

                                                          🎊 Nearing 200th Kaizen Post – We want to hear from you! Do you have any questions, suggestions, or topics you would like us to cover in future posts? Your insights and suggestions help us shape future content and make this series better for everyone.
                                                        • Client Script | Update - Introducing Commands in Client Script!

                                                          Have you ever wished you could trigger Client Script from contexts other than just the supported pages and events? Have you ever wanted to leverage the advantage of Client Script at your finger tip? Discover the power of Client Script - Commands! Commands


                                                        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

                                                                                                        • 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
                                                                                                        • How do I modify the the incoming/current call popup? I can modify other call pages but not that one.

                                                                                                          I want to modify the incoming and active call popup on the crm to include customer relevant information, such as purchase history or length of relationship. Under modules and fields, I don't seem to see active call as a choice to modify, only the main
                                                                                                        • Interactions Tab in Zoho CRM: A 360° Omnichannel View of Every Customer Touchpoint

                                                                                                          Hello Everyone, Hope you are well! We are here today with yet another announcement in our series for the revamped Zoho CRM. Today, we introduce Interactions Tab a new way to view all customer interactions from one place inside your CRM account. Customers
                                                                                                        • Canvas: Add Sections to Detail View

                                                                                                          Currently it is only possible to add fields to a canvas detail view. This makes Canvas hard to maintain, because everytime we add a field to our system, someone needs to go into the canvas view and add it there as well. This leads to additional work and
                                                                                                        • Automation#32:Auto Add New Portal Users to the Help Center User Groups

                                                                                                          Hello Everyone, Introducing a custom function that automates the process of adding new portal users to Help Center user groups, making user management effortless! By default, Zoho Desk allows you to assign new portal users to groups manually. But with
                                                                                                        • 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.
                                                                                                        • Cannot delete old accounts

                                                                                                          Hello, I try to delete old accounts from CRM, but it won't permit, saying documents are still linked to them. I searched in CRM and BOOKS, found some documents and deleted them, but still CRM won't delete them. Any idea how to do that ? I have a lot of
                                                                                                        • How to start fresh after many years of using Zoho Books without deleting everything and creating a new organisation?

                                                                                                          Hi, I have used Books since 2016, but never reconciled with my bank account. I was thinking of trying to go back and fix that, but I don't just don't have the time it would take. Instead, I'd like back up my old records and start anew. What is the best
                                                                                                        • Is it possible to Bulk Update 'Product Name' in Zoho Desk?

                                                                                                          Is it possible to Bulk Update 'Product Name' in Zoho Desk? I cannot see that option now. Kindly help how we can do it.
                                                                                                        • Feature Suggestion: Dynamic Browser Tab Icon for Check-in/Check-out Status

                                                                                                          Hello Zoho People Team, I am a regular user of Zoho People, and I believe I have a simple but powerful feature suggestion that would significantly improve the user experience for everyone. The Problem: Our team, and likely many others, sometimes forgets
                                                                                                        • Offline mode on Android TV app?

                                                                                                          Hello! Is there a way to use Zoho Show offline in the Android TV app? I have an Android TV based projector, and I travel with it, and don't want to have to rely on a steady internet connection when giving a presentation.
                                                                                                        • Choice-based Field Rules on Global Lists

                                                                                                          Hi, The new Choice-based Field Rules should also be able to work with Global Lists not just local lists. Thanks Dan
                                                                                                        • Tip #36- How to use Survey in Zoho Assist to capture valuable feedback from remote sessions- 'Insider Insights'

                                                                                                          How to use Survey in Zoho Assist to capture valuable feedback from remote sessions The survey feature allows technicians and customers to share their valuable feedback, contributing to the improvement of remote service quality. After the completion of
                                                                                                        • 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
                                                                                                        • Sudden Layout Issue After Last CSS Update for ZML (Temporary Fix Inside)

                                                                                                          Hi, Our clients have noticed today that every section laid out with ZML suddenly shows an unwanted top padding/blank space that interrupts the user screens. It appears that Zoho has changed the default CSS for the .zcp-col.zcp-panel-rowtype-auto element.
                                                                                                        • Improve History Feature in Zoho Inventory

                                                                                                          At present there is a "history" tab on Zoho Inventory Items, however this only shows a date and time stamp along with the users name. It doesn't say what was changed. What is the value of this if you can't see what was changed? My Ideal is to include
                                                                                                        • Writing by Hand in "Write" Notes

                                                                                                          Hi there! I just downloaded this app a few moments ago, and I was wondering if there was a way to write things by hand in "Write" mode instead of just typing in the keyboard. It would make things a bit more efficient for me in this moment. Thanks!
                                                                                                        • Why Server error in creatiing Landing Pages

                                                                                                          Hi Zoho Team, pls see my screenshot and tell me, what's wrong. Thx
                                                                                                        • 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
                                                                                                        • Bulk update account type when adding a bill

                                                                                                          Hi I've only been using Zoho Books for a short while but I'm impressed so far, keep up the great work. One minor issue I'm coming up against is when creating a new bill from a scanned document (supplier invoice). In some cases, the supplier invoice could
                                                                                                        • Narrative 3 - Comprehending User Management

                                                                                                          Behind the scenes of a successful ticketing system - BTS Series Narrative 3 - Comprehending User Management User management in a ticketing system is how administrators oversee user access, roles, and permissions. This process involves not just creating
                                                                                                        • Payment Schedule

                                                                                                          Please add the ability to create a payment schedule. The other options, like retainer invoices or two invoices, do not work for the customer.  We invoice a client and need to be able to show them everything they owe in one invoice, and when each payment
                                                                                                        • 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
                                                                                                        • Product Details's Description is lost

                                                                                                          Hi CRM lost its description in Product details subform. Can you make some test before deploy any update?
                                                                                                        • 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
                                                                                                        • メール一括配信の未送信のメールについて知りたい

                                                                                                          メール一括配信の後の、未送信のメールの数は添付のようにシステムから連絡がくるのですが それらの対象者を知りたい。レポートなど一覧で知りたい。 また配信対象者なのに(担当者、リード)の メールの履歴に配信したメールの件名でさえ表示されないのはどう理解したらよいのか知りたいです。 また、これらの人をレポートで一覧で出す方法を教えてください。把握したいためです。
                                                                                                        • Zoho Bookings Issues We are facing

                                                                                                          Hi team, Here are list of issues we are facing with Zoho Bookings when migrating from other platforms. Sorry there is a lot but the bookings app need to be functional and practical for people to actually use it and not-cause MORE problems by being so basic and not customisable to each business.  1: SMS reminders for staff  There should be time limits on these reminders to make them useful. EG. if a new booking comes in more than 4 hours from now we don't really need to get a reminder, however if
                                                                                                        • Booking outside of scheduled availability

                                                                                                          Is there a way for staff (such as the secretary) to book appointments outside of the scheduled availability? Right now to do this special hours must be set each time. There should be a quicker way. Am I missing something?
                                                                                                        • Run workflow on data import in Creator 6

                                                                                                          How to run a workflow on data import in Creator 6?
                                                                                                        • Add Resource to Export

                                                                                                          The Export Data feature does not include a column for the Resource field. Without this column, Zoho Bookings cannot be used by any business for resource-based services or event types e.g. room bookings, equipment bookings. It seems to be an oversight,
                                                                                                        • Multi Day booking for resources

                                                                                                          I have following business-case: Rental for Tablets. Customer should be able to select how many device for how many days he'd like to rent. Same as a car rental for multiple days. Is this possible with Bookings on the current version?
                                                                                                        • Sales IQ - Bot Builder - Forward to Operator Action Card Improvement

                                                                                                          Hi team, It would be a great improvement to have an additional branch out of the Forward to Operator Action Card. I would like to allow 10 seconds for an operator to pick up the chat, if they don't or if they reject the chat I would like the Bot to continue
                                                                                                        • Zoho AI Translate Task as Rest API

                                                                                                          I cant find any docs on how to use Zoho AI Translate Task from a rest api call https://www.zoho.com/deluge/help/ai-tasks/translate.html I am working on a custom Widget and I dont think I can execute zoho deluge ai translate task from a custom widget.
                                                                                                        • How to Initiate WhatsApp Message on SalesIQ?

                                                                                                          I've just activated a Business WhatsApp phone number through SalesIQ because of its touted omnichannel chat approach. Sounds exciting. I understand that when a customer sends me a WA message, I can reply to it on SalesIQ and keep the chat going, perfect.
                                                                                                        • Custom Roles & Granular Permission Control in Zoho SalesIQ

                                                                                                          Hello Zoho SalesIQ Team, We appreciate the functionalities offered by Zoho SalesIQ, but we would like to request a crucial enhancement regarding user roles and permissions. Current Issue: At present, Zoho SalesIQ provides fixed roles—Admin, Supervisor,
                                                                                                        • Upcoming Changes to LinkedIn Parsing in Resume Extractor

                                                                                                          Starting 31 July 2025, the Zoho Recruit Resume Extractor will no longer support direct parsing of candidate data from LinkedIn profiles. Why Is This Change Needed? In accordance with LinkedIn’s platform policies, extracting profile data through browser
                                                                                                        • Add Usage & Voting Analytics for Knowledge Base Articles in Zoho SalesIQ

                                                                                                          Dear Zoho SalesIQ Team, We appreciate the current integration between Zoho Desk and Zoho SalesIQ that allows knowledge base articles to be synced and displayed to users directly within the SalesIQ chat interface. One valuable feature already available
                                                                                                        • Real-Time Alert or Status Indicator for WhatsApp Connection Issues in SalesIQ

                                                                                                          Hi Zoho Team, We’d like to request a feature enhancement in Zoho SalesIQ related to WhatsApp integration stability and visibility. Recently, we encountered a critical issue where our WhatsApp bot stopped responding to messages without any warning or alert
                                                                                                        • Customization of Chat Transcript Emails in Zoho SalesIQ

                                                                                                          Hi Zoho SalesIQ Team, I hope you're doing well. We would like to request the ability to customize the email template that is sent to clients when they request a chat transcript from SalesIQ. Currently, when a client clicks the button to receive their
                                                                                                        • Import from Linkedin

                                                                                                          Please provide a way to enable importing contact information for Contacts and Companies from Linkedin? Thanks
                                                                                                        • Next Page