[GH-ISSUE #4282] stripe plugin: credit/usage based billing #27209

Closed
opened 2026-04-17 18:05:32 -05:00 by GiteaMirror · 7 comments
Owner

Originally created by @mohammed-bahumaish on GitHub (Aug 28, 2025).
Original GitHub issue: https://github.com/better-auth/better-auth/issues/4282

Originally assigned to: @bytaesu on GitHub.

Is this suited for github?

  • Yes, this is suited for github

how can we handle "Customer Balance approach" for credit/usage based billing rather than subscriptions?

Describe the solution you'd like

support Customer Balance approach

Describe alternatives you've considered

Customer Balance approach

Additional context

Customer Balance approach

Originally created by @mohammed-bahumaish on GitHub (Aug 28, 2025). Original GitHub issue: https://github.com/better-auth/better-auth/issues/4282 Originally assigned to: @bytaesu on GitHub. ### Is this suited for github? - [ ] Yes, this is suited for github ### Is your feature request related to a problem? Please describe. how can we handle "Customer Balance approach" for credit/usage based billing rather than subscriptions? ### Describe the solution you'd like support Customer Balance approach ### Describe alternatives you've considered Customer Balance approach ### Additional context Customer Balance approach
GiteaMirror added the lockedpayments labels 2026-04-17 18:05:32 -05:00
Author
Owner

@tboutron commented on GitHub (Sep 20, 2025):

Hi @himself65 , are you actively working on the usage plugin?
Can I help finish the PR?

<!-- gh-comment-id:3314860342 --> @tboutron commented on GitHub (Sep 20, 2025): Hi @himself65 , are you actively working on the usage plugin? Can I help finish the PR?
Author
Owner

@dosubot[bot] commented on GitHub (Dec 20, 2025):

Hi, @mohammed-bahumaish. I'm Dosu, and I'm helping the better-auth team manage their backlog and am marking this issue as stale.

Issue Summary:

  • You requested adding support for a "Customer Balance approach" in the Stripe plugin to enable credit or usage-based billing instead of traditional subscriptions.
  • The goal is to manage billing through customer balances rather than subscription models.
  • No alternative solutions have been considered or proposed by you.
  • A team member, tboutron, asked if @himself65 is actively working on the usage plugin and offered help to finish the related PR.
  • The issue remains unresolved with no recent updates.

Next Steps:

  • Please let me know if this feature request is still relevant to the latest version of the better-auth repository by commenting on this issue.
  • If I do not hear back within 7 days, I will automatically close this issue.

Thank you for your understanding and contribution!

<!-- gh-comment-id:3677928617 --> @dosubot[bot] commented on GitHub (Dec 20, 2025): Hi, @mohammed-bahumaish. I'm [Dosu](https://dosu.dev), and I'm helping the better-auth team manage their backlog and am marking this issue as stale. **Issue Summary:** - You requested adding support for a "Customer Balance approach" in the Stripe plugin to enable credit or usage-based billing instead of traditional subscriptions. - The goal is to manage billing through customer balances rather than subscription models. - No alternative solutions have been considered or proposed by you. - A team member, tboutron, asked if @himself65 is actively working on the usage plugin and offered help to finish the related PR. - The issue remains unresolved with no recent updates. **Next Steps:** - Please let me know if this feature request is still relevant to the latest version of the better-auth repository by commenting on this issue. - If I do not hear back within 7 days, I will automatically close this issue. Thank you for your understanding and contribution!
Author
Owner

@himself65 commented on GitHub (Dec 27, 2025):

This is still on roadmap but not now

<!-- gh-comment-id:3694078189 --> @himself65 commented on GitHub (Dec 27, 2025): This is still on roadmap but not now
Author
Owner

@Yorizel commented on GitHub (Feb 6, 2026):

any updates on this?

<!-- gh-comment-id:3861369064 --> @Yorizel commented on GitHub (Feb 6, 2026): any updates on this?
Author
Owner

@bytaesu commented on GitHub (Mar 28, 2026):

Hello @tboutron @mohammed-bahumaish @Yorizel,

First, please create a priceId using Stripe's usage-based billing: https://docs.stripe.com/billing/subscriptions/usage-based

Then you can attach that priceId to your plan configuration. If you want to combine a base plan with additional usage-based pricing, you can include them in lineItems.

We don't provide ingest or analytics APIs. Waiting for an extra HTTP response on every request wouldn't be practical, and wrapping the Stripe API here doesn't add much value. Each app also has different requirements, making it hard to abstract at the package level.

Instead, Better Auth focuses on linking usage-based priceIds to identity. For the actual usage tracking, you can directly use APIs like stripe.billing.meterEvents

<!-- gh-comment-id:4148041133 --> @bytaesu commented on GitHub (Mar 28, 2026): Hello @tboutron @mohammed-bahumaish @Yorizel, First, please create a priceId using Stripe's usage-based billing: https://docs.stripe.com/billing/subscriptions/usage-based Then you can attach that priceId to your plan configuration. If you want to combine a base plan with additional usage-based pricing, you can include them in lineItems. We don't provide ingest or analytics APIs. Waiting for an extra HTTP response on every request wouldn't be practical, and wrapping the Stripe API here doesn't add much value. Each app also has different requirements, making it hard to abstract at the package level. Instead, Better Auth focuses on linking usage-based priceIds to identity. For the actual usage tracking, you can directly use APIs like `stripe.billing.meterEvents`
Author
Owner

@bytaesu commented on GitHub (Mar 28, 2026):

Feel free to reopen if you have further questions!

<!-- gh-comment-id:4148041517 --> @bytaesu commented on GitHub (Mar 28, 2026): Feel free to reopen if you have further questions!
Author
Owner

@github-actions[bot] commented on GitHub (Apr 5, 2026):

This issue has been locked as it was closed more than 7 days ago. If you're experiencing a similar problem or you have additional context, please open a new issue and reference this one.

<!-- gh-comment-id:4187978082 --> @github-actions[bot] commented on GitHub (Apr 5, 2026): This issue has been locked as it was closed more than 7 days ago. If you're experiencing a similar problem or you have additional context, please open a new issue and reference this one.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#27209