Extension Pointers - JS SDK Series #5: Working with connectors via widgets using ZOHO.CRM.CONNECTOR

Extension Pointers - JS SDK Series #5: Working with connectors via widgets using ZOHO.CRM.CONNECTOR

Working with third-party applications enables seamless data synchronization through integration. A connector is one of the features available in Zoho CRM that's used to establish an integration. You can create connectors and add the necessary APIs required for your business needs in your extension. Authorizing the connector and invoking the necessary APIs are the two important steps that are needed to achieve your business functionality. We detailed the steps involved in creating a connector, adding APIs, and using Deluge tasks to invoke APIs in our earlier post.

In this post, let's see how you can authorize a connector and invoke the APIs from a widget, thereby performing your business functionality with a customized UI. The ZOHO.CRM.CONNECTOR JS SDK supports methods to authorize a connector and invoke an API.
  • Authorize - This method is used to prompt the connector authorization window of the integrated application.
  • Invoke API - This method is used to invoke an API associated with the connector to perform the required functionality through a widget.
Syntax

Authorize:

ZOHO.CRM.CONNECTOR.authorize(nameSpace)

Here, namespace refers to the namespace of the connector you want to authorize.

There are a few instances in which the authorize method can be used. For your reference, we list a couple of them below.
  • An extension's widget feature may involve certain third-party integrations via a connector. There may be situations where the user could skip authorizing the connector while installing the extension. During such events, developers can conveniently set up a verification mechanism to confirm that the authorization is being properly carried out by the user. This can be done by prompting the user for authorization, when required, from within the scope of the extension itself using the authorize SDK method in the widget.
  • Say that a user has revoked an extension's authorization of a third-party application as the extension is currently not in use. Later, when the user tries to use the extension, they can go ahead without worrying about authorization, because once the authorize SDK is used at the appropriate place, the user will be prompted for authorization while accessing the widget and they can go ahead and utilize the extension features.
Invoke API:

ZOHO.CRM.CONNECTOR.invokeAPI(nameSpace, data)

Here, namespace refers to the namespace of the connector API to be invoked, and data refers to the data object to be constructed and passed to the connector API.

Data Object

Name
Type
Description
Variables
Object
The dynamic data is represented by placeholders in the connector API.
Content_Type
Object
ContentType - multipart for multipart request.
Parts
Array
For a multipart request, provide the parts configuration details here.
File
Object
To include a file in your multipart request.

Let's see an example of how the authorize and invokeAPI JS SDK methods can be used to establish an integration between Zoho CRM and Google Calendar from a widget.

Consider a simple scenario where a Zoho CRM user wants to create an event for a lead via a button on the lead's detail view page and the event has to be automatically created in the user's default Google Calendar for seamless synchronization.

  1. A connector called "GoogleEventscalendar" is created and an API called "CreateNewEvent" is added to the connector to insert a new event. Please refer to this post to learn the detailed steps involved in creating a connector and adding an API.
  2. The APIs request body is constructed with parameters for end date, start date, and summary of the event. The data for the parameters hold placeholders that represent the dynamic data that will be passed via javascript. To learn more about GoogleCalendar Events API, please refer here.



Events.js

Util={};
var EntityId;
var EntityName;
var recordInfo;
var emailid;

//Subscribe to the EmbeddedApp onPageLoad event before initializing the widget 
ZOHO.embeddedApp.on("PageLoad",function(data)
{

/*Prompts the authorization window of the "GoogleEventsCalendar" connector to establish integration between Zoho CRM and GoogleCalendar*/
ZOHO.CRM.CONNECTOR.authorize("jssdkextension.googleeventscalendar").then(function(data1){
})  
})

/*To create an event by retrieving the input values of start date, end date, and summary and passing it as a constructed data set to the 'InvokeAPI' method*/

Util.create=function()
{

//Fetching the record details and retrieving the mail ID of the lead
ZOHO.CRM.API.getRecord({Entity:EntityName,RecordID:EntityId})
.then(function(data){
recordInfo=data;
emailid=recordInfo.data[0].Email;

//Retrieving the input values
var title=document.getElementById("summary").value;
var startdate = document.getElementById("startdate").value;
var enddate = document.getElementById("enddate").value;

//Constructing the data set
var x = {
"Start":startdate,
"End":enddate,
"Title":title,
"Email":emailid
}

//Invoking the 'CreateNewEvent' API by passing the constructed data set
ZOHO.CRM.CONNECTOR.invokeAPI("jssdkextension.googleeventscalendar.creatnewevent",x)
.then(function(responsedata){
})
})
}

3. In the above code snippet, the authorization window is prompted on the page load of the widget. 

Note: The ZOHO.CRM.CONNECTOR.authorize SDK works only in the production environment and cannot be tested in sandbox environment.



4. Once the authorization has been completed, the user can go ahead and create an event for the lead by providing the necessary input and clicking the Create Event button.



In a similar way, you can use the authorize method depending on your business requirements and invoke the APIs accordingly. We hope you found this information useful. Keep following this space for more inputs.

SEE ALSO




    Access your files securely from anywhere

        All-in-one knowledge management and training platform for your employees and customers.






                              Zoho Developer Community




                                                    • Desk Community Learning Series


                                                    • Digest


                                                    • Functions


                                                    • Meetups


                                                    • Kbase


                                                    • Resources


                                                    • Glossary


                                                    • Desk Marketplace


                                                    • MVP Corner


                                                    • Word of the Day


                                                    • Ask the Experts



                                                              • 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 #226: Using ZRC in Client Script

                                                                Hello everyone! Welcome to another week of Kaizen. In today's post, lets see what is ZRC (Zoho Request Client) and how we can use ZRC methods in Client Script to get inputs from a Salesperson and update the Lead status with a single button click. In this
                                                              • Kaizen #222 - Client Script Support for Notes Related List

                                                                Hello everyone! Welcome to another week of Kaizen. The final Kaizen post of the year 2025 is here! With the new Client Script support for the Notes Related List, you can validate, enrich, and manage notes across modules. In this post, we’ll explore how
                                                              • Kaizen #217 - Actions APIs : Tasks

                                                                Welcome to another week of Kaizen! In last week's post we discussed Email Notifications APIs which act as the link between your Workflow automations and you. We have discussed how Zylker Cloud Services uses Email Notifications API in their custom dashboard.
                                                              • Kaizen #216 - Actions APIs : Email Notifications

                                                                Welcome to another week of Kaizen! For the last three weeks, we have been discussing Zylker's workflows. We successfully updated a dormant workflow, built a new one from the ground up and more. But our work is not finished—these automated processes are


                                                              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

                                                                                                                • Is there a way to configure dark mode for Campaigns emails that go out to customers?

                                                                                                                  I've found a lot of information on how to configure dark mode for my (The user) personal Zoho workspace and email, but is there any way to edit dark mode settings on emails that we send out to customers via campaigns?  We sent out a test email the other
                                                                                                                • When Does WorkDrive integrate with Books?

                                                                                                                  When Does WorkDrive integrate with Books?
                                                                                                                • How do I import Connected Records for a Deal?

                                                                                                                  Can you point me to an example of the CSV file that would add related records to an existing CRM Deal? I imported a Deal, then tried importing a connected record using a unique ID that references the Deal ID, but it doesn't attach it to the Deal rec
                                                                                                                • FSM integration with Books

                                                                                                                  Hi, I have spent a few months working with FSM and have come across a critical gap in the functionality, which I find almost shocking....either that, or I am an idiot. The lack of bi-directional sync between Books and FSM on Sales Orders/ Work Orders
                                                                                                                • How to close an estimate ?

                                                                                                                  Hello, I have created estimates, and converted them to invoices to get 50% payment. Now I have 2 cases where the estimate stills shows status partially invoiced, however: 1. for one of them, project stopped half way, so the remaining part will never be
                                                                                                                • Power up your Kiosk Studio with Real-Time Data Capture, Client Scripts & More!

                                                                                                                  Hello Everyone, We’re thrilled to announce a powerful set of enhancements to Kiosk Studio in Zoho CRM. These new updates give you more flexibility, faster record handling, and real-time data capture, making your Kiosk flows smarter and more efficient
                                                                                                                • Sharing Tickets to a team within a department

                                                                                                                  Hi there, We have a need for one department to be able to share tickets to a specific team within a department, I'm wondering if this is possible? All the shared tickets are going into the 'Shared Tickets' view for the whole department but is there a
                                                                                                                • How do you print out the invoices comments

                                                                                                                  I have some invoices where i need to print out the comments that show when reminders and etc were sent how do we print those out in Zoho Books.
                                                                                                                • Unable to load a specific image

                                                                                                                  Hi I am trying to upload an svg file, which reports that there is "a problem with the file", but does not say what sort of problem. I can't find anything which says which files are supported, so it may be it does not support svg. (which would be a real shame) The file itself will open in either Firefox or Chrome without problem. For the moment I am using a png file, which does not zoom well of course. David
                                                                                                                • Why does the Address field show the wrong map location even with a correct Pincode?

                                                                                                                  I am noticing an issue with the Address field map in Zoho Creator. When I enter a city name that exists in multiple locations within the same state, the map sometimes points to the wrong area even if I have entered the correct Pincode. Currently, it seems
                                                                                                                • Uploaded files are not included when using "Include user submitted data" in Email Notification

                                                                                                                  In Send Email notification workflow in Zoho Creator, there is an option called "Include user submitted data" which allows the email to contain all the form submission details. However, when this option is enabled, files or images uploaded through File
                                                                                                                • Books <-> CRM synchronisation with custom Fields

                                                                                                                  Hello, We are synchronising Books Customers with CRM Accounts. In CRM Accounts I set up last year a "segments" multiselect field shown below In Books, I set up a custom multi-select field with the same value as in the CRM And set up the synchronisation inside Books. Want to synchronise the Books Segments with the CRM Segments, but the later doesn't exist, and another non-existing is there ?! First, I don't understand where the field Segmentation is coming from. Second, I set CRM Segmentation to sync
                                                                                                                • CRM x WorkDrive: We're rolling out the WorkDrive-powered file storage experience for existing users

                                                                                                                  Release plan: Gradual rollout to customers without file storage add-ons, in this order: 1. Standalone CRM 2. CRM Plus and Zoho One DCs: All | Editions: All Available now for: - Standalone CRM accounts in Free and Standard editions without file storage
                                                                                                                • Archive Option in Conversation View

                                                                                                                  Hello, I have a suggestion\request to add an "Archive Thread" button in conversation view of Zoho Mail. The best suggestion I have is to put an "Archive Thread" button next to the "Label Entire Thread" button in conversation view. Most users don't just
                                                                                                                • Outlook/Hotmail Blocking Zoho SMTP IPs (S3150)

                                                                                                                  We are currently facing a serious deliverability issue with Zoho SMTP while sending transactional OTP emails for our production application. Emails sent to Outlook / Hotmail addresses are being rejected with the following error: 550 - 5.7.1 Unfortunately,
                                                                                                                • Outlook is blocking incoming mail

                                                                                                                  Outlook is blocking all emails sent from the Zoho server. ERROR CODE :550 - 5.7.1 Unfortunately, messages from [136.143.169.51] weren't sent. Please contact your Internet service provider since part of their network is on our block list (S3150). It looks
                                                                                                                • Track Marketing Automation Campaigns in Zoho CRM

                                                                                                                  Hello, I've been searching but haven't found the exact answer to this question. I am looking to track Marketing Automation email campaigns and activities inside of Zoho CRM. Use Case: Action: Prospect Submits A Lead Form Outcomes: Prospect created in
                                                                                                                • Zoho Social API for generating draft posts from a third-party app ?

                                                                                                                  Hello everyone, I hope you are all well. I have a question regarding Zoho Social. I am developing an application that generates social media posts, and I would like to be able to incorporate a feature that allows saving these posts as drafts in Zoho Social.
                                                                                                                • Temporarily rate limited due to IP reputation.

                                                                                                                  We have suddenly started receiving the following Mail Delivery Status Notification: Diagnostic-Code: 4.7.650 The mail server [136.143.184.12] has been temporarily rate limited due to IP reputation. For e-mail delivery information, see https://aka.ms/postmaster
                                                                                                                • Incorrect Functioning of Time Logs API (Version 3)

                                                                                                                  We need to fetch the list of time logs for each task for our company internal usage. We are trying to achieve it by using the next endpoint: https://projects.zoho.com/api-docs#bulk-time-logs#get-all-project-time-logs Firstly, in the documentation the
                                                                                                                • IMPORTANT: It doesn´t search for letters with portuguese characters.

                                                                                                                  Some of my articles have for example the word "vídeo". But if I search for "vídeo" it doesn´t find them. If I search for "video" it does find them. Idealy, it should find the articles either way. But if I have to choose, it would be better to find the
                                                                                                                • IMPORTANT: It doens´t show full article name on search - Should add line break

                                                                                                                  When we search for articles, it doesn´t show the full name. There should be a line break so the user can see the full article name, otherwise the user can´t know if that´s the article he/she is looking for. This is very important, otherwise the user has
                                                                                                                • Zoho Books - Payment Gateway - Revolut

                                                                                                                  Hi Books Team, My feature request if to include the popular platform Revolut as a payment collection option on invoices in Zoho Books. Please upvote if you are also looking for this option.
                                                                                                                • Zoho Books | Product updates | January 2026

                                                                                                                  Hello users, We’ve rolled out new features and enhancements in Zoho Books. From e-filing Form 1099 directly with the IRS to corporation tax support, explore the updates designed to enhance your bookkeeping experience. E-File Form 1099 Directly With the
                                                                                                                • Kaizen #233 - Generating AI-powered Follow-up Emails Using CRM Functions and Widgets

                                                                                                                  Hey everyone! Welcome back to another interesting post in the Kaizen series! Sales teams regularly capture interaction notes in CRM after speaking with prospects. However, drafting a follow-up email that reflects the conversation context can be repetitive
                                                                                                                • Connect Bank in Zoho Books

                                                                                                                  Can I connect UOB or Ariwallex in Zoho Books?
                                                                                                                • Using MPN across multiple SKUs and inventory tracking

                                                                                                                  I have several different SKU's that share a common MPN and would like to track inventory by MPN. SKU1 has MPN1 assigned SKU2 has MPN1 assigned Here is an example If I start with 5 of MPN 1 in stock I want each SKU1 and SKU2 to show as 5 in stock, If I
                                                                                                                • Extend Zoho Canvas Customization to Zoho Creator Forms and Reports

                                                                                                                  Currently, Zoho Canvas allows users to design and customize the UI of Zoho CRM modules with a much better visual experience. This helps organizations create cleaner layouts, improve usability, and design interfaces that match their workflows. However,
                                                                                                                • Marketing Tip #1: Optimize item titles for SEO

                                                                                                                  Your item title is the first thing both Google and shoppers notice. Instead of a generic “Leather Bag,” go for something detailed like “Handcrafted Leather Laptop Bag – Durable & Stylish.” This helps your items rank better in search results and instantly
                                                                                                                • Feature Enhancement Request – Text Formatting Options in Item Description (Zoho Books/Quotes Module)

                                                                                                                  Dear Zoho Development Team, Greetings from Radiant360 Integrated Technical Services LLC. We would like to bring to your attention a functional limitation we've encountered within the Item Table / Quote Description section of Zoho Books (and Zoho CRM Quotes).
                                                                                                                • ZOHO Books Query

                                                                                                                  Good day, Can someone please advise. I recently migrated from ZOHO Invoice to ZOHO Books. No that I want to use the inventory on Books I cant as all my items have transaction history. The person I spoke to at ZOHO said I need to create a new Company profile
                                                                                                                • Best way to schedule bill payments to vendors

                                                                                                                  I've integrated Forte so that I can convert POs to bills and make payments to my vendors all through Books. Is there a way to schedule the bill payments as some of my vendors are net 30, net 60 and even net 90 days. If I can't get this to work, I'll have
                                                                                                                • ZOHO.CRM.UI.Record.open not working properly

                                                                                                                  I have a Zoho CRM Widget and in it I have a block where it will open the blocks Meeting like below block.addEventListener("click", () => { ZOHO.CRM.UI.Record.open({ Entity: "Events", RecordID: meeting.id }).catch(err => { console.error("Open record failed:",
                                                                                                                • Removing To or CC Addresses from Desk Ticket

                                                                                                                  I was hoping i could find a way to remove unnecessary email addresses from tickets submitted via email. For example, a customer may email the support address AND others who are in the helpdesk notification group, in either the TO or CC address. This results
                                                                                                                • inventory removal at packing list or shipment.

                                                                                                                  currently our system is set to remove inventory at invoice. This is creating an inventory nightmare? Is it possible to change the settings to remove the item from inventory at either the packing slip stage or shipping the item.
                                                                                                                • How to add employee and not invite them to log in?

                                                                                                                  I want to add 50 employees, but invite them only when everything will be configured and ready. Is it possible? Should we create employee profiles and then convert them later? Thank you,
                                                                                                                • How is Your eCommerce Experience w/Zoho Inventory?

                                                                                                                  First off, I'm SUPER grateful for the advent of Zoho Inventory and now the Zoho Commerce Suite. Overall, Inventory is a great product, especially for customers without an eCommerce presence. For eCommerce companies (especially those shipping more than ~10 packages/day), however, there are certain drawbacks that keep my clients from moving over to Zoho Inventory: Cons: 1. Invoice + Package Creation from Shopify/Other eCommerce Integrations: Zoho Inventory makes the somewhat perplexing decision to
                                                                                                                • Ability to Use Both AND and OR When Creating Rules (Advanced Conditions)

                                                                                                                  I'd like to be able to use more complicated logic when setting up rules. E.g. in Zoho Mail, I can choose "Advanced conditions (AND/OR) to create a rule that can be applied to multiple subject lines from the same sender. But in Zoho TeamInbox, I will have
                                                                                                                • Zoho Desktop App- Unable to Minimize/Freezes

                                                                                                                  I'm having issues with my Zoho Mail desktop app (PC). When go on my desktop and open the app this is what happens: - Unable to minimize and close app (in the screenshot attached you can see at the top right there is no option to minimize/close) - Unable
                                                                                                                • Zoho Invoice Zapier Integration

                                                                                                                  Is there still a way to use Zapier with Zoho Invoice? I've read online that that migrated to Zoho Books or Billing but since I am just using Invoice I can not find a Zapier Connection anymore.
                                                                                                                • Next Page