Reactivate a Subscription Retroactively
Reactivate all or part of a subscription retroactively
Overview
This guide shows you how to implement the Reinstate Subscription Items endpoint to reactivate one or more canceled subscription items retroactively.
Use case
- A customer deactivates their Cloudify Cloud Storage subscription.
- On the next renewal date, the subscription expires. Because the subscription is no longer active, Cloudify disables the customer's access to the service.
- Later, the customer decides to reinstate the subscription to continue using the service.
- Cloudify calls the Reinstate Subscription Items endpoint to reactivate the subscription items.
- Cloudify restores the customer's access to the service and resumes billing for the next subscription interval.
Result
The customer regains access to the service, and recurring billing resumes from the reactivation date. Because the customer did not have access to the service while the subscription was inactive, no charges are applied retroactively for the missed billing periods.
Implement API endpoints
Before you start
Make sure that:
- Each subscription item to be reinstated has the status
Deactivated. - Each subscription item to be reactivated belongs to an active subscription product.
- All subscription items have been canceled before the retroactive reactivation is performed.
- The customer agrees to retroactive billing for the missed billing intervals.
ImportantGet the customer's consent before making changes to a subscription.
To avoid chargebacks and customer inquiries, it is also essential that you coordinate all price increases with Client Experience.
In the European Economic Area (EEA), Strong Customer Authentication (SCA) is required for recurring electronic payments when the amount changes. This means that some of your customers will have to authenticate their payment, which in turn might impact the renewal success rate.
For more information, see Best Practices: Obtain Customer Consent.
Step 1: Get the subscription details
Use the Get Subscription endpoint to retrieve the current subscription details and identify the subscription item to reactivate.
Parameters
| Parameter | Type | Required | Example | Notes |
|---|---|---|---|---|
| SubscriptionId | str | Yes | S68732954 | The unique identifier of the subscription. |
Request
curl --location 'https://rest.cleverbridge.com/subscription/getsubscription?subscriptionId=S68732954'
--header 'Accept: application/json'
--header 'Authorization: Basic YOUR_BASE64_ENCODED_CREDENTIALS'import http.client
conn = http.client.HTTPSConnection("rest.cleverbridge.com")
payload = ''
headers = {
'Accept': 'application/json',
'Authorization': 'Basic YOUR_BASE64_ENCODED_CREDENTIALS'
}
conn.request("GET", "/subscription/getsubscription?subscriptionId=S68732954", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))var request = require('request');
var options = {
'method': 'GET',
'url': 'https://rest.cleverbridge.com/subscription/getsubscription?subscriptionId=S68732954',
'headers': {
'Accept': 'application/json',
'Authorization': 'Basic YOUR_BASE64_ENCODED_CREDENTIALS'
}
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
Unirest.setTimeouts(0, 0);
HttpResponse<String> response = Unirest.get("https://rest.cleverbridge.com/subscription/getsubscription?subscriptionId=S68732954")
.header("Accept", "application/json")
.header("Authorization", "Basic YOUR_BASE64_ENCODED_CREDENTIALS")
.asString();
Response
{
"Subscription": {
"Id": 68732954,
"Items": [
{
"RunningNo": 1,
"ProductName": "Cloudify Iron",
"ProductNameExtension": "Cloud Storage",
"DeactivationDate": "2026-05-29T12:28:39.131314",
"Status": 2
}
]
},
"ResultMessage": "OK"
}The response shows that the subscription contains one item with the running number 1. The item has a Status value of 2, which indicates that the item is Deactivated, and the DeactivationDate shows when the cancellation took effect. In the next step, use the item's RunningNo value (1) in the Items array of the Reinstate Subscription Items request to reactivate the item retroactively.
Subscription Item Status Parameters
# ID Status 1 ACT Active 2 DEA Deactivated 3 FIN Finished 4 HBC Handled by client 5 REM Removed 6 WAT Awaiting reinstate
Step 2: Reinstate the subscription item
Use the Reinstate Subscription Items endpoint to reactivate the subscription item effective from the original cancellation date.
Parameters
| Parameter | Type | Required | Example | Notes |
|---|---|---|---|---|
| SubscriptionId | str | Yes | S68732954 | The unique identifier of the subscription. |
| Items | array[int] | Yes | [1] | Array of subscription item running numbers to reactivate retroactively. |
Request
curl --location 'https://rest.cleverbridge.com/subscription/reinstatesubscriptionitems'
--header 'Content-Type: application/json'
--header 'Accept: application/json'
--header 'Authorization: Basic YOUR_BASE64_ENCODED_CREDENTIALS'
--data '{
"SubscriptionId": "S68732954",
"Items": [
1
]
}'import http.client
import json
conn = http.client.HTTPSConnection("rest.cleverbridge.com")
payload = json.dumps({
"SubscriptionId": "S68732954",
"Items": [
1
]
})
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'Authorization': 'Basic YOUR_BASE64_ENCODED_CREDENTIALS'
}
conn.request("POST", "/subscription/reinstatesubscriptionitems", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))var https = require('follow-redirects').https;
var fs = require('fs');
var options = {
'method': 'POST',
'hostname': 'rest.cleverbridge.com',
'path': '/subscription/reinstatesubscriptionitems',
'headers': {
'Content-Type': 'application/json',
'Accept': 'application/json',
'Authorization': 'Basic YOUR_BASE64_ENCODED_CREDENTIALS'
},
'maxRedirects': 20
};
var req = https.request(options, function (res) {
var chunks = [];
res.on("data", function (chunk) {
chunks.push(chunk);
});
res.on("end", function (chunk) {
var body = Buffer.concat(chunks);
console.log(body.toString());
});
res.on("error", function (error) {
console.error(error);
});
});
var postData = JSON.stringify({
"SubscriptionId": "S68732954",
"Items": [
1
]
});
req.write(postData);
req.end();Unirest.setTimeouts(0, 0);
HttpResponse<String> response = Unirest.post("https://rest.cleverbridge.com/subscription/reinstatesubscriptionitems")
.header("Content-Type", "application/json")
.header("Accept", "application/json")
.header("Authorization", "Basic YOUR_BASE64_ENCODED_CREDENTIALS")
.body("{\n \"SubscriptionId\": \"S68732954\",\n \"Items\": [\n 1\n ]\n}")
.asString();
JSON Body
{
"Items": [
1
],
"SubscriptionId": "S68732954"
}Response
{
"ResultMessage": "OK"
}Diagram
flowchart LR
classDef mainColor fill:#ffffff,color:#555555,stroke:#96C34B,stroke-width:2px;
A([" <br/><b>Subscription expires</b><br/>The customer's access to the service is disabled <br/> "]):::mainColor
--> B([" <br/><b>Reactivation request</b><br/>The customer resumes the subscription.Cloudify calls the <i>Reinstate Subscription Items</i> <br/> "]):::mainColor
--> C([" <br/><b>Access restored</b><br/>Cloudify restores access. Recurring billing continues from the reactivation date <br/> "]):::mainColor