curl --request POST \
  --url https://api.nomba.com/v1/checkout/order \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'accountId: <accountid>' \
  --data '{
"order": {
    "orderReference": "90e81e8a-bc14-4ebf-89c0-57da752cca58",
    "customerId": "762878332454",
    "callbackUrl": "https://ip:port/merchant.com/callback",
    "customerEmail": "[email protected]",
    "amount": "10000.00",
    "currency": "NGN",
    "accountId": "01a10aeb-d989-460a-bbde-9842f2b4320f",
    "splitRequest": {
      "splitType": "PERCENTAGE",
      "splitList": [
        {
          "accountId": "01a10aeb-d989-460a-bbde-9842f2b4320f",
          "value": "65.45"
        }
      ]
    }
  },
  "tokenizeCard": "true"
}'
{
  "code": "00",
  "description": "Success",
  "data": 
  {
    "checkoutLink": "https://ip:port/checkout/78388899938",
    "orderReference": "fd3002af-d48b-40a0-adba-0b1c93635bd2"
  }
}

Create a checkout order

Create an online checkout order to accept payments from your customers

POST /v1/checkout/order

Kindly be aware that the optional boolean value tokenizedCard should be included or set to true only if you intend to tokenize your customer’s card for the purpose of attempting other card payments at a later time.

Please pass the accountId inside the order request object if you wish to generate a checkout link for a subaccount.

Request body

order
object
required

Account reference

tokenizedCard
boolean

Determines if the card used for payment is to be tokenized

Response body

code
string
required

Response code

description
string
required

Response description

data
object
curl --request POST \
  --url https://api.nomba.com/v1/checkout/order \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'accountId: <accountid>' \
  --data '{
"order": {
    "orderReference": "90e81e8a-bc14-4ebf-89c0-57da752cca58",
    "customerId": "762878332454",
    "callbackUrl": "https://ip:port/merchant.com/callback",
    "customerEmail": "[email protected]",
    "amount": "10000.00",
    "currency": "NGN",
    "accountId": "01a10aeb-d989-460a-bbde-9842f2b4320f",
    "splitRequest": {
      "splitType": "PERCENTAGE",
      "splitList": [
        {
          "accountId": "01a10aeb-d989-460a-bbde-9842f2b4320f",
          "value": "65.45"
        }
      ]
    }
  },
  "tokenizeCard": "true"
}'
{
  "code": "00",
  "description": "Success",
  "data": 
  {
    "checkoutLink": "https://ip:port/checkout/78388899938",
    "orderReference": "fd3002af-d48b-40a0-adba-0b1c93635bd2"
  }
}