Product

Ship credit billing in an afternoon.

No billing logic to write, no pricing to hardcode. Wrap what you already have, and price it from a dashboard instead of a deploy.

1

Install and initialize, server-side

npm install @crediball/sdk

Then call crediball.init(apiKey) once. Never expose the secret key to the browser.

2

Wrap the actions worth billing

crediball.action("generate_poem", userId, () => generatePoem(topic)) registers the action, deducts credits before the work runs in live mode, and returns the result unchanged. No result to return? Use crediball.track() instead — same billing, no wrapping required.

3

Register everything with one command

npx @crediball/sdk sync

Auto-discovery only sees actions that actually ran. This reads the action keys out of your source and registers the rest, so everything is ready to price before your first real user shows up.

4

Price and activate in the dashboard

Set a credit cost per action (or let usage-based AI cost pass through automatically), then activate it. Change prices any time — no redeploy needed.

5

Drop in the credit UI

Wrap your app in <CrediballProvider> and add <CreditsBadge/>, <PaywallModal/>, or the headless useCrediball() hook — styled to match your app with --crediball-*CSS variables, or fully unstyled “naked” components if you want to own the markup.

6

Connect Stripe and go live

Sandbox mode costs nothing and never expires, so you can test the whole flow first. When you’re ready, connect your Stripe account and flip the app to live — payouts go straight to you.

Prefer to hand it to an agent?

Crediball runs an MCP server, so a coding agent already in your editor can price actions, create top-up packages, set a signup bonus, and flip the app to live — in the same conversation as the code integration. See the SDK page for details.

Not sure what to bill for yet?

The Use cases page walks through how chat apps, image generators, coding assistants, and other AI apps typically price their actions.

Get started