Churn Prevention Campaigns
Retrieve the list of eligible campaigns for a specific subscription.
Path parameters
SubscriptionReferencestringRequiredExample:
Unique, system-generated subscription identifier.
48F5AC7011LanguagestringRequiredExample:
The language abbreviation in which messages are translated
enHeader parameters
Acceptstring · enumRequiredDefault:
application/jsonExample: application/jsonPossible values: X-Avangate-AuthenticationstringRequiredExample:
Authentication header
code="{VENDOR_CODE}" date="{REQUEST_DATE_TIME}" hash="{HASH}"Responses
200
Successful response
application/json
400
Invalid subscription
application/json
404
Invalid language
application/json
get/subscriptions/{SubscriptionReference}/churn-campaigns/eligible/{Language}
GET /rest/6.0/subscriptions/{SubscriptionReference}/churn-campaigns/eligible/{Language} HTTP/1.1
Host: api.2checkout.com
Accept: application/json
X-Avangate-Authentication: code="{VENDOR_CODE}" date="{REQUEST_DATE_TIME}" hash="{HASH}"
{
"AvailableCancellationReasons": {
"ANY_ADDITIONAL_PROPERTY": "text"
},
"Campaigns": [
{
"Code": "text",
"Name": "text",
"DefaultMessage": "text",
"CancellationReasonRequired": true,
"RestrictedToCatalogPrices": true,
"OfferPause": true,
"OfferDiscount": {
"Message": "text",
"Discount": 1,
"DiscountType": "PERCENT",
"BillingCycles": "text"
}
}
]
}Accept discount from a churn prevention campaign for a specific subscription.
Path parameters
SubscriptionReferencestringRequiredExample:
Unique, system-generated subscription identifier.
13E4ED768DCampaignCodestringRequiredExample:
Unique, system-generated campaign identifier.
IHMMYIAZULAZDHZGOLIYHeader parameters
X-Avangate-AuthenticationstringRequiredExample:
Authentication header
code="{VENDOR_CODE}" date="{REQUEST_DATE_TIME}" hash="{HASH}"Acceptstring · enumRequiredExample:
application/jsonPossible values: Responses
200
OK
application/json
400
Invalid subscription
application/json
post/subscriptions/{SubscriptionReference}/churn-campaigns/{CampaignCode}/accept-discount
POST /rest/6.0/subscriptions/{SubscriptionReference}/churn-campaigns/{CampaignCode}/accept-discount HTTP/1.1
Host: api.2checkout.com
X-Avangate-Authentication: code="{VENDOR_CODE}" date="{REQUEST_DATE_TIME}" hash="{HASH}"
Accept: application/json
trueMark auto renewal cancellation intent for a specific subscription.
Path parameters
SubscriptionReferencestringRequiredExample:
Unique, system-generated subscription identifier.
351D8F557ECampaignCodestringRequiredExample:
Unique, system-generated campaign identifier.
UGPPKKJY5L1LHBFPHKQ3Header parameters
X-Avangate-AuthenticationstringRequiredExample:
Authentication header
code="{VENDOR_CODE}" date="{REQUEST_DATE_TIME}" hash="{HASH}"Acceptstring · enumRequiredExample:
application/jsonPossible values: Body
StepstringRequiredExample:
REASONSuccessintegerRequiredExample:
0ReasonstringRequiredExample:
CHURN_REASON_NOT_SATISFIEDCommentstringOptionalExample:
Not satisfied because …Responses
200
OK
application/json
400
Invalid campaign
application/json
post/subscriptions/{SubscriptionReference}/churn-campaigns/{CampaignCode}/enter
POST /rest/6.0/subscriptions/{SubscriptionReference}/churn-campaigns/{CampaignCode}/enter HTTP/1.1
Host: api.2checkout.com
X-Avangate-Authentication: code="{VENDOR_CODE}" date="{REQUEST_DATE_TIME}" hash="{HASH}"
Accept: application/json
Content-Type: application/json
Content-Length: 105
{
"Step": "REASON",
"Success": 0,
"Reason": "CHURN_REASON_NOT_SATISFIED",
"Comment": "Not satisfied because …"
}trueLast updated
Was this helpful?