Skip to main content
POST
Cancel a subscription (terminal, no refund/proration)

Headers

ApiKey
string
required

Your api key. To create a key, please get into our dashboard. If you don't have access to it, please reach the Support team.

MerchantId
string
required

Your merchant ID. This information is available in our dashboard. If you don't have access to it, please reach the Support team.

Environment
enum<string>
required

Allow you to choose between the sandbox mode to perform some tests or the live mode for real world transactions.

Available options:
live,
sandbox

Path Parameters

id
number
required

Response

id
number
required

Subscription identifier — pass this into the cancel/suspend/charge/transactions endpoints.

cybersourceSubscriptionId
object | null
required

Same value received as subscriptionId in the subscription.created webhook payload. Null for a merchant_initiated subscription — there is no RBS-side subscription.

status
enum<string>
required
Available options:
created,
pending,
active,
delinquent,
suspended,
cancelled,
completed
billingMode
enum<string>
required

rbs_scheduled — debited on a schedule by Cybersource RBS; merchant_initiated — charged on demand via POST /subscriptions/{id}/charge.

Available options:
rbs_scheduled,
merchant_initiated
frequency
enum<string> | null
required

Null for a merchant_initiated subscription — charges are on-demand, not scheduled.

Available options:
weekly,
monthly
amount
object | null
required

Null for a merchant_initiated subscription — charge amounts are per-call, not fixed.

currency
string
required
startDate
object | null
required

Null for a merchant_initiated subscription.

customerId
string
required
createdAt
string<date-time>
required