Bro. Nungu

02 · Marketplace ecosystem

MaliGo

In development

A Tanzanian marketplace for new and used products.

Category
Marketplace ecosystem
Role
Product design & full-stack engineering
Built by
Empire Pro Dev
MaliGo home page on desktop in the light theme: product search, a category rail, a promotional carousel, sign-in and Sell on MaliGo panels, and a row of live deals from verified sellers.
MaliGo home page on a phone in the dark theme: search, New and Used shortcuts, a promotional banner, live deals and a bottom navigation bar.

Screens

MaliGo interface

  • MaliGo home page on desktop in the light theme: product search, a category rail, a promotional carousel, sign-in and Sell on MaliGo panels, and a row of live deals from verified sellers.
  • MaliGo home page on a phone in the dark theme: search, New and Used shortcuts, a promotional banner, live deals and a bottom navigation bar.
  • MaliGo product page on a phone in the light theme for a brand-new Apple iPhone 17, with rating, sales and views, and a sticky price bar with Add to cart and Buy now.
  • MaliGo used-products marketplace on desktop in the dark theme: a two-panel banner carousel, image tiles for browsing categories, and the Most wanted product row.
  • MaliGo product page on desktop in the light theme for an Apple iPhone 17 Pro: image gallery, verified seller card, specifications, and a buy box with price, quantity, Buy now and Add to cart.
  • MaliGo new-products marketplace on a tablet in the light theme: category chips, a banner carousel, category tiles and the Most ordered product row.
  • MaliGo seller store page on a tablet in the dark theme: a verified vendor header with rating and Message seller, sorting options, a Filters button and a grid of the store's listings.
  • MaliGo Home & Living category on desktop in the dark theme: subcategory shortcuts, filters for marketplace, condition, price and rating, sort options and a grid of discounted listings.

Overview

A marketplace ecosystem for Tanzania that connects buyers and sellers of new and used products, with administration, commerce workflows, analytics, and infrastructure designed to scale.

Product areas

  • Buyers
  • Sellers
  • New & used listings
  • Commerce workflows
  • Administration
  • Analytics
  • Authentication

Technologies

  • Next.js
  • TypeScript
  • Tailwind CSS
  • Prisma
  • Supabase
  • PostgreSQL
  • Upstash Redis
  • Cloudflare R2

Case study

From problem to product

The complete engineering lifecycle behind MaliGo.

  1. 01

    Problem

    Buyers and sellers of new and used products need an organised, trustworthy place to meet, with clear listings, simple workflows, and administration that keeps the marketplace healthy.

    • Buyers struggle to tell new stock from used goods, or to trust sellers they don't know
    • Sellers need a simple way to list, price and get paid
    • A marketplace without moderation fills up with bad listings
  2. 02

    Idea

    MaliGo: one marketplace ecosystem for Tanzania that brings buyers, sellers and administrators onto a single connected platform.

    • Separate New and Used marketplaces under one account
    • A commission added on top of the seller's price, so sellers keep exactly what they ask
    • Verified sellers, moderated listings and buyer protection
  3. 03

    Approach

    I built MaliGo as a modular monolith: one deployable application with strict layers, so business rules never live inside a page or a route handler.

    • Route handler, then application service, then repository, then database
    • Every subsystem degrades on its own; without a database it runs on a bundled demo catalogue
    • Money rules written and tested before the screens that use them
  4. 04

    Architecture

    Separate experiences for buyers, sellers and administrators sit on top of shared services for listings, commerce workflows, authentication and analytics.

    • One wrapper on every API route for rate limiting, sessions, role checks and input validation
    • PostgreSQL as the source of truth, Redis as a cache and cloud storage for media
    • Server-side role checks in both workspaces and every API route

    System architecture

    3 layers · 10 modules

    1. L01Experiences

      3 modules
      • Buyer marketplace
      • Seller workspace
      • Admin console
    2. L02Services

      4 modules
      • Listings & catalogue
      • Commerce workflows
      • Authentication & roles
      • Analytics
    3. L03Data & edge

      3 modules
      • PostgreSQL · Supabase
      • Redis cache
      • Cloudflare R2 media
    Conceptual architecture: layers and their responsibilities.
  5. 05

    Design

    MaliGo follows the layout shoppers already know from large marketplaces, rebuilt mobile-first on design tokens with light and dark themes.

    • Product cards in four variants from one data shape: grid, rail, list and mini
    • Sign-in as a modal, so a buyer never loses their place mid-cart
    • Filters, sorting and pagination kept in the URL, so every results page can be shared
  6. 06

    Development

    The code is strict TypeScript throughout, built around one pricing rule: commission is added to the seller's price, never taken from it.

    • Money stored as whole numbers in the smallest currency unit, never as floating point
    • Checkout re-prices every item on the server and reserves stock in a single transaction
    • Order lines keep snapshots of price and commission, so later rule changes never rewrite history
    • Seller and admin workspaces with dashboards, moderation, settlements and an audit log
  7. 07

    Data

    Analytics are part of the product scope from the start. Marketplace activity is treated as a source of insight, not an afterthought.

    • Commission rules resolved from seller, to category, to marketplace type
    • Seller analytics and admin dashboards built on real order data
    • Product structured data that marks each listing as new or used for search engines
  8. 08

    Testing

    Automated tests cover the rules where a mistake would cost money or trust.

    • Commission maths and rule resolution
    • Webhook signature verification and password hashing
    • The Redis-outage fallback, and rate limits that fail closed
    • Input validation and search query parsing
  9. 09

    Deployment

    MaliGo is deployed on Vercel, with PostgreSQL on Supabase, Upstash Redis and Cloudflare storage, each switched on independently through environment configuration.

    • Live at maligo-market.vercel.app
    • Type-checking, linting, tests and a production build run before every release
    • Caching falls back to the database if Redis is unreachable, so the marketplace stays up
  10. 10

    Result & current state

    The buyer marketplace, checkout, notifications and both workspaces are built and live. Messaging, disputes, delivery tracking and email and SMS notifications come next.

    • Built: marketplace, search and filters, cart, checkout, orders, favourites, and the seller and admin workspaces
    • Next: buyer-to-seller messaging, reviews written from the buyer side, and delivery tracking

What building it taught.

Challenges

  • Keeping prices honest when commission rules can change at any time
  • Two buyers racing for the last unit of stock
  • A payment provider calling back more than once for the same payment

Solutions

  • Immutable price and commission snapshots on every order line
  • A conditional stock reservation inside one transaction, so only one buyer can succeed
  • Each webhook event stored under a unique key before anything else runs, so a replay changes nothing

Lessons

  • Never let the browser send a price; derive it on the server every time
  • Decide deliberately which failures should fail open and which must fail closed
  • Snapshots are cheaper than explaining why an old order changed