Skip to content

Update a subscription

PATCH
/v1/subscriptions/{subscriptionId}

Update metadata or flip cancelAtPeriodEnd.

subscriptionId
required
string
Example
sub_01ARZ3NDEKTSV4RRFFQ69G5FAZ
object
cancelAtPeriodEnd
boolean
metadata

Up to 50 key/value string pairs you can attach to an object. Trile ignores them; they’re returned on every read.

object
key
additional properties
string
{
"internal_user_id": "42"
}

A subscription object.

object
id
string
sub_01ARZ3NDEKTSV4RRFFQ69G5FAZ
customerId
string
priceId
string
status
string
Allowed values: trialing active past_due canceled
currentPeriodStart
string format: date-time
currentPeriodEnd
string format: date-time
cancelAtPeriodEnd
boolean
metadata

Up to 50 key/value string pairs you can attach to an object. Trile ignores them; they’re returned on every read.

object
key
additional properties
string
{
"internal_user_id": "42"
}