Recently, our team had the opportunity to integrate with Zoho Mail, and the experience provided us with valuable insights into the Zoho Mail API. In this blog post, we will share our learnings, highlight its strengths, and discuss some areas where improvements could be made.
What We Learned about Zoho Mail API:
-
Easy Authentication and Authorization: We found the OAuth 2.0 authentication flow provided by the Zoho Mail API to be intuitive and straightforward. The process of obtaining access tokens for authentication was well-documented, allowing us to securely access user data without compromising login credentials.
** What was a bit uncommon is that an authorized user does not belong to any specific Zoho organization, there is no one primary OrgId or TenantId like with Office 365 or Google. All Zoho products (Projects, CRM, Mail,…) seem to provide their own Orgs so look out for that. **
-
Thorough Documentation and Resources: Zoho Corporation’s documentation for the Zoho Mail API was comprehensive and detailed. The examples and code snippets provided in the documentation were helpful in understanding how to make API calls and handle responses.
-
Versatile Email Management: The Zoho Mail API offers a wide range of functionalities to manage email accounts effectively. We were able to create, read, update, and delete emails programmatically. The ability to manage folders, labels, and attachments through the API allows developers to automate and customize email management processes.
What Is Missing:
-
Threads API: Zoho Mail supports threads, and you will see ’threadId’ for messages, but there is no API methods to request a list of all threads or to request a list of messages in a thread. That makes it quite difficult to build thread based views.
** Also note, that a single new email is not a thread yet and Zoho Mail API won’t return ’threadId’ for it. After some experimenting we’ve figured that when a response is created and Zoho Mail makes a new thread it assumes the first message’s id to be the threadId. **
September'23 Update: Zoho implemented
&threadId=
parameter support for their List messages method (although not documented yet), so now messages of a given thread can be retrieved. -
Sync/Deltas API: Except receiving new emails Zoho Mail API does not provide any way to monitor mailbox changes, like messages moving to another folder, or changing read/unread status, or being flagged or labeled or deleted. Zoho Mail messages don’t have an ‘updatedAt’ timestamp, so you can’t even use the search method to receive updates.
-
Real-time Notifications with Webhooks: A Zoho Mail admin can configure Outgoing webhooks for Email and Tasks, but Zoho Mail API does not provide any methods to subscribe to such real-time notifications programmatically.
Conclusion:
In conclusion, our integration experience with Zoho Mail and exploration of the Zoho Mail API revealed its strengths in easy authentication, thorough documentation, versatile email management. We definitely prefer to use this OAuth2 based REST API over IMAP which Zoho Mail provides too.
However, the API is missing some very important capabilities in the area of threading, syncing/deltas, and webhooks API. Having Webhooks could mitigate the lack of sync methods but unfortunately a product team needing this would have to ask each client’s Zoho Mail admin to set up those outgoing webhooks manually.
In the end, with some limitations, we have extended our Email API to Zoho Mail and developers integrating with multiple email providers will benefit from integrating through Aurinko.