BluePayAPI
Ask AI
BluePay
API Keys Support Dashboard

Payment status

Read the latest result for a checkout or invoice.

Payment status

Call from your backend with the same auth as STK. Pass one lookup key.

GET https://bluepay.co.ke/api/payment_status.php?checkout_request_id=…
POST https://bluepay.co.ke/api/payment_status.php
FieldNotes
checkout_request_idBest key — from STK response.
account_referenceInvoice id from the STK call. Returns the newest STK for that id. The same value can be sent as external_reference.
stk_request_idInteger from STK response.

paid = settled · found = row exists · order.status = pending|completed|failed · payment.pending_confirmation while receipt is RCHK-….

Example responses

{
  "ok": true,
  "success": true,
  "found": true,
  "paid": true,
  "failed": false,
  "stk_status": "SUCCESS",
  "stk_request_id": 42,
  "checkout_request_id": "ws_CO_...",
  "account_reference": "BPLINK-A8A25317",
  "external_reference": "BPLINK-A8A25317",
  "amount": 100,
  "phone": "254712345678",
  "payment": {
    "id": 10,
    "mpesa_receipt_number": "ABC12XYZ",
    "amount": 100,
    "phone": "254712345678",
    "transaction_time": "2026-04-19 09:50:00",
    "pending_confirmation": false
  },
  "wallet_topup": null,
  "created_at": "2026-04-19 09:48:00",
  "order": {
    "status": "completed",
    "checkout_request_id": "ws_CO_...",
    "external_reference": "BPLINK-A8A25317",
    "amount": 100,
    "phone": "254712345678",
    "stk_request_id": 42
  }
}

Not found (still 200)

{
  "ok": true,
  "success": true,
  "found": false,
  "paid": false,
  "failed": false,
  "stk_status": null,
  "message": "No matching STK for this merchant yet",
  "payment": null
}

422

{ "ok": false, "success": false, "error": "Provide checkout_request_id, account_reference, external_reference, or stk_request_id" }