API Reference

This section documents the web flow with redirection to MondiaPay consent page.

Log in to see full request history

To purchase article (single purchase item) use this endpoint to initiate the purchase flow, this API can be accessed with Client Access Token obtained from the response of the Client Access Token API, if the endpoint is accessed with a Client Access Token then at the end of the purchase flow the redirect URL includes a (query) parameter "?code="

How to use:

  • Fill in Authorization header: Bearer C1234abcde-1234-abcd-1234-abcd1234abcd (Replace with access_token that starts with letter C obtained from response of Client Access Token API request)
  • (OPTIONAL) Add marketingCampaign details(conversionId, agency, medium...etc) to be relayed back in later notifications and stored in the purchase details.
  • Fill in the rest of the parameters as per your requirement.
  • In the response received, click on the href link which should direct you to the Consent Gateway page that will authenticate your purchase request and
  • Upon successful subscription there will be a redirect, that redirect WILL include parameter "code=" with an Authorization Code.

Purchase Link Validity period

The obtained href purchase link will be valid for single use only within 10 mins of its creation.

Authorization Code Validity period

The obtained Authorization Code will be valid for single use only!

Body Params
marketingCampaign
object

Markering campaign information used for the acquisition.

string
Defaults to test-test-00005

Transaction ID that you want to receive in notification for correlating the request with notification.

string
Defaults to DCB

Type of payment, this has to be 'DCB' (case sensitive) always.

string
Defaults to 1

Amount that you are trying to charge the customer. This amount is in main currency.

string
Defaults to Hago

Category of the product configured for your product, please contact your account manager to receive it.

string
Defaults to Hago

Product description configured for your product, please contact your account manager to receive it.

string
Defaults to Hago

Product ID configured for your product, please contact your account manager to receive it.

string
Defaults to Hago

Service ID configured for your product, please contact your account manager to receive it.

string
Defaults to https://www.mondiapay.com

The URL where user will be redirected to after transaction is complete.

Headers
string
Defaults to application/json

!DO NOT CHANGE OR REMOVE!

string
Defaults to application/json

!DO NOT CHANGE OR REMOVE!

string
Defaults to Bearer C570e8d5c-cbbb-4912-b83f-0a0e4aac571

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

Responses

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