Create Custom Connections in Zoho CRM
- Peter
- Difficulty: N/A
- Estimated reading time: 30 mins
getContact = invokeurl [
url: "https://www.zohoapis.com/crm/v2/Contacts/2787502000001234567"
type: GET
connection: "zoho_crm"
];
This connection to Zoho CRM from Zoho CRM (sooooo meta, right?) is part of the prebuilt Zoho OAuth connection. Zoho has provided a number of out-of-the-box connections to Shopify, Survey Monkey, MailChimp, and many other popular business software.
In this tutorial we will cover how to create a custom connection to a tool that Zoho has not built a connection for.
To access the Connections, do the following:
In the Pick Your Service tab you can browse for available connections.
Let’s head over to the Custom Service tab and see what’s going on.
A few important first-observations:
We’re going to continue with an API that uses the OAuth 2.0 authentication framework. This is the most common method of authentication for major Open APIs.
Within the service you are trying to connect, follow the guide to generate a Client ID and Client Secret for your application.
When creating your Client ID and Client Secret you will need to declare an authorized Redirect URI and often scopes.
Zoho CRM custom connections require that you add the following authorized Redirect URI: https://deluge.zoho.com/delugeauth/callback.
Many OAuth 2 APIs require each Client ID to be given a set of scopes (think: permissions and limitations) to promote data security. Each scope maps to a set of API endpoints. You should give each Client ID the least amount of scopes possible to successfully perform your integration. In order to find the scopes you need, consult your API reference (it is often referenced in the section discussing the Authorization Request).
OAuth 2.0 relies on the following URLs which the software service will provide in their API Reference:
/oauth2/auth
, /auth
, or /authorize
)./oauth2/token
or /api/token
)./oauth2/token
or /api/token
).After your connection is created, Zoho will generate an invokeUrl
statement to be used in your Deluge code.
It should look something like this:
response = invokeUrl [
url :
type : GET/POST/PUT/DELETE
parameters :
connection : YOUR_CONNECTION_NAME
];
Sometimes the Deluge editor doesn’t like your connection
name, in which case surround it with quotations like 'YOUR_CONNECTION_NAME'
. As long as you have the permissions, you are now able to make an API call to any software you need.
You should now be connected to your custom service! There are some services which for whatever reason do not play well with Custom Connections. If this is the case, reach out to us. You may also consider building your own OAuth 2.0 workflow in Deluge, in which case you may reference the following repository: Deluge OAuth 2.0 Client.
If you ran into any issues or have any questions, please do not hesitate to reach out to us.
Click here to copy these scripts. For more Zoho-wizardry, check out our GitHub page. And, if you want to know how Zoho CRM stacks up agains the competition, check out our detailed comparison of Zoho CRM and HubSpot.