Skip to main content

Integration Journey

The Subscription Module allows SmartPay integrators to create and manage complex subscriptions, plans, monitor charges and automated payments.

Authentication

Subscription solution supports strong API authentication. Thus, in order to authenticate within the APIs, basic authorisation header is to be provided, using:

  • Username: being your merchantKey
  • Password: key provided

(merchantKey & Passwords shall be provided by your dedicated Product Solutions Specialist).

Additionally, the merchantKey must be provided in the HEADER of the request in the property X-API-KEY (merchantKey should be previously provided by your dedicated Product Solutions Specialist Sandbox vs. Production).

important

This must be done for every request to the Subscription APIs. If not provided, the API will return HTTP 403 - Forbidden.

Subscription Process Flow

  1. Subscription Plans are created by calling the Subscription Module API Create Subscription Plan. The plan ID returned in the response could be then used for creating underlying subscription(s).
  2. Your server creates a new subscription by calling the API method Create subscription. Alongside your secret Merchant Key which authenticates your request, you shall provide also the Customer Account ID for an existing or a new customer. You would receive a response including the The Subscription ID, which is a unique identifier of the subscription.
  3. Your server forwards the Subscription ID to your client for the initialization of the Subscription Widget.
  4. The customer securely submits their payment information via the initialized Subscription Widget. It directly communicates to the acquirer for the authentication of the payment instrument. Once finished, it provides the storing of the payment option status via a JavaScript callback.
  5. The stored payment option would then be used by our system to trigger MIT payments as per the Subscription details (amount, recurrence, ect). Depending on the details of the created subscription, our backend would create a billing cycle for each due charge. Each billing cycle would be linked to at least one transaction.

For the full details of the available features and APIs please refer to this section.

Payment Serie Process Flow

  1. A Payment Serie is created by calling the Subscription Module API Create Payment Serie. You would receive a response including the The Payment Serie ID, which is a unique identifier of the payment serie.
  2. Your server forwards the Payment Serie ID to your client for the initialization of the Subscription Widget.
  3. The customer securely submits their payment information via the initialized Subscription Widget. It directly communicates to the acquirer for the authentication of the payment instrument. Once finished, it provides the storing of the payment option status via a JavaScript callback.
  4. At this point, whenever you want to trigger an MIT transaction under the created Payment Serie, you can call the Create PS Transaction API.

For the full details of the available features and APIs please refer to this section.