- Built from scratch: apollo, chargebee, datadog, greenhouse, lever, loom, pandadoc, salesloft, sendgrid, supabase, typeform, webflow, zoho-crm, twilio, reonomy - TSC fixes: brevo, google-console, housecall-pro, meta-ads, rippling, bamboohr, close, fieldedge, freshdesk, helpscout, toast, touchbistro, hubspot, notion, quickbooks, airtable, gusto, intercom, linear, monday, salesforce, shopify, square, wave, xero - Entry points added: close, touchbistro - All 65 active servers compile with 0 TypeScript errors - 4 specialty servers skipped (competitor-research, compliance-grc, n8n-apps, product-analytics)
QuickBooks Online MCP Server
Model Context Protocol (MCP) server for QuickBooks Online integration.
Features
- Full QBO API Coverage: Invoices, Customers, Vendors, Bills, Payments, Estimates, Items, Accounts, Reports, and more
- SQL-like Queries: Native support for QBO's query language
- Rate Limiting: Respects QBO's 500 req/min throttle with automatic retry
- Optimistic Locking: SyncToken support for safe updates
- Sandbox Support: Test against QBO Sandbox environment
- Type Safety: Comprehensive TypeScript types for all QBO entities
- Pagination: Automatic handling of large result sets
- Token Refresh: Built-in OAuth2 token refresh support
Installation
npm install
Configuration
Create a .env file (see .env.example):
# Required
QBO_ACCESS_TOKEN=your_access_token
QBO_REALM_ID=your_realm_id
# Optional
QBO_REFRESH_TOKEN=your_refresh_token
QBO_SANDBOX=false
QBO_MINOR_VERSION=73
Getting OAuth Credentials
- Create an app at Intuit Developer Portal
- Configure OAuth2 redirect URIs
- Obtain access token and realm ID via OAuth flow
- Store refresh token for automatic renewal
Usage
Development
npm run dev
Production
npm run build
npm start
Architecture
Foundation Components
src/types/index.ts: Comprehensive TypeScript interfaces for all QBO entitiessrc/clients/quickbooks.ts: Full-featured QBO API client with retry, rate limiting, and paginationsrc/server.ts: MCP server with lazy-loaded tool modulessrc/main.ts: Entry point with environment validation and dual transport
QuickBooks Client Features
- OAuth2 Bearer authentication
- Automatic retry with exponential backoff (3 retries)
- Rate limit handling (500 req/min)
- Pagination support (startPosition + maxResults)
- SQL-like query execution
- Batch operations (up to 30 per batch)
- Token refresh helper
- Sandbox/production environment switching
Tool Categories (Lazy-Loaded)
Tool implementations will be added in:
src/tools/invoices.ts- Create, read, update, send invoicessrc/tools/customers.ts- Customer managementsrc/tools/payments.ts- Payment processingsrc/tools/estimates.ts- Estimate creation and conversionsrc/tools/bills.ts- Bill managementsrc/tools/vendors.ts- Vendor operationssrc/tools/items.ts- Inventory and service itemssrc/tools/accounts.ts- Chart of accountssrc/tools/reports.ts- P&L, Balance Sheet, Cash Flow, etc.src/tools/employees.ts- Employee managementsrc/tools/time-activities.ts- Time trackingsrc/tools/taxes.ts- Tax codes and ratessrc/tools/purchases.ts- Purchase orders and expensessrc/tools/journal-entries.ts- Manual journal entries
API Examples
Query Invoices
const result = await client.query(
'SELECT * FROM Invoice WHERE TotalAmt > 1000',
{ startPosition: 1, maxResults: 100 }
);
Create Customer
const customer = await client.create('Customer', {
DisplayName: 'Acme Corp',
PrimaryEmailAddr: { Address: 'billing@acme.com' },
});
Update Invoice (with SyncToken)
const invoice = await client.update('Invoice', {
Id: '123',
SyncToken: '0',
TotalAmt: 5000,
});
Get Reports
const profitLoss = await client.getReport('ProfitAndLoss', {
start_date: '2024-01-01',
end_date: '2024-12-31',
accounting_method: 'Accrual',
});
QuickBooks Online API Reference
Type Safety
All QBO entities use:
- Branded types for IDs (prevents mixing Customer/Vendor/etc. IDs)
- Discriminated unions for entity types and statuses
- SyncToken for optimistic locking on all entities
- Strict TypeScript mode for compile-time safety
Rate Limiting
QBO enforces 500 requests/minute:
- Client tracks requests per rolling window
- Automatically throttles when approaching limit
- Retries 429 responses with exponential backoff
Error Handling
QBO errors include:
- Error code
- Message
- Detail
- Element (field causing error)
The client wraps these in structured MCP errors.
License
MIT
Contributing
This is the foundation layer. Tool implementations and UI apps will be added separately.