`PUT /api/admin/plans/{plan_id}` — edit a plan (display name, pricing, features, visibility). An `amount_cents` change rotates the Stripe Price.
PUT
/api/admin/plans/{plan_id}
const url = 'https://example.com/api/admin/plans/example';const options = { method: 'PUT', headers: {'Content-Type': 'application/json'}, body: '{"amount_cents":1,"currency":"example","display_name":"example","features":"example","interval":"example","is_active":true,"is_public":true,"reason":"example","sort_order":1,"stripe_price_id":"example","stripe_product_id":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://example.com/api/admin/plans/example \ --header 'Content-Type: application/json' \ --data '{ "amount_cents": 1, "currency": "example", "display_name": "example", "features": "example", "interval": "example", "is_active": true, "is_public": true, "reason": "example", "sort_order": 1, "stripe_price_id": "example", "stripe_product_id": "example" }'Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”plan_id
required
string
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
amount_cents
integer | null format: int32
currency
string | null
display_name
string | null
features
interval
string | null
is_active
boolean | null
is_public
boolean | null
reason
string | null
sort_order
integer | null format: int32
stripe_price_id
string | null
stripe_product_id
Operator-supplied parent Stripe Product id. Outer Option =
“field omitted” (no DB write), inner Option = “set to NULL”.
Mirrors the stripe_price_id shape so admin UI / API can wire
up an existing Stripe product before any price-rotation happens.
string | null
Examplegenerated
{ "amount_cents": 1, "currency": "example", "display_name": "example", "features": "example", "interval": "example", "is_active": true, "is_public": true, "reason": "example", "sort_order": 1, "stripe_price_id": "example", "stripe_product_id": "example"}Responses
Section titled “Responses”Media typeapplication/json
object
amount_cents
required
integer format: int32
created_at
required
string format: date-time
currency
required
string
display_name
required
string
features
required
id
required
string
interval
required
string
is_active
required
boolean
is_public
required
boolean
sort_order
required
integer format: int32
stripe_price_id
string | null
stripe_product_id
Parent Stripe Product for the plan. Required for Price rotation
(migration 088): when an admin edits amount_cents, the new
recurring Price is created under this product so existing
checkout links / marketing copy keep their Stripe parent intact.
string | null
updated_at
required
string format: date-time
Examplegenerated
{ "amount_cents": 1, "created_at": "2026-04-15T12:00:00Z", "currency": "example", "display_name": "example", "features": "example", "id": "example", "interval": "example", "is_active": true, "is_public": true, "sort_order": 1, "stripe_price_id": "example", "stripe_product_id": "example", "updated_at": "2026-04-15T12:00:00Z"}