Subscription

Cancel a subscription

Immediately cancels a subscription; no more payments will be created under it. Any metadata supplied to this endpoint will be stored on the payment cancellation event it causes.

This will fail with a cancellation_failed error if the subscription is already cancelled or finished.

<p class="notice--warning"><strong>Warning</strong>: Please note that this will not cancel any payments that have already been created from this subscription — these payments will still be collected unless you also manually cancel them.</p>
post/subscriptions/{subscription_id}/actions/cancel

Request

  • Base URL
    https://api.gocardless.com
  • Auth
    HTTP bearer

Path parameters

subscription_idstring required

The subscription id

Headers

GoCardless-Versionstring required

Request body

Response

Action completed successfully

Example response

{
  "subscriptions": {
    "id": "SB123",
    "created_at": "2014-01-01T12:00:00.000Z",
    "amount": 1000,
    "name": "12 month subscription",
    "start_date": "2014-10-21",
    "end_date": "2015-10-21",
    "interval": 1,
    "interval_unit": "monthly",
    "day_of_month": 28,
    "currency": "EUR",
    "month": "january",
    "count": 5,
    "payment_reference": "GOLDPLAN",
    "status": "active",
    "upcoming_payments": [
      {
        "amount": 2500,
        "charge_date": "2014-11-03"
      }
    ],
    "app_fee": 100,
    "links": {
      "mandate": "MD123"
    },
    "earliest_charge_date_after_resume": "2014-11-03"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.