kepa
Subscriptions/cancelSubscription

Cancel a subscription

Planned
Planned. This contract is published ahead of the build. It is not callable yet — treat it as the shape to design against, not a live endpoint.

End a subscription, immediately or at the period's end.

POST/v1/subscriptions/{id}/cancel
Cancel at period end by default, or immediately with atPeriodEnd=false.
Path parameters
idstringRequired

Request body

application/json

atPeriodEndboolean

Response

application/json

idstring
Example "sub_9c2a4f10"
customerIdstring
Example "cus_123"
priceIdstring
Example "price_pro_monthly"
statusenum
trialingactivepast_duecanceled
Example "active"
currentPeriodEndstring · ISO 8601
Example "2026-04-09T09:14:22Z"
cancelAtPeriodEndboolean
Example false
createdAtstring · ISO 8601
Example "2026-04-09T09:14:22Z"

cancelSubscription