# WHMCS API Integration

> Connect WHMCS to your accounting tool, ERP, website or staff tools through the official API, with scoped credentials.

WHMCS API integration for accounting, ERP, storefronts and internal tools: scoped API roles, IP restrictions, field mapping, retries and a runbook. Fixed price from $200.

- **Price:** $200 - $1,000
- **Billing:** One-time, fixed scope
- **Category:** Custom Development
- **Quote turnaround:** Fixed-price quote within 24 hours
- **Start a project:** https://whmcspilot.com/start-project
- **Details:** https://whmcspilot.com/services/whmcs-api-integration
- **Last updated:** 2026-11-05

## Overview

WHMCS API integration connects WHMCS to another system you run, such as an accounting package, an ERP, your marketing website or an internal staff tool, so orders, clients and payments move between them through the official WHMCS API instead of being typed in twice. It is for providers whose team re-keys data from WHMCS into a second tool every week. Quotes are fixed, between $200 and $1,000. Syncing contacts and deals with HubSpot, Pipedrive, Salesforce or Zoho has its own page, [WHMCS CRM integration](/services/whmcs-crm-integration). If you only need alerts when events happen, [webhook setup](/services/whmcs-webhook-setup) is the lighter option.

## One API, two entry points

The External API accepts POST requests at includes/api.php, each naming an action such as GetClients, and answers in JSON when the request sets responsetype to json. Code already running inside WHMCS, such as a hook or an addon module, calls the same actions through localAPI, with no credentials sent over the network. Most integrations use both: the outside system calls the External API to pull or push records, and a hook inside WHMCS sends changes out the moment they happen.

## Integrations we build

- **Accounting and ERP.** GetInvoices, GetTransactions and AddInvoicePayment keep Xero, an ERP or a bookkeeping database in step with WHMCS. For QuickBooks Online, our [QuickBooks Integration module](/modules/quickbooks-integration) may cover it without a custom build.
- **Your own storefront.** GetProducts feeds live pricing to a marketing site and AddOrder places orders from your own checkout. AddOrder ignores the automatic setup setting, so the connector follows it with an explicit AcceptOrder call when you want instant provisioning.
- **Staff and NOC tools.** GetClientsDetails and GetClientsProducts show account data in an internal dashboard, and ModuleSuspend or ModuleUnsuspend let an abuse system act on a service with an audit trail.
- **Single sign-on from another site.** CreateSsoToken returns a one-time login link, valid for at most 60 seconds, that drops an already signed-in customer into the right client area page.
- **Reseller access.** When resellers need their own keys to order from you, the [WHMCS REST API module](/modules/whmcs-rest-api) gives them that without handing out admin credentials.

## Credentials and access control

Most API problems we are asked to fix come from one shared, all-powerful credential. Each integration gets its own setup instead:

- An API role at Configuration &gt; System Settings &gt; Manage API Credentials that allows only the actions this integration calls
- A credential pair assigned to that role and to a dedicated admin user with the API Access permission, so it can be revoked without touching staff logins
- The caller's address added under API IP Access Restriction on the Security tab of General Settings, with an $api\_access\_key in configuration.php used only when the caller has no fixed IP
- Log API Authentication switched on if you want successful API logins recorded in the admin log
- Secrets kept in the other system's secret store or environment variables, never in browser code or a public repository

## How the connector is built

- A field mapping sheet that lists each WHMCS field, its match in the other system, and which side wins when both change
- External IDs stored on both sides, so a retried request updates a record instead of creating a duplicate
- Paged reads using limitstart and limitnum, since list actions such as GetClients return 25 records unless told otherwise
- A one-time backfill of historical records, then incremental sync from that point on
- Failed calls written to a log and retried on a schedule, with an email to you if a record keeps failing

## Version notes

Connectors are tested on your actual branch, whether that is 8.13 (PHP 8.1+) or 9.x (PHP 8.2+). On 9.x, invoices cannot be edited once published unless you change the Invoice Immutability setting, and corrections appear as credit and debit notes, so accounting connectors need to read those notes as well as invoices.

## To get started we need

- API documentation and sandbox or test credentials for the other system
- WHMCS admin access, preferably on a staging copy
- Which records move, in which direction, and how often

## What you get

The connector code, the mapping sheet, a note of the API role and the exact actions it allows, and a short runbook covering credential rotation and what to check when a sync stops. Corrections to anything in the agreed scope are free for 14 days after delivery.

## Pricing

ScopeFixed priceOne record type in one direction, such as paid invoices to accountingFrom $200Two-way sync or several record types, with a mapping table and retry queueFixed quote between $200 and $1,000Ordering from your own storefront through AddOrder, plus SSO into the client areaUp to $1,000Ongoing connector work beyond one project30 hours a month for $1,650

## Outside this service

- Subscription fees or plan upgrades on the third-party system
- New features inside the other system itself
- Provisioning modules that create accounts on a remote panel
- Real-time chat or helpdesk widgets, which have their own pages

Send us the API documentation link for the system you want connected and we will confirm feasibility on the scoping call.

## What's included

- External API and localAPI integration using documented WHMCS actions
- Dedicated API role limited to the actions the integration calls
- Separate credential pair per integration, revocable on its own
- IP allowlisting through API IP Access Restriction, or an access key where IPs change
- Field mapping sheet with conflict rules for two-way sync
- Duplicate protection through stored external IDs
- Paged backfill of historical records, then incremental sync
- Retry queue and failure alerts by email
- AddOrder and AcceptOrder ordering flows for custom storefronts
- CreateSsoToken single sign-on into the WHMCS client area

## Business outcomes

- Staff stop re-typing WHMCS data into a second system
- A leaked or retired credential can be revoked without breaking other integrations
- Both systems show the same invoice, payment and client records
- Failures are visible and retried instead of silently lost
- A future developer can maintain the connector from the mapping sheet and runbook

## Frequently asked questions

### Does WHMCS have a REST API?

WHMCS has an HTTP API at includes/api.php that takes POST requests with an action name and returns JSON. It is not resource-style REST, but any language that can send an HTTP POST can use it.

### How should API credentials be secured?

Give each integration its own credential pair and an API role that allows only the actions it needs, then restrict the caller's IP. Never put the secret in a mobile app, browser script or public repository.

### Can Zapier or Make write data into WHMCS?

Yes, by calling the WHMCS API with a credential whose role allows only the actions the automation needs. For alerts travelling the other way, out of WHMCS into those tools, see our webhook setup page.

### Why did AddOrder not provision the service?

AddOrder ignores the automatic setup setting by design. The order has to be accepted with a separate AcceptOrder call, which our connectors make when you want instant setup.

### Does the integration work on WHMCS 9?

Yes, we build and test on whichever version you run, 8.13 or 9.x. Accounting connectors on 9.x also read credit and debit notes, because published invoices are no longer edited directly.

### When is payment due?

Half when you accept the written quote and half when the connector is delivered and tested. Cards, Apple Pay and Google Pay go through Stripe, and PayPal and NOWPayments crypto also work.
