ml-connector
Zoho BooksChargebee

Zoho Books and Chargebee integration

Zoho Books handles your general ledger and accounts receivable. Chargebee handles your recurring billing and subscription lifecycle. Connecting the two keeps your revenue ledger in sync with your actual subscription invoices without manual entry. Subscription invoices from Chargebee flow into Zoho Books as AR documents, allocated to the correct revenue accounts and currencies, and your month-end close starts with AR already reconciled.

How Zoho Books works

Zoho Books is a cloud-based accounting platform offering invoicing, bills, purchase orders, vendor payments, customer payments, items, chart of accounts, journals, and expenses through a REST API. It authenticates via OAuth2 with user-delegated refresh tokens and requires an organization ID query parameter on every call. Regional base URLs vary by geography (US, EU, India, Australia, Japan, Canada, China, Saudi Arabia) and are returned in the token response. Access tokens expire after 1 hour. Zoho Books supports both webhooks (configured via Settings or the API) for push notifications on invoices, bills, purchase orders, contacts, and payments, and polling via offset-based pagination on list endpoints with a rate limit of 100 requests per minute.

How Chargebee works

Chargebee is a subscription billing and revenue management platform that handles customers, subscriptions, invoices, credit notes, transactions, payment sources, and items through a REST API. It authenticates via HTTP Basic Auth using a site-specific API key and supports both test and live environments. Chargebee exposes 200+ webhook event types for customer, subscription, invoice, payment, and credit note changes, pushing events without HMAC signature protection (verification via re-fetch or basic auth on the endpoint). Webhooks retry for up to 2 days with increasing delays. Chargebee supports offset-based pagination with a maximum page size of 100 and enforces rate limits by plan tier (Starter 150 req/min, Performance 1000 req/min, Enterprise 3500 req/min).

What moves between them

Chargebee subscription invoices flow into Zoho Books as customer AR documents. When Chargebee creates or updates an invoice, ml-connector receives the webhook notification, maps the invoice line items to Zoho Books revenue accounts and currencies, and posts the invoice as an AR transaction. Customer and billing contact information flows from Chargebee to Zoho Books to keep the two systems aligned on receivables. The sync runs in real-time via Chargebee webhooks with a fallback to periodic polling for missed events.

How ml-connector handles it

ml-connector stores Chargebee API credentials and Zoho Books refresh tokens encrypted and uses Zoho Books OAuth2 to obtain a fresh access token on each job, proactively refreshing at 55 minutes to avoid expiry. For Zoho Books, ml-connector resolves the customer organization ID via GET /organizations and routes all calls to the correct regional base URL based on the region credential. Invoice line items are mapped to Zoho Books Chart of Accounts entries using a configurable mapping table, with invoice amounts converted to the correct currency via Zoho Books currency resolution tables. Chargebee webhook payloads are validated through re-fetch via GET /api/v2/events/{event_id} to confirm authenticity. ml-connector tracks Chargebee's invoice state transitions (created, updated, payment applied) so only relevant events trigger postings, avoiding duplicate AR entries. Zoho Books rate limits are respected with exponential backoff on 429 responses, and every invoice posting carries a full audit trail and a deduplication key in Zoho Books reference_number so a replay does not double-post.

A real-world example

A SaaS company with 50 to 200 subscription customers runs Chargebee for billing and Zoho Books for accounting. Previously, the finance team exported invoices from Chargebee on a daily basis and manually created AR entries in Zoho Books, then spent hours each month reconciling Chargebee revenue to the AR ledger. With Chargebee and Zoho Books connected, each new subscription invoice flows automatically into Zoho Books as an AR document on the correct account and in the correct currency. Month-end close now starts with the revenue ledger already in sync, and the manual invoice entry step is eliminated.

What you can do

  • Sync Chargebee subscription invoices into Zoho Books as customer AR documents, mapped to the correct revenue accounts and currencies.
  • Authenticate Zoho Books with OAuth2, handle 1-hour token expiry, and route calls to the correct regional base URL for each organization.
  • Receive Chargebee invoice events in real-time via webhooks and validate them through API re-fetch, with fallback polling for missed events.
  • Track invoice state transitions to avoid duplicate postings, using reference numbers for deduplication across retries and replays.
  • Respect rate limits on both systems with exponential backoff and maintain a full audit trail on every invoice posting.

Questions

Which direction does data flow between Zoho Books and Chargebee?
Chargebee subscription invoices flow into Zoho Books as customer AR documents. Customer and billing contact data also flows from Chargebee to Zoho Books to keep receivables aligned. Zoho Books does not push data back to Chargebee; the integration is read from Chargebee and write to Zoho Books.
How does the integration handle regional differences and currency conversion?
Zoho Books has region-specific base URLs (US, EU, India, Australia, Japan, Canada, China, Saudi Arabia) and the region is returned in the OAuth2 token response. ml-connector uses this region to route all API calls to the correct endpoint. Chargebee invoices are automatically converted to the customer's Zoho Books currency using the Zoho Books currency resolution tables, so multi-currency companies see amounts in the ledger currency, not the billing currency.
What happens if an invoice posting fails or a webhook is missed?
ml-connector validates Chargebee webhooks by re-fetching the event via API and maintains a deduplication key in Zoho Books reference_number so a retry does not create a duplicate AR entry. If a webhook is missed, ml-connector falls back to periodic polling on Chargebee's invoice list. Every posting carries a full audit trail and can be replayed if a downstream call fails.

Related integrations

Connect Zoho Books and Chargebee

Free to use. Add your credentials, ping your real systems, and see if we fit.

Get started