Healthcare technology
Businesses Healthcare July 23, 2026 • 12 min read

How HealthPotli Fulfilled 500K Orders Without a Warehouse

For: COO or product lead at a mid-size pharmacy chain or healthcare distributor who has been handed a mandate to go digital and is trying to understand what a real fulfillment architecture looks like before they sign a contract with a vendor

HealthPotli fulfilled roughly 500,000 pharmacy orders without owning a single warehouse by treating partner pharmacies as distributed inventory nodes and building the routing, prescription-gating, and expiry logic in software — not by scaling operations. The non-obvious part: the storefront was the easy 20% of the build. The hard 80% was making sure a naive e-commerce fulfillment model didn't quietly dispatch expired stock, controlled substances without a valid prescription, or a drug from a pharmacy that couldn't legally ship to the patient's state. This post walks through how that pipeline was actually architected, what broke first, and what a mid-size chain going digital should copy versus avoid.

If you're a COO or product lead at a pharmacy chain or distributor with a mandate to go online, this is the concrete example most vendor decks won't give you.

The original problem: pharmacy fulfillment is not e-commerce

HealthPotli's goal looked simple from the outside: a patient opens an app, uploads a prescription or picks OTC items, pays, and a courier arrives. Amazon has trained everyone to expect this. The founders had partner-pharmacy relationships across multiple cities and no interest in taking on warehouse leases, cold-chain infrastructure, or dispensing licenses of their own.

The naive path — the one every generic e-commerce agency proposes — is: build a Shopify-style catalog, stock levels sync via CSV, orders route to the nearest pharmacy by pincode, done. This approach breaks in about four different ways at once when pharmaceutical inventory is involved:

Miss any one of these and you get an order that dispatches. Miss all four at scale and you're not running an online pharmacy fulfillment system — you're running an unlicensed drug distribution operation with a nice UI.

What the team tried first (and why it didn't hold)

The first iteration was closer to a marketplace pattern: catalog centrally maintained, partner pharmacies mark items in/out of stock via a merchant app, orders route by proximity, prescription uploads reviewed by an in-house pharmacist team before dispatch.

It worked at low volume. It started leaking as soon as order volume climbed:

None of these were individually fatal. Together, they created the classic mid-scale collapse: enough volume to reveal every weakness, not enough operational muscle to paper over them.

The architectural call: treat each pharmacy as a real-time fulfillment node, not a stock row

The rebuild pushed three ideas hard.

1. Inventory as a stream, not a snapshot

Partner pharmacies run their own point-of-sale software — a mix of local vendors, most of them legacy Windows apps with a SQL backend. Rather than asking partners to key stock into a merchant portal (which they wouldn't do reliably), the team built lightweight connectors and, where connectors weren't possible, a polling agent that read POS state directly. Stock changes flowed as events, not as periodic snapshots.

The platform maintained its own inventory projection per pharmacy per SKU per batch, updated on every POS event. When a walk-in customer bought 5 units, the platform knew within seconds. When an order was placed on the app, the units were soft-locked immediately and the pharmacy's projection dropped before any other user could see them as available.

This is the piece most pharmacy inventory management software vendors get wrong. They model inventory as a number to be updated. It's actually a ledger of batches, each with attributes, being mutated by two independent sales channels simultaneously.

2. Order routing as a constraint solver, not a proximity lookup

Routing an order to "the nearest pharmacy" is what you do for pizza. For a pharmacy order, the router had to satisfy a stack of constraints in order:

  1. Is every SKU in the cart available at this pharmacy right now, in a quantity sufficient, from a batch that isn't expired and isn't so close to expiry that shipping it is inappropriate?
  2. Is this pharmacy licensed to dispatch every SKU in the cart to the patient's delivery address?
  3. For Rx items, does the pharmacy have a licensed pharmacist on shift to validate and dispense?
  4. Can the pharmacy commit to a pickup window that meets the patient's promised delivery slot?
  5. Only now — of the pharmacies that pass 1–4 — which is nearest / cheapest / has best fulfillment history?

When no single pharmacy could satisfy the full cart, the router split the order across multiple pharmacies with independent dispatches, and the patient-facing UI reconciled that into a single order experience. Split fulfillment sounds obvious. Building it so the patient sees one order, one invoice per pharmacy for compliance, one delivery ETA, and one refund flow if something fails — that's where most builds cut corners and pay for it later.

3. Prescription verification as a pipeline, not a queue

The human pharmacist bottleneck got broken by staging the workflow:

The drug interaction check is one of the pieces where AI genuinely earned its place. Rules-based interaction engines exist and are used, but layering a model that can reason about the patient's active prescription history — not just the current cart — caught edge cases the pure rules engine missed. You can see more of that pattern in the HealthPotli case study.

What actually moved the metrics

A few outcomes to be concrete about, without inventing numbers that weren't measured:

What this architecture is bad at

Being honest about tradeoffs matters more than the wins.

If you're a pharmacy chain that already owns stores, this last point flips in your favor — you do control the counter experience. The distributed-node model becomes even stronger when the nodes are yours.

What generalizes to a pharmacy chain going digital

If you're at a mid-size chain evaluating vendors, here's what to press on before signing anything:

Ask how they model inventory

If the answer is "we sync stock counts from your POS every N minutes," walk away. Ask specifically: does the system track batch and expiry per SKU per location? What happens if a walk-in sale reduces stock between the time an order is placed and the time it's picked?

Ask how the router handles multi-store fulfillment

A chain has an inherent advantage over a marketplace — inventory pooling across your stores. But most off-the-shelf e-commerce platforms cannot route a single order across multiple store locations. Ask for a concrete walkthrough of what happens when the nearest store has 8 of 10 items and the next store has the other 2.

Ask how prescription workflow is staged

If every Rx order sits in one queue for one team to review, that's your future scaling wall. Ask what auto-clears, what escalates, and how the audit trail is stored.

Ask about the compliance surface

Batch numbers on invoices. Pharmacist-of-record on dispatch. State-level dispatch restrictions. Schedule H1 register maintenance. If the vendor's answer is "we'll add that in a later phase," the platform is not actually a pharmacy platform. It's a storefront.

Ask what the system does when it doesn't know

The right answer to "a pharmacy hasn't reported stock in 30 minutes" is not "we assume it's still what we last saw." It's "we degrade that pharmacy's routing priority or take it offline until we hear back." How the system fails matters more than how it succeeds.

How CodeNicely can help

HealthPotli is the reference build for pharmacy operators who need this pattern. The team that built it worked through the specific failure modes above — the batch-level inventory ledger, the constraint-based router, the staged prescription pipeline with AI-assisted drug interaction checks, and the operational tooling for pharmacists and dispatch coordinators. If you're a chain or distributor and your problem shape looks like "we have physical stores, partner relationships, or both, and we need a fulfillment platform that respects pharmaceutical constraints instead of pretending they're the same as retail," that's the engagement pattern that fits.

The relevant reading is the HealthPotli case study for the pharmacy-specific work, and the broader digital transformation and AI studio pages if you want to see how the AI components (OCR, interaction checks, routing) get built and owned by you rather than rented. Engagements include full IP transfer — the platform is yours, not licensed back to you.

The takeaway

The reason HealthPotli fulfilled 500,000 orders without a warehouse isn't clever logistics. It's that the team refused to build pharmacy fulfillment as if it were book fulfillment. Every architectural decision — event-driven inventory, constraint-based routing, staged prescription verification, batch-level tracking — was a direct response to the fact that pharmaceutical inventory is simultaneously location-bound, expiry-sensitive, and prescription-gated. Skip any one of those and the system dispatches wrong at scale.

If you're evaluating an e-pharmacy platform architecture for your chain or distribution business, the vendor questions above are worth more than any feature comparison sheet. The features are easy to demo. The failure modes are what determine whether the platform survives its 100,000th order.

Frequently Asked Questions

Do we need to own warehouses to run an online pharmacy?

No. The HealthPotli model shows partner-pharmacy fulfillment can scale into the hundreds of thousands of orders without operating a warehouse — provided the platform treats each pharmacy as a real-time fulfillment node with batch-level inventory visibility, not as a stock row updated occasionally. Owning stores gives you more control over the counter experience but doesn't change the core architectural requirements.

How is a pharmacy fulfillment system different from a normal e-commerce platform?

Three things: inventory is tracked at the batch level with expiry attributes, dispatch is gated by prescription validation for scheduled drugs, and routing has to enforce state-level dispensing licenses. A standard e-commerce fulfillment engine handles none of these natively, which is why bolting a pharmacy onto Shopify or WooCommerce breaks at moderate scale.

Can AI actually help with prescription verification, or is it hype?

It helps in specific places: OCR and structured extraction from prescription images, automated drug-interaction checks against the patient's active prescription history, and triage of which orders need human pharmacist review versus which can auto-clear. It does not replace the licensed pharmacist for scheduled drugs, and it shouldn't. The value is in cutting the queue that reaches the pharmacist, not in removing the pharmacist.

What's the biggest hidden cost of the distributed partner-pharmacy model?

Onboarding integration. Every partner pharmacy needs its POS connected to the platform, and pharmacy POS software in most markets is a fragmented mix of legacy vendors. Growth is gated by integration engineering capacity. Chains that already own their stores and can standardize the POS avoid most of this cost.

How long does a build like this take and what does it cost?

That depends heavily on your existing systems, partner network, regulatory geography, and how much of the workflow already runs in software versus paper. For a realistic scope and estimate, contact CodeNicely for a personalized assessment against your specific operation.

Building something in Healthcare?

CodeNicely partners with founders and tech teams to ship AI-native products that move metrics. Tell us about the problem you're solving.

Talk to our team