Overview

Sections

Theme switcher

Update Subscription Status

Body Parameters

CallerAccessKeystring Required

The access key provided by TG.

CallerSecretKeystring Required

The secret key provided by TG.

MerchantIdinteger

This field is deprecated and will be removed in future versions.

Empty value:
True
MSISDNstring Required

User's phone number. Optional if ExternalUserId or TgUserId is provided. When all three identifiers (TgUserId, ExternalUserId, and MSISDN) are provided, the system will prioritize them in the following order: TgUserId, ExternalUserId, and MSISDN. If no user is found with the provided phone number, a new user will be automatically created.

TnsIDstring Required

Unique Id for this transaction. Used for logging and troubleshooting purposes.

AppIDinteger Required

The application ID used to map the configuration. TG to provide.

PlanIDstring Required

The subscription plan ID.

TnsTypestring Required

The transaction type.

Enum values:
SubUnsub
GBillingStatusCodeinteger

This field is deprecated and will be removed in future versions.

GBillingStatusDescriptionstring

This field is deprecated and will be removed in future versions.

TelcoResponseBodystring

The raw response body from the external billing system.

TrialExpirystring

The trial expiry date. This is a legacy field and may be deprecated in future versions.

Circlestring

The user circle / region information.

ServiceKeystring

This field is deprecated and will be removed in future versions.

StartDatestring Required

The subscription start date. Required only when the transaction type is Sub. Accepted formats are either full ISO 8601 date-time YYYY-MM-DDTHH:MM:SSZ or date-only YYYY-MM-DD.

EndDatestring Required

The subscription end date. Required only when the transaction type is Sub. Accepted formats are either full ISO 8601 date-time YYYY-MM-DDTHH:MM:SSZ or date-only YYYY-MM-DD.

SubIdinteger

The unique identifier for a subscription. If provided, the system will attempt to update the existing subscription with this ID. If not provided, any existing subscriptions for the user will be removed, and a new subscription will be created. It's recommended to provide the SubId when renewing an existing subscription to ensure continuity and prevent unintended replacement.

ExternalUserIdstring Required

The external system identifier for the user. Optional if MSISDN or TgUserId is provided. When all three identifiers (TgUserId, ExternalUserId, and MSISDN) are provided, the system will prioritize them in the following order: TgUserId, ExternalUserId, and MSISDN. If no user is found with the provided external ID, a new user will be automatically created.

TgUserId integer Required

The Tuned Global user Id. Optional if MSISDN or ExternalUserId is provided. When all three identifiers (TgUserId, ExternalUserId, and MSISDN) are provided, the system will prioritize them in the following order: TgUserId, ExternalUserId, and MSISDN. If no user is found with this ID, a new user will be automatically created using the MSISDN provided.

HadTrialboolean

This field indicates whether the user has had a trial period. Defaults to false.

Emailstring

The email of the user. Optional if at least one of the identifiers (MSISDN, ExternalUserId, or TgUserId) is provided

Response

200
Object

Subscription status was processed successfully.

400
Object

The request failed to be processed. The response body contains the error message.

Was this section helpful?

POST

/

Select
1

Response

Was this section helpful?