Skip to content
Back to work

The Kingdom Collection

Kenyan clothing e-commerce with M-Pesa payment.

Write-up in progress: some sections are still draft copy.

Role
Full Stack Engineer
Duration
2 Months
Team
Solo Project
Status
Production
Platform
Web Store
Completed
August 2024
The Kingdom Collection interface

01

Overview

The Kingdom Collection is a modern e-commerce storefront built to showcase Kenyan fashion. This case study covers building a guest-checkout flow integrated with M-Pesa for local payment processing.

02

Problem

Kenyan designers need e-commerce solutions that support local payment methods.

03

Objectives

  • Build a frictionless guest checkout experience.
  • Integrate M-Pesa for payment processing.

04

Solution

  • Guest checkout
  • M-Pesa payment integration
  • Product filtering by category

05

Technology

ReactFlaskSQLAlchemyPostgreSQLCloudinaryM-Pesa

06

Architecture

React SPA + Flask REST API

React SPA on Cloudflare Workers talking to a Flask REST API hosted on Render.

Data. PostgreSQL via SQLAlchemy, with schema changes managed by Flask-Migrate.

API. Flask REST API for products, orders and M-Pesa payments.

Auth. Guest checkout, with JWT-based sign-in via Flask-JWT-Extended.

07

Key engineering decisions

Performance. Product images served from Cloudinary, with preconnects so the first photograph starts loading early.

Accessibility. Semantic markup and keyboard-reachable navigation.

Security. Payments are handled by M-Pesa, so card or wallet details never touch the store's server.

Trade-offs. Chose guest checkout over mandatory registration.

08

Challenges

Integrating M-Pesa API with payment confirmation.

Insights into African payment ecosystems.

11

Gallery

The Kingdom Collection
The Kingdom Collection

12

Links

Have a problem worth building?

Tell me what the software needs to do and who has to use it. If it is a good fit, I will come back with scope, a build order and a realistic timeline.