MIT recurring payments
MIT recurring payments (Merchant Initiated Transaction) enable you to accept a payment without involving the user, using a token.
These payments can be used for paying:
- utilities and mobile phone bills
- any memberships
- any subscriptions
Once you have a token, you can start accepting MIT recurring payments.
Accepting payments using a token
-
Create a payment session sending a
session/createrequest.Alternatively, you can use the
session/init/paymentmethod. In this case, specify all the payment parameters right away as it is specified in the next step and skip the next step. -
Send a
session/start/paymentrequest with therecurrentpayment type. Instead of a bank card, pass the token. Optionally, you can passinitiator:merchantin therecurrentobject ofpayment_details.Example
curl -X POST \
https://demo.smart-glocal.com/api/v1/session/start/payment \
-H 'Content-Type: application/json' \
-H 'X-PARTNER-PROJECT: your_project_name' \
-H 'X-PARTNER-SIGN: signature' \
-d '{
"session_id":"ps_3230",
"payment_details": {
"type": "recurrent",
"recurrent": {
"token": "e9876f32bcd947f79c324cf2da5726304a894f6ae2037de7705fdb3e0a134d39",
"initiator": "merchant"
}
},
"amount_details": {
"amount": 10000,
"currency": "usd"
},
"customer": {
"reference": "lucky"
}
}' -
Wait for a
ready_to_confirmwebhook. -
Send a
session/confirmrequest or asession/cancelrequest to confirm or cancel the operation. -
Wait for a
payment_finishedwebhook containing the payment status information.
Sequence diagram of MIT recurring payments
