Skip to main content

Checkout

Checkout creates a hosted payment page. You redirect the customer to its url, and IntaSend shows the payment methods enabled on your account for that currency.

Checkout is authenticated with your publishable key, so you can call it from your frontend or your server.

curl -X POST https://api.intasend.com/api/v1/checkout/ \
-H "X-IntaSend-Public-API-Key: ISPubKey_test_xxxx" \
-H "Content-Type: application/json" \
-d '{
"amount": 1500,
"currency": "KES",
"email": "[email protected]",
"first_name": "Jane",
"last_name": "Doe",
"phone_number": "254712345678",
"api_ref": "order-123",
"redirect_url": "https://example.com/thank-you"
}'
{
"id": "0b7d…",
"url": "https://sandbox.intasend.com/checkout/0b7d…/express/",
"signature": "eyJ…",
"amount": 1500,
"currency": "KES",
"paid": false
}

Redirect the customer to url. After they pay, they are sent to redirect_url.

Request​

FieldRequiredDescription
amountYesAmount to charge, up to 2 decimal places. Minimum 0.10.
currencyNoKES (default), USD, EUR, GBP, UGX, TZS, RWF, CDF. UGX and TZS amounts must be between 500 and 5,000,000.
email, first_name, last_name, phone_numberNoPrefills the customer's details. Names are max 45 characters.
country, address, city, state, zipcodeNoBilling address (card payments). country is ISO-2.
api_refNoYour reference (letters, numbers, -, _, : and spaces, max 140 characters)
unique_api_refNotrue returns the existing checkout for this api_ref instead of creating a new one
redirect_urlNoWhere the customer goes after paying
wallet_idNoWallet to credit. Defaults to your settlement wallet for the currency.
hostNoYour site's URL. Defaults to the caller's IP address.
channelNoWhere the checkout comes from: WEBSITE (default), WOOCOMMERCE, SHOPIFY, WORDPRESS, BUBBLE or MOBILE. With WOOCOMMERCE, the result is also posted to {host}/wc-api/intasend_webhook/. With SHOPIFY, it is posted to the IntaSend Shopify app.
is_mobileNotrue when the checkout is opened from a mobile app
mobile_tarrif, card_tarrif, bank_tarrifNoWho pays the M-Pesa/mobile money, card and PesaLink fees. See Fees.
bitcoin_tarrif, pyusd_tarrif, ach_tarrif, transfi_tarrifNoWho pays the crypto (Bitcoin), PYUSD, ACH and TransFi fees: BUSINESS-PAYS (default) or CUSTOMER-PAYS
public_keyNoYour publishable key, if you can't send the X-IntaSend-Public-API-Key header

method is ignored. The customer picks the method on the page.

Fees​

Each tariff field takes BUSINESS-PAYS (the fee is deducted from what you receive) or CUSTOMER-PAYS (the fee is added to what the customer pays). See Who pays the fees.

note

For checkout, mobile_tarrif, card_tarrif and bank_tarrif currently follow the default tariff in your dashboard's payment settings, and the values you send are overridden. To change who pays these fees on checkout, change that setting.

Methods shown​

The page shows the methods enabled on your account:

CurrencyMethods
KESM-Pesa, card, Apple Pay, Google Pay, PesaLink, crypto
USD / EUR / GBPCard, Apple Pay, Google Pay, crypto
UGXMTN, Airtel
TZSM-Pesa TZ, Tigo Pesa, Airtel, HaloPesa

Confirming payment​

Don't treat a redirect to redirect_url as proof of payment. Instead, confirm with one of these: