1. Formulate Payload
You should start by using the data in the table below, which contains a list of the parameters you can pass when initializing a transaction.
Parameters
Key | Value Type | Required | Description |
---|---|---|---|
merchant_transaction_id | String | Yes | Unique merchant reference for the request raised for express checkout. |
account_number | String | Yes | Account number for the customer on the merchant system. This is the reference the customer will pay to. |
msisdn | String | Yes | Customer's Phone number is formatted as given in the E.164 phone numbering |
country_code | String | Yes | 3 digit ISO code of the country you wish to collect payment for. |
currency_code | String | Yes | 3 digit ISO code of the currency the merchant is invoicing for. |
due_date | String | Yes | Time window a customer should complete making a payment. A future date when the request expires in UTC with the date format YYYY-MM-DD HH:mm:ss . If not passed passed time defaults to 12 hours. |
request_amount | Double | Yes | Amount you wish to start collecting for. |
service_code | String | Yes | The service code assigned to the merchant on the tingg portal |
callback_url | String | Yes | String of the endpoint we are to send the webhook request to. |
success_redirect_url | String | Yes | Where we will redirect the customer to after a successful payment is made. |
fail_redirect_url | String | Yes | Where we will redirect the customer to when the payment time passed above expires |
customer_first_name | String | No | Customer's first name |
customer_last_name | String | No | Customer's last name |
customer_email | String | No | Customer's email address. |
payment_option_code | String | No | Payment option code of the payment options the merchant wishes to collect for. |
pending_redirect_url | String | No | Where we redirect the customer to after the customer clicks back to the merchant |
request_description | String | No | Shows the description of the item being purchased. |
language_code | String | No | Language code you wish to display instructions for payment for. E.g
|
prefill_msisdn | Boolean | No | When set to false the phone number provided above will not be pre-filled in the payment form. Defaults to true |
charge_beneficiaries | JSONArray | No | Extra charge client we should settle to |
Charge_beneficiaries:
Key | Value Type | Required | Description |
---|---|---|---|
charge_beneficiary_code | String | No | This is the client who we are to settle to on behalf of the customer |
amount | Double | No | Amount we should settle the service provider above |
{
"msisdn":"+254700000000",
"account_number":"oid39",
"country_code":"KEN",
"currency_code":"KES",
"customer_email":"[email protected]",
"customer_first_name":"John",
"customer_last_name":"Doe",
"due_date":"2021-11-18 16:15:30",
"fail_redirect_url":"https://webhook.site/6c933f61-d6da-4f8e-8a44-bf0323eb8ad6",
"merchant_transaction_id":"txn_id_342",
"payment_option_code":"",
"callback_url":"https://webhook.site/6c933f61-d6da-4f8e-8a44-bf0323eb8ad6",
"pending_redirect_url":"https://webhook.site/6c933f61-d6da-4f8e-8a44-bf0323eb8ad6",
"request_amount":"100",
"request_description":"Dummy merchant transaction",
"success_redirect_url":"https://webhook.site/6c933f61-d6da-4f8e-8a44-bf0323eb8ad6",
"invoice_number":"",
"language_code":"en",
"service_code":"ABCDEXAMPLEONLINE",
"charge_beneficiaries":[
{
"charge_beneficiary_code":"KRA",
"amount":30
},
{
"charge_beneficiary_code":"GLOVO",
"amount":70
}
]
}
Updated 8 months ago