Skip to content
Test mode: payments are simulated. No real money moves.
MutexPay

Developers

Code snippets

Copy-ready examples that match the API documentation. The full reference for every endpoint is there.

Start a payment

Ask the customer's phone to confirm an M-Pesa payment. Swap in your key, your email and the id of one of your connected accounts.

Read the status of a payment

Ask what M-Pesa has reported so far. Treat only TransactionStatus "Completed" as money received.

Check a webhook signature

A webhook that says "paid" is only worth acting on once you have checked who sent it. Use the raw request body exactly as it arrived.