All projects

Headless e-commerce

Headless WooCommerce Platform

Role

Full-stack developer

Year

2025

Client

Stack

WordPressWooCommercePHPREST APIs

Overview

The business already ran its storefront on WordPress, and the content team knew that workflow well — so the brief was never "replace WordPress." It was "keep it, but stop letting it be the bottleneck." Products, categories, and content stayed managed the way editors already understood, while everything that needed to move fast — checkout, order status, stock levels — got pulled out from behind wp-admin and put behind an API instead.

That's the shape the platform settled into: WordPress and WooCommerce running headless, as the system of record for products, carts, checkout, and inventory, with a decoupled frontend consuming all of it over REST. WordPress kept doing what it was good at; everything downstream just stopped depending on wp-admin to get there.

The challenge

Before this platform existed, running the storefront meant living in three places at once: the WordPress site itself, a Lazada seller dashboard, and a TikTok Shop dashboard. Each one had its own order list, its own notion of what was in stock, and no idea the other two existed. A morning shift started with logging into all three, cross-checking new orders by hand, and copying details across so fulfillment had a complete picture.

The sharpest version of the problem: a unit sold on TikTok Shop didn't decrement the stock count shown on the website, so the same item could get sold twice before anyone noticed the mismatch.

That kind of manual reconciliation is fine at a handful of orders a day. It stops being fine once order volume grows past what one person can eyeball across three tabs — which is exactly the point this project stepped in.

Building the platform

The build started from the ground up with WooCommerce's own fundamentals — products, categories, cart, checkout, and stock — getting those solid before anything else was layered on top. Once that core was reliable, the next step was wrapping it in a REST API so nothing outside of it had to touch wp-admin directly to read a product, place an order, or check stock.

That decision paid off almost immediately: WooCommerce could stay the single source of truth for products, orders, and inventory, while every other system — the storefront, internal tooling, and eventually the marketplace integrations — just talked to the same API instead of duplicating that logic themselves.

Marketplace sync

With a solid API in place, the marketplace side came next. Scheduled jobs pull orders from the Lazada and TikTok Shop seller APIs on a regular cycle, normalize each one into WooCommerce's order shape, and drop it into the same order queue as a direct site sale — no separate table, no separate status list to check.

Stock deduction follows the same rule regardless of where the sale happened: an order pulled in from TikTok Shop reduces inventory exactly the way a checkout on the website would, so the count shown across every channel reflects what's actually left.

One order queue, three sales channels — direct site, Lazada, and TikTok Shop all land in the same fulfillment flow instead of three separate dashboards, and stock stays consistent across all of them.

Outcome & stack

The end result is a fulfillment team that checks one queue instead of three dashboards, and a stock count that means the same thing no matter which channel sold the item. The headless split also meant the storefront could keep evolving on its own schedule without waiting on WordPress core or plugin updates.

Under the hood: WordPress and WooCommerce for the commerce core, PHP for the custom integration layer, and REST APIs tying together the marketplace order feeds, the headless frontend, and everything in between.

More work
this way.

All projects