The README asks you to do your own security testing, error handling and Safaricom compliance work before real money moves through it, and development has since moved to a different repository. Treat this as the version you experiment and learn with.
A Python server over Safaricom's Daraja API that lets an assistant start M-Pesa payment requests and generate payment QR codes, with a prompt for composing the request.
- `stk_push` — send an STK push so the customer authorises the payment on their own phone; takes `amount` and `phone_number` and returns the M-Pesa API response
- `generate_qr_code` — a scannable payment QR built from merchant name, transaction reference, amount, transaction type and the credit party identifier
- An `stk_push_prompt` that assembles the payment request from a phone number, an amount and a stated purpose
- OAuth authentication against Daraja handled by the server rather than by you
Python 3.12 and Daraja API credentials — a consumer key and secret — in a `.env` copied from the example. Install with uv: `uv venv`, activate it, `uv sync`, then point your client at `uv --directory /path/to/DarajaMCP run main.py`. Use the sandbox environment for development and switch the URL for production.
One command plus a key — uvx daraja, then supply credentials
