Developer Hub

Build with BitnovaPay

REST API for Direct Pay (non-custodial STK) and Smart Gateway (cards, M-Pesa, PayPal, crypto). JSON in, JSON out.

# Direct Pay - STK to your own shortcode
curl -X POST https://pay.bitnova.co.ke/api/v1/stk-push \
  -H "Authorization: Bearer pk_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{
    "channel_id": 1,
    "amount":     2500,
    "phone":      "0712345678",
    "description":"School fees"
  }'

# Smart Gateway - custodial M-Pesa
curl -X POST https://pay.bitnova.co.ke/api/v1/charges \
  -H "Authorization: Bearer pk_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{
    "method":      "mpesa",
    "amount":      1500,
    "phone":       "0712345678"
  }'

API

One API. Both modes.

The same API key works for both Direct Pay and Smart Gateway. Webhooks, sandbox mode, and typed responses across the board.

REST API v1

Personal keys (pk_live_-). All endpoints: charges, payment-links, channels, STK push, webhooks, disbursements.

Signed Webhooks

HMAC-SHA256 on every event. Delivery log and retry tracking.

Sandbox Mode

Test with Daraja sandbox for M-Pesa and PayPal sandbox for cards. No real charges.

Plugins

WooCommerce and Shopify — enter your API key, webhook registers automatically.

Webhooks

Real-time event notifications

payment.success

Payment completed (Direct Pay or Smart Gateway)

payment.failed

STK cancelled, card declined, invoice expired

payment.refunded

Card or PayPal refund processed

payout.completed

Bulk disbursement sent to recipient

withdrawal.completed

Admin marked withdrawal as sent

invoice.paid

Invoice fully paid by customer

Signature Verification Guide →

Ready to build?

Get your API key, explore the sandbox, and go live when you're ready.