Sell credits
Price each AI tool in credits and sell packs. Usage-based, so a customer pays in proportion to what they run. Best for expensive or variable AI calls.
There are two clean ways to charge for AI: sell credits that your tools spend, or gate premium tools behind a paid plan. Most apps use both. Stripe handles the money end to end into your own account, and access or credits are granted on the signed payment webhook, never a redirect.
Pick the model that matches where your value sits. If cost tracks how much someone uses the AI, charge for usage with credits so heavy users pay more. If the value is simply having the feature, charge for access with a plan. A common shape is a paid tier that includes a monthly credit allowance, which is both at once.
Price each AI tool in credits and sell packs. Usage-based, so a customer pays in proportion to what they run. Best for expensive or variable AI calls.
Put premium tools behind an entitlement and sell a subscription that grants it. Access-based, predictable revenue. Best when the feature itself is the upgrade.
Give each AI tool a credit price, then let customers buy packs. Every call spends from their balance, and the purchase is a normal Stripe payment.
await g.payments.buy("credits-500"); // a configured product
const { balance } = await g.credits.balance();Credits sit on a grant, and credit packs never expire. See how charging credits works.
Require an entitlement on your premium AI tools, then sell a plan that grants it. The customer subscribes through Stripe, and their plan gates what they can run.
await g.subscriptions.checkout("pro"); // start checkout
const sub = await g.subscriptions.mine(); // { plan, status } or null
// A tool that requires "access:pro" runs only when the plan grants it.Gemmein never holds, moves, or processes money. Payments run through Stripe into your own account, and Gemmein only records who is on which plan. Crucially, access and credits are granted when Stripe's signed webhook arrives, not when the browser returns from checkout.
Building with Cursor, Claude, Bolt, or Lovable? Paste this so your agent wires the money side correctly.
Read https://docs.gemmein.com/llms.txt. I want to monetise the AI features in my app. Show me both models: selling credit packs that AI tools spend (g.payments.buy, g.credits.balance) and gating premium tools behind a paid plan (g.subscriptions.checkout, g.subscriptions.mine, requiring an entitlement). Explain that Stripe handles the money into my own account and access is granted on the signed payment webhook, not the redirect.
npx gemmein devRead the getting-started guide Use credits when cost tracks usage, such as expensive AI calls, so heavy users pay more. Use a subscription when access is the value, such as a Pro tier. Many apps combine them: a plan that includes a monthly credit allowance.
Credits sit on a grant, such as a credit pack. Credit packs never expire.
No. Gemmein never holds, moves, or processes money. Stripe handles all payments end to end and the money goes to your own Stripe account; Gemmein only records who is on which plan from Stripe's webhook.
On the signed payment webhook, not the checkout redirect. A redirect can be faked; the webhook is the record Stripe signs, so access and credits only land on a real payment.
How to charge credits for AI features · Rate-limit AI usage per user · Payments and access on the product page · Docs
Point your coding agent at docs.gemmein.com/llms.txt and ask it to confirm the fit before it builds.