1. Formulate Payload

Generate payload details to be passed to the checkout platform.

Parameters

Parameter nameTypeDescriptionRequired
merchantTransactionIDstringUnique identifier of the request for paymentTRUE
requestAmountstringMerchant amount to be collected.TRUE
currencyCodestringCurrency of the amount to be collectedTRUE
accountNumberstringA unique reference number identifying the customer's accountTRUE
serviceCodestringMerchant's service code. This can be found here.TRUE
countryCodestringThe ISO 3166-1 alpha-2 code of the country you wish to collect payment for. The country code ensures we present valid payment options available in that particular country.TRUE
dueDatestringTime window a customer should complete making a payment. If not passed passed time defaults to 12 hours. Date format is YYYY-MM-DD hh:mm:ss.FALSE
payerClientCodestringParameter to limit the payment that is presented to the customer. The value will be the payer client code fromFALSE
requestDescriptionstringShows the description of the item being purchased.FALSE
languageCodestringLanguage preferred by the merchant using the two letter ISO 639-1 code. Available language codes can be found here.FALSE
MSISDNstringCustomer's phone number formatted as given in the E.164 phone numbering.TRUE
customerFirstNamestringCustomer first nameTRUE
customerLastNamestringCustomer last nameTRUE
customerEmailstringCustomer email addressTRUE
successRedirectUrlstringThe URL where the customer will be redirected on merchant's site once a full payment is made.TRUE
pendingRedirectUrlstringThe URL where the customer will be redirected on merchant's site after a timeout period reaches and the request has not been paid or when the back button is clicked once you are redirected to checkout. Mandatory if timeout period is configuredFALSE
failRedirectUrlstringURL where the customer will be redirected to if a full payment is not done within the payment windowTRUE
paymentWebhookUrlstringA server to server URL endpoint that will be called to notify a merchant of a complete payment.TRUE
extraDataJSONAdditional data specific to a client's applicationFALSE

πŸ“˜

NOTE:

The MSISDN and customerEmail presented may be used to receive invoice and payment notifications to confirm completion of service.

The resulting checkout request details JSON object should be as follows:

{
    "merchantTransactionID": "<YOUR_UNIQUE_TRANSACTION_ID>",
    "requestAmount": "100",
    "currencyCode": "KES",
    "accountNumber": "10092019",
    "serviceCode": "<SERVICE_CODE>",
    "dueDate": "2019-06-01 23:59:59", //Must be a future date
    "requestDescription": "Dummy merchant transaction",
    "countryCode": "KE",
    "languageCode": "en",
    "payerClientCode": "",
    "MSISDN": "+2547XXXXXXXX", //Must be a valid number format
    "customerFirstName": "John",
    "customerLastName": "Smith",
    "customerEmail": "[email protected]",
    "successRedirectUrl": "<YOUR_SUCCESS_REDIRECT_URL>",
    "failRedirectUrl": "<YOUR_FAIL_REDIRECT_URL>",
    "pendingRedirectUrl": "<YOUR_PENDING_REDIRECT_URL>",
    "paymentWebhookUrl": "<PAYMENT_WEBHOOK_URL>",
    "extraData": {
      "bundleID": "30GB"
    }
}