Checkout Sessions

Cancel a checkout session

post/api/v1/checkout-sessions/{id}/cancel

Path parameters

idstring MeteroidId required
Example:che_7n42DGM5Tflk9n8mt7Fhc7

Checkout session ID

Response

Checkout session cancelled

Example response

{
  "session": {
    "customer_id": "cus_7n42DGM5Tflk9n8mt7Fhc7",
    "id": "che_7n42DGM5Tflk9n8mt7Fhc7",
    "payment_methods_config": {
      "account_id": "ba_7n42DGM5Tflk9n8mt7Fhc7"
    },
    "plan_version_id": "plv_7n42DGM5Tflk9n8mt7Fhc7",
    "subscription_id": "sub_7n42DGM5Tflk9n8mt7Fhc7"
  }
}

Changes

Changed in 8 of the 54 revisions of this API.566

  • v1560215310a0912See the full diff
    • added OnlinePaymentMethodConfig BankTransferPaymentMethodConfig ExternalPaymentMethodConfig to the session/payment_methods_config/oneOf[PaymentMethodsConfig]/ response property oneOf list for the response status 200

      response-property-one-of-added

    • added discriminator to session/payment_methods_config/oneOf[PaymentMethodsConfig]/ response property for the response status 200

      response-property-discriminator-added

    • removed subschema #1 subschema #2 subschema #3 from the session/payment_methods_config/oneOf[PaymentMethodsConfig]/ response property oneOf list for the response status 200

      response-property-one-of-removed

  • v1de35c02bb0d2341See the full diff
    • for the path request parameter id, the type/format was changed from string/ to string/MeteroidId

      request-parameter-type-changed

    • added BankAccountId subschema #1 to the session/payment_methods_config/oneOf[PaymentMethodsConfig]/oneOf[subschema #2]/account_id response property oneOf list for the response status 200

      response-property-one-of-added

    • the session/payment_methods_config/oneOf[PaymentMethodsConfig]/oneOf[subschema #2]/account_id response's property type/format changed from string null/ to / for status 200

      response-property-type-changed

    • added the new TOO_MANY_REQUESTS enum value to the code response property for the response status 400

      response-property-enum-value-added

    • added the new TOO_MANY_REQUESTS enum value to the code response property for the response status 401

      response-property-enum-value-added

    • added the new TOO_MANY_REQUESTS enum value to the code response property for the response status 404

      response-property-enum-value-added

    • added the new TOO_MANY_REQUESTS enum value to the code response property for the response status 500

      response-property-enum-value-added

    • added the non-success response with the status 429

      response-non-success-status-added

    • added the new ADDON_PURCHASE enum value to the session/checkout_type response property for the response status 200

      response-property-enum-value-added

    • added the new PLAN_CHANGE enum value to the session/checkout_type response property for the response status 200

      response-property-enum-value-added

    • added the optional property session/payment_methods_config to the response with the 200 status

      response-optional-property-added

    This revision also has 1 change that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog

    • the endpoint scheme security bearer_auth was added to the API

      api-security-added

    This revision also has 1 change that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog

    • endpoint added

      endpoint-added

    • api path removed without deprecation

      api-path-removed-without-deprecation

    This revision also has 274 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog