Skip to main content
GET
Preview a plan change
Read-only. Nothing is charged or scheduled until you call Change the plan with the prorationDate from this response. The target must be a different subscription product in the same currency and billing interval; the subscription must be active or trialing. Anything else returns 400.

Authorizations

x-api-key
string
header
required

Your secret key, from app.agentaos.ai -> Settings -> Developers -> API Keys. The key's prefix is both its identity and its environment: sk_test_... (sandbox, free, no verification) or sk_live_... (real money, requires business verification). A missing or invalid key returns 401.

Path Parameters

id
string<uuid>
required

Subscription id.

Query Parameters

The target product's payment-link id.

Response

The quote. Money fields are integer minor units.

Read-only quote for moving a subscription to another plan. Money is integer minor units.

direction
enum<string>
required

upgrade when the new plan costs more per cycle; downgrade otherwise; revert when the target is the current plan while a downgrade is pending (cancels it, nothing due).

Available options:
upgrade,
downgrade,
revert
currency
string
required
dueTodayMinor
integer
required

Charged now. Always 0 for a downgrade.

dueTodayVatMinor
integer
required
effectiveAt
string<date-time>
required

Upgrade: now. Downgrade: the current period end.

nextInvoiceMinor
integer
required

The next regular cycle invoice on the new plan.

nextInvoiceVatMinor
integer
required
nextInvoiceAt
string<date-time>
required
prorationDate
integer
required

Unix seconds. Echo it in the apply request so the charge matches this quote.