how it works
plan, button, credit
define a plan
set a monthly price, an optional annual price, and the credit grants subscribers get every month. price and credit are independent: charge $10 and include $5, $25, or nothing.
drop in the button
<SubscribeButton> logs the user in if needed, uses the card they already have on hypery, and subscribes them. no card on file? it adds one and retries.
credits land every month
monthly and annual subscribers get their grants each month. requests from your app spend them first, then fall back to normal billing when they run out.
subscribe
one button on your pricing page
<SubscribeButton> logs the user in if needed, uses the card they already have on hypery, and subscribes them to the monthly or annual price.
- login, card, and subscribe in one click
- interval="month" or "year" picks the price
- popup on desktop, redirect on mobile
import { SubscribeButton } from "@hyperyai/sdk" // logs in if needed → subscribes with the card on file → adds one if missing<SubscribeButton planId="plan_pro" interval="year" onSuccess={() => toast.success("welcome to pro")}/>manage
show credit, switch plans
useAppSubscription gives you the subscriber's plan, remaining credit, and next credit date, plus actions to switch, cancel, or resume.
- remainingCreditUsd and nextGrantAt for your account page
- switchInterval to move between monthly and annual
- cancel and resume without leaving your app
import { useAppSubscription } from "@hyperyai/sdk" function Plan({ appId }: { appId: string }) { const { isSubscribed, interval, nextGrantAt, remainingCreditUsd, switchInterval } = useAppSubscription(appId) if (!isSubscribed) return null return ( <div> <p>${remainingCreditUsd.toFixed(2)} credit left · next credit {nextGrantAt}</p> {interval === "month" && ( <button onClick={() => switchInterval(undefined, "year")}> switch to yearly and save </button> )} </div> )}what you get
subscriptions built for ai usage
monthly and annual prices
offer both on one plan. the annual price shows its effective monthly cost and savings.
monthly credit, even on annual
annual subscribers pay once a year but still receive credits every month, so nothing lands or expires all at once.
credit that stays in your app
grants can only pay for requests made through your app. they expire and never roll over.
you're the merchant of record
subscriptions run on your stripe connect account. hypery takes its platform fee and holds no funds.
switch, cancel, resume
monthly → annual is prorated immediately; annual → monthly takes effect at renewal. cancel and resume from the sdk.
refund-safe
a full refund or dispute revokes the unspent credit from that payment and stops the rest of an annual plan's monthly grants.
faq
questions
how are annual plans different from monthly?
only in how often the user is charged. both receive the plan's credit grants every month. annual subscribers are charged once a year, and each month's credit is issued (and funded) when it lands.
who pays for the credit grants?
you do, as each grant is issued: from your team's hypery balance, or billed to your card on file if the balance is short. you set the grant amounts independently of the price, so you control the margin.
do users have to enter a card again?
no. subscribing uses a card the user already gave hypery, like the one they added at sign-up. if there isn't one, the add-card step opens and the subscription retries automatically.
can users switch between monthly and annual?
yes. switching to annual charges the year now, minus the unused part of the current month, without issuing that month's credit twice. switching to monthly takes effect when the paid year ends.
what happens when a subscriber runs out of credit?
their requests keep working and bill the normal way, against their balance or card. grants are spent first, then usage falls through.