Connect Chargebee to Claude Code
Read and manage customers, subscriptions, invoices, transactions and the product catalog. Add Toolspoke to Claude Code once and it can use 14 Chargebee actions. Your Chargebee credential stays in Toolspoke, and you choose which actions Claude Code may call.
Set it up in Claude Code
Three steps, the first one once for every toolkit you will ever add.
Add Toolspoke to Claude Code
Run it in your project, then /mcp to sign in
claude mcp add --transport http toolspoke https://toolspoke.com/mcpThe sign-in opens in your browser, and Toolspoke asks you to approve it.
Install Chargebee and connect it
Add Chargebee to a project in your Toolspoke workspace.
API key. You provide it once, when you install the connector. Toolspoke encrypts it at rest and decrypts it only for the length of a single call, and the gateway attaches it to the outbound request itself, so it is never part of the arguments an agent sends.
- Site name
- Just the subdomain. For https://acme.chargebee.com this is acme; a test site is usually acme-test.
- API key, then a colon
- Chargebee → Settings → Configure Chargebee → API Keys and Webhooks → API Keys → Add an API Key. Paste the key followed by a single colon (key:). Chargebee reads it as the HTTP Basic username with an empty password. A Read-only: All key covers every read here; create_customer, update_customer, cancel_subscription and refund_invoice need a Full-Access key. Test and live sites have different keys.
Choose what Claude Code may do
All 14 actions start on. Switch off any of the 4 actions that change something in Chargebee, and Claude Code gets a refusal if it tries.
What you can ask Claude Code for
A few of the Chargebee actions that only read, so they are safe to try first.
- List customers, newest first, optionally only one email address
- Retrieve one customer by id, with billing address, payment method summary and balances
- List subscriptions, optionally by status or customer
- Retrieve one subscription by id, together with its customer and card on file
What Claude Code can do in Chargebee
10 actions read, 2 write and 2 delete or permanently change something.
Reads
List customers
List customers, newest first, optionally only one email address. Chargebee wraps each row as {customer: {...}} inside list, and returns next_offset only when there is another page, pass it back as offset.
Get customer
Retrieve one customer by id, with billing address, payment method summary and balances.
List subscriptions
List subscriptions, optionally by status or customer. Each row carries the plan item prices, billing period, next billing date and MRR.
Get subscription
Retrieve one subscription by id, together with its customer and card on file.
List invoices
List invoices, optionally by status, customer or subscription. Amounts are in the currency's minor unit (cents).
Get invoice
Retrieve one invoice by id, with its line items, taxes, payments and billing address.
List transactions
List payment transactions, payments, refunds and reversals, optionally by customer, status or type.
List item prices
List item prices, the plans, add-ons and charges subscriptions are built from, with their amounts, periods and currencies.
List credit notes
List credit notes, optionally by customer, status or the invoice they reference.
List events
List site events, subscription_created, payment_succeeded, invoice_generated and the rest, newest first. Each event carries a full copy of the records it touched, so this is the audit trail of what changed and when. occurred_after is a Unix timestamp in seconds.
Writes
Create customer
Create a customer. A write rather than destructive: it charges nothing and starts no subscription. id is optional. Chargebee generates one when it is left out.
Update customer
Update a customer's name, email, company, phone or auto-collection setting. Billing address and VAT number are changed through a separate Chargebee call this connector does not expose.
Deletes or permanently changes
Cancel subscription
Cancel a subscription (Product Catalog 2.0). Destructive because it stops billing a paying customer and, with cancel_option immediately, ends their access now; a cancelled subscription has to be reactivated deliberately. end_of_term lets the paid period run out first.
Refund invoice
Refund a paid invoice to the customer's original payment method, in full or in part, and create a credit note for it. Destructive because it moves money out of the business and cannot be undone. refund_amount is in the currency's minor unit (cents); leave it out to refund the whole invoice.
Chargebee in Claude Code: questions
Does Claude Code see my Chargebee credential?
No. The credential is stored encrypted in Toolspoke, and the gateway adds it to each call. Claude Code only ever talks to Toolspoke, and the dashboard shows the last four characters of the credential and nothing more.
Can I stop Claude Code from changing things in Chargebee?
Yes. Each of the 14 actions can be switched off for a project. Turn off the 4 that change something and Claude Code can only read.
Will 14 actions crowd Claude Code's context?
No. Toolspoke shows Claude Code five bridge tools, plus a guide where a toolkit has one, and Claude Code searches for the Chargebee action it needs when it needs it. Adding more toolkits does not add more tools to its list.
Can I add it once for every project?
Yes. Add --scope user to the command and Claude Code keeps Toolspoke in every project on this machine. Without it, the server is added to the project you ran the command in.
What does it cost?
Tool calls are free on every plan, and a Chargebee call does not run in a sandbox, so it bills nothing.
Chargebee in your other apps
More payments toolkits for Claude Code
Try Chargebee in Claude Code
Free to start, and tool calls cost nothing on any plan.