Cancel subscription
Flow
Users can cancel a subscription they purchased at any time. inTandem's cancellation policy states that when a user cancels a subscription, the business is entitled for that subscription until the end of its current billing cycle.
App subscription flow is different than plan subscription flow. (see relevant section)
Steps by step
Cancel decision
The user clicks on a cancel CTA (i.e., apps, deleting a staff member, canceling the main subscription, etc.).
Checkout form
The checkout forms handle the user's confirmation to cancel the subscription. It presents the user with:
- The subscription to cancel and its details
- Cancellation terms
- Confirmation CTA
The checkout form receives the following parameters:
- Subscription UID (smng_external_id) - the subscription to cancel (to be used as subscription_uid in the path)
- Cancel URL (cu): A URL to redirect the user to in case of aborting the cancellation flow.
- Success URL (su): A URL to redirect the user to upon successful completion of the cancellation.
Cancel Subscription
The billing app sends an API call to cancel the subscription. This will show the user her cancel request has been submitted. She will typically have access until the end of the subscription term or be refunded.
Access to the business management system is revoked only after expire subscription is being called
An example of a cancel subscription API call:
curl --location --request PUT 'https://api.vcita.biz/business/subscriptionsmng/v1/subscriptions/{subscription id}' \
--header 'Authorization: Bearer {business API token}' \
--header 'Content-Type: application/json' \
--data '{
"subscription":
{
"purchase_state": "canceled",
"expiration_date":"2024-07-07 12:00"
}
}'
Response example:
{
"success": true,
"data": {
"subscription":
{
"is_active": true,
"uid": "string",
"display_name": "string",
"updated_at": "2024-07-31T06:36:30.828Z",
"created_at": "2024-07-31T06:36:30.828Z",
"purchasable_uid": "1234",
"purchase_state": "canceled",
"cancellation_date": "2024-07-31T06:36:30.828Z",
"expiration_date": "",
"buyer_uid": "string",
"business_uid": "string",
"purchase_price": 0,
"purchase_currency": "string",
"payment_type": "string",
"pay_per_unit": [
"string"
],
"bundled_from_subscription_uid": "string"
}
}
}
Redirect back to the product
After canceling the subscription, the user should be redirected to the success URL to continue using the product.
Response example:
{
"success": true,
"data": {
"subscription":
{
"is_active": true,
"uid": "123",
"display_name": "Platinum5",
"updated_at": "2024-07-31T06:36:30.828Z",
"created_at": "2024-07-31T06:36:30.828Z",
"purchasable_uid": "1234",
"purchase_state": "expired",
"cancellation_date": "2024-07-31T06:36:30.828Z",
"expiration_date": "2024-07-31T06:36:30.828Z",
"buyer_uid": "12345",
"business_uid": "123456",
"purchase_price": 10,
"purchase_currency": "USD",
"payment_type": "monthly",
"bundled_from_subscription_uid": ""
}
}
}
Update subscription (Expire)
When the billing system expires the corresponding subscription (which may happen a few days after the cancellation request or immediately after cancellation, depending on the business terms), call the updated subscription again to expire the subscription in inTandem.
An example of a subscription expiration API call:
curl --location --request PUT 'https://api.vcita.biz/business/subscriptionsmng/v1/subscriptions/{subscription id}' \
--header 'Authorization: Bearer {business API token}' \
--header 'Content-Type: application/json' \
--data '{
"subscription":
{
"purchase_state": "expired"
}
}'
Response Example:
{
"success": true,
"data": {
"subscription":
{
"is_active": true,
"uid": "123",
"display_name": "Platinum5",
"updated_at": "2024-07-31T06:36:30.828Z",
"created_at": "2024-07-31T06:36:30.828Z",
"purchasable_uid": "1234",
"purchase_state": "expired",
"cancellation_date": "2024-07-31T06:36:30.828Z",
"expiration_date": "2024-07-31T06:36:30.828Z",
"buyer_uid": "12345",
"business_uid": "123456",
"purchase_price": 10,
"purchase_currency": "USD",
"payment_type": "monthly",
"bundled_from_subscription_uid": ""
}
}
}
Updated 3 months ago