Portfolio Project

Safaricom Daraja API
Integration Demo

A sandbox application demonstrating STK Push, STK Query, C2B and B2C payment flows using the Safaricom Daraja REST API — built with Laravel and pure CSS.

Laravel 13 PHP 8.3 MySQL Daraja Sandbox Pure CSS

STK Push

Trigger a payment prompt on a customer's phone via M-Pesa Express.

Open

STK Query

Check the status of a previous STK Push by Checkout Request ID.

Open

C2B Simulate

Simulate a customer paying a business shortcode via Paybill.

Open

B2C Payment

Send money from a business to a customer's M-Pesa wallet.

Open
Recent Transactions View all

No transactions yet. Use one of the API forms above to make your first call.

Sandbox Reference

Shortcode

174379

Test Phone

254708374149

Environment

Sandbox

Base URL

sandbox.safaricom.co.ke