← Blog

Claude API Billing Passthrough for Resellers

2026-10-12 · 5 min read · SubToAPI Team

If you're building a product on top of Claude and want to resell that access to clients or end users, "billing passthrough" means one specific thing: you need a way to attribute every API call to the right customer, track their usage in real time, and bill them (with or without markup) without exposing your own Anthropic credentials or eating the cost difference blind. This is a common problem for agencies, SaaS wrappers, and consultancies that have Claude access but no clean way to meter it per client.

The short answer is that you don't do this by proxying raw Anthropic keys to clients — that's a security and billing nightmare. Instead, you issue scoped application keys, one per client or per project, route all traffic through a layer that logs usage against that key, and either bill clients directly for their consumption or roll it into your own invoicing. This is exactly the gap a tool like SubToAPI is built to fill: it turns your Claude access into an HTTPS API with per-key usage metadata, so you can issue a sub_live_... key per client and see exactly what each one costs you.

Why "just share the Anthropic key" doesn't work

The naive approach is to give every client the same Anthropic API key, or hand out a handful of keys and reconcile usage manually at the end of the month. This breaks down fast for a few reasons:

A proper passthrough setup solves all four by giving each client (or each internal project) its own key, scoped to your account, with independent usage tracking.

What a working passthrough setup looks like

The practical architecture is simple:

  1. One Claude access point, many application keys. You keep a single relationship with Claude underneath, but issue a distinct application key per client.
  2. Per-key usage logging. Every request against a key is tagged with token counts, model used, and timestamp, so you have a ledger per client, not just a company-wide total.
  3. Revocation without disruption. If a client churns or a key leaks, you kill that one key — everyone else keeps working.
  4. A dashboard or export you can bill from. Whether you invoice manually or push usage into Stripe metered billing, you need numbers you can defend.

With SubToAPI, this maps directly onto the product: each client gets their own sub_live_... key from your dashboard, requests go through the same Claude API shape you already know, and usage metadata comes back with each response so you can track consumption per key without building a logging layer yourself.

Example: issuing a scoped key per client

Once you've created a key for a client in your dashboard, requests look like standard Claude Messages API calls:

curl https://api.subtoapi.app/v1/messages \
  -H "Authorization: Bearer $SUBTOAPI_KEY" \
  -H "content-type: application/json" \
  -d '{
    "model": "claude-sonnet-4.5",
    "max_tokens": 1024,
    "messages": [
      {"role": "user", "content": "Summarize this client ticket."}
    ]
  }'

Because $SUBTOAPI_KEY is specific to that client's integration, every token consumed on this call rolls up to their usage record, not a shared pool. See the quickstart and messages docs for the full request shape.

Pricing the passthrough

Once usage is attributable per client, pricing is a business decision, not a technical one. Common models:

Whichever model you pick, you need the underlying usage numbers to be accurate and timely — this is the part that's easy to underestimate when building it from scratch (webhook handling, token counting across streaming responses, retry deduplication, etc.) and is the core reason teams move to a managed layer instead of rolling their own logging on top of raw Anthropic calls.

Keeping team and client access separate

If you have multiple people on your side working across several client integrations, don't conflate "who can use the API" with "who can manage billing or keys." Separate your internal team seats from client-facing application keys:

This separation matters most when your team grows — you want to onboard or offboard staff without touching any client's live integration. SubToAPI's Team and Scale plans are built around this: per-seat access for your staff, with application keys issued independently underneath.

Streaming and tool use still need attribution

If your resold product involves streaming responses or tool calls — common in chat products and agents — make sure your billing layer still attributes tokens correctly across the full response lifecycle, not just the initial request. Streaming responses accumulate tokens over time, and tool-calling turns can involve multiple round trips. A passthrough layer that only counts the first request will undercount real cost. Check the streaming and tools docs for how usage is reported across these patterns before you build pricing assumptions on top of them.

Getting started

If you're currently reselling Claude access with spreadsheets and manual reconciliation, the fastest fix is moving to per-client application keys with built-in usage metadata rather than building a logging and billing layer yourself. You can start a trial and issue your first client key at signup, or review plan details on the pricing page if you're estimating costs for multiple client integrations.

FAQ

Can I resell Claude API access without Anthropic's direct involvement in billing each client? Yes — you maintain one underlying Claude relationship and issue separate scoped keys per client through a layer like SubToAPI, handling client billing yourself using the per-key usage data.

Do I need to rebuild my app if I switch from a raw Anthropic key to a passthrough service? No, if the service mirrors the Claude Messages API shape. Requests, models, and response formats stay the same — you just point at a different base URL and key.

How do I stop one client's usage from affecting another's budget? Issue a unique application key per client so usage, rate limits, and revocation are isolated. Shared keys make isolation impossible regardless of how careful your logging is.

Turn your Claude access into an HTTPS API

SubToAPI gives you application API keys, streaming, tool use and usage insights on top of your existing Claude access — set up in minutes.

Start free  Read the quickstart →