Subscription Creation

Create an API flow session for a user subscription payment.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

This section covers the subscription flow process. To initiate a subscription purchase, use this endpoint as a starting point. When accessing this API, it is recommended to use a User Access Token obtained from the corresponding User Creation & Access Token API response.

Subscription Payment Process

Subscription Payment Process


To create an API flow session for user subscription payment, follow these steps:

1. Set the Request Details

  • URL: https://stg-gw.mondiapay.com/v1/api/purchase/subscription/oneClick

2. Add the Required Headers

Authorization Header: Fill in the Authorization header with the user access token obtained from the User Creation & Access Token API request, formatted as follows:

Bearer U1234abcde-1234-abcd-1234-abcd1234abcd

HeaderValue
Content-Typeapplication/json
x-api-keyYour API Key
AuthorizationGenerated User Access Token

3. Prepare the Request Body

Replace lang, subscriptionTypeId, & marketingCampaign in the body with your specific configuration values.

Request BodyDescriptionRequired
marketingCampaignMarketing campaign information used for the acquisition.Optional
langThe two-letter ISO-639-1 language code - defaults to client's default languageYes
subscriptionTypeIdThe Id of the subscription type (same as typeId returned in the Product endpoint)Yes

4. Make the Request

Once you’ve set the URL, headers, and body, proceed with a POST request.



Body Params
int32
Defaults to 12340001

Subscription type identifier, this is returned in the Product API. You can also contact your account manager to get this.

string
Defaults to en

The two-letter ISO-639-1 language code - defaults to client's default language

marketingCampaign
object

Marketing campaign information used for the acquisition.

Headers
string
Defaults to Bearer Ua0b1cd23-4e56-78f9-g0h6-5c68b92c5b4b

This field is mandatory and should follow the format: Bearer then single space then access_token that starts with letter U (obtained from response of User Access Token API.)

Responses

Language
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json