Cancel Subscription
PUT
https://api.baremetrics.com/v1/{source_id}/subscriptions/{oid}/cancelThis endpoint allows you to cancel a subscription.
It may take a while for your cancellations to appear in your metrics.
[!NOTE] To update the canceled_at time on a subscription, you may send subsequent canceled events. However, you cannot set the date further forward than it currently is set.
Path parameters
oidstring requiredYour unique ID for the subscription
source_idstring requiredPlease see Sources
Body
application/jsoncanceled_atstring · date-time requiredA unix timestamp of when this subscription was, or should be canceled.
Responses
200OK
{
"event": {
"id": "48X3C1W4w5vCbx",
"type": "subscription.canceled",
"info": {
"canceled_at": 1480421362,
"addons": []
},
"occurred_at": 1480421362,
"received_at": 1480421362
}
}400Bad Request
{
"error": "Error message here"
}