Glossary

Safaricom Daraja API

Safaricom's developer API for M-Pesa, providing STK Push, Paybill and Till payment collection, B2C disbursement, and transaction status and reversal endpoints.

In plain terms

Safaricom’s developer interface for M-Pesa. It provides STK Push prompts, Paybill and Till collection, business-to-customer payments, and endpoints for checking transaction status and handling reversals.

Integrating directly means your system talks to M-Pesa rather than through a third party, which lowers the cost per transaction and gives you the data, at the price of owning the error handling.

Why it matters in Kenya

This is the payment rail for Kenyan online selling, and getting it right is mostly about the unhappy paths: a callback that never arrives, a customer who pays twice, a payment with the wrong reference, a refund after delivery.

What to do about it

Four checks you can run on your own site this week.

  • Make callbacks idempotent, so a repeated message cannot double-credit an order
  • Query transaction status as a fallback rather than trusting the callback alone
  • Keep a reconciliation view somebody in finance can actually use
  • Test with live low-value transactions before launch, not only in sandbox