The backend powering The Hub - a multi-vendor e-commerce marketplace built for the Kenyan market. Handles auth, merchant onboarding, product listings, orders, and MPESA payments.
Endpoints
Register, login, email verification, password reset, and 2FA.
Fetch and update user profiles.
Merchant applications, shop creation, and storefront management.
Create and manage product listings scoped to a merchant's shop.
Checkout, order tracking, and merchant fulfilment.
MPESA Daraja STK Push, callbacks, and payment status polling.
User management, merchant approvals, and platform oversight.
Built with
Base URL
All requests are prefixed with /api
Responses always include a success boolean and a data or error field. Authentication uses JWT Bearer tokens with a 15-minute access token and a 7-day rotating refresh token.