Skip to main content

Documentation Index

Fetch the complete documentation index at: https://developers.kulmipay.com/llms.txt

Use this file to discover all available pages before exploring further.

Use M-Pesa B2B when you need to pay a business through an M-Pesa PayBill or Till number. This is typically used for supplier payments, bills, and business-to-business settlement.

Transaction fields

FieldRequiredDescription
accountYesPayBill or Till number.
account_typeYesUse PayBill or TillNumber.
account_referenceConditionalRequired for PayBill; this is the account number/reference on the bill.
amountYesAmount to send in KES.
nameNoRecipient name for your records.
narrativeNoPayment reason shown in your reports.

Pay a PayBill

curl -X POST https://app.kulmipay.com/api/v1/send-money/initiate/ \
  -H "Authorization: Bearer ISSecretKey_live_xxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "currency": "KES",
    "provider": "MPESA-B2B",
    "requires_approval": "YES",
    "transactions": [
      {
        "account": "400200",
        "account_type": "PayBill",
        "account_reference": "ACC-00123",
        "amount": "2500",
        "name": "Supplier Ltd",
        "narrative": "January invoice"
      }
    ]
  }'

Pay a Till number

For Till payments, set account_type to TillNumber and omit account_reference.
{
  "currency": "KES",
  "provider": "MPESA-B2B",
  "transactions": [
    {
      "account": "123456",
      "account_type": "TillNumber",
      "amount": "2500",
      "narrative": "Store payment"
    }
  ]
}

Validate before sending

Use POST /api/v1/send-money/validate-accounts/ to confirm the PayBill or Till account before initiating a payout.