API Reference
Hosted Checkout
Create Checkout [POST]

Create Checkout

https://sandboxapi.bitnob.co/api/v1/checkout (opens in a new tab)

Creating a payment checkout


Body Parameters

ParametertypeRequired
satoshis
Payment amount
int32
reference
Payment Reference
string
description
Transaction Description
string
customerEmail
Email of paying Customer
string
notificationEmail
Email where status of payment will be sent to
string
callbackUrl
URL a customer is sent to after successful payment
string
successUrl
Link to business success page
string

Request

Hosted checkout/Create Checkout [POST]
curl --request POST \
     --url https://sandboxapi.bitnob.co/api/v1/checkout \
     --header 'Authorization: Bearer API-KEY' \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --data '
{
  "satoshis": 0,
  "reference": "string",
  "description": "string",
  "customerEmail": "string",
  "notificationEmail": "string",
  "callbackUrl": "string",
  "successUrl": "string"
}
'

Response

🟢 200 OK
{
  "status": true,
  "message": "create checkout successful",
  "data": {
    "reference": "checkoutref",
    "satAmount": "1000",
    "description": "string",
    "currency": "btc",
    "status": "unpaid",
    "expiresAt": "2022-01-26T11:02:10.509Z",
    "lightningExpiresAt": "2022-01-25T14:02:10.000Z",
    "callbackUrl": "https://string.com",
    "successUrl": "https://string.com",
    "satAmountPaid": "0",
    "id": "0fe33b67-7b1b-4e52-8304-6f56c8e6f546",
    "createdAt": "2022-01-25T11:02:10.513Z",
    "updatedAt": "2022-01-25T11:02:10.513Z"
  }
}