Skip to main content

Case Study

Scan a QR code. Know the medicine is real β€” and where it has been.

How Betadrix Tech built a QR-based pharmaceutical traceability platform for Virtual Tech Gurus β€” unit-level IDs, controlled custody transfers and a public, no-login verification layer, live in 11 weeks.

Secure & PrivateProduction ReadyHuman-in-the-LoopScalable Architecture
Production Ready EngineeringSLA Guaranteed
Scan a QR code. Know the medicine is real β€” and where it has been.
Architecture (Scalable)
Security (Enterprise)
Performance (Optimized)
Integration (Seamless)
Enterprise Technical StackProduction Hardened
Service Deep Dive

Overview

Virtual Tech Gurus needed two things at once: one-scan medicine verification for customers and a much stricter supply chain underneath. Betadrix delivered a four-stage pharmaceutical traceability platform β€” company β†’ provider β†’ shop β†’ customer β€” with unit-level identifiers, server-side custody rules and a public verification layer that requires no login and no app.

Built with Node.js, React.js and PostgreSQL, the platform went from kickoff to production in 11 weeks, with ~230ms average API response and 99.9% uptime since go-live.

Every medicine unit carries a digital identity that follows it through each authorised handoff β€” and any customer can verify it with a phone camera.

"Reconciliation between our company, provider and shop records used to be a manual chore. Now it happens the moment stock is accepted, and our customers can verify any package with a scan."

Roman Harris
Operations Director at Virtual Tech Gurus Inc.

The problem was bigger than a missing tracking screen

Pharmaceutical products rarely move directly from the manufacturer to the person who uses them. There are handoffs: manufacturer β†’ provider β†’ shop β†’ customer.

At Virtual Tech Gurus, those steps lived in different places β€” paperwork here, spreadsheets there, systems that weren't really talking to each other. When someone wanted to know whether a particular package was legitimate, there was no reliable record behind the answer. Just a document to find later, or a spreadsheet that may or may not have been updated.

The brief was simple to explain β€” and much harder to build properly:

Put a QR code on a medicine package, let someone scan it with their phone, and show them whether that product is genuine and where it has been.

That meant solving two problems at once: make verification extremely simple for the customer, while making the underlying supply chain considerably stricter.

It's a challenge that sits exactly where healthcare software development meets logistics & transportation software development β€” regulated workflows on one side, custody moving between organisations on the other.

Four stages. One traceable record.

The platform covers the full chain: Company β†’ Provider β†’ Shop β†’ User. Each business stage has its own role-based interface and permissions; the customer-facing verification experience is deliberately different β€” it's public.

Four-stage pharmaceutical supply chain diagram showing a medicine unit moving from manufacturer to provider to shop to customer, with ownership transfers recorded at acceptance and a QR verification step at the end
Ownership is recorded when each party accepts the stock β€” not reconciled afterwards.

01 β€” Manufacture

The pharmaceutical company registers a drug type and creates individual medicine units under an active licence. Each unit receives a unique traceable ID, mapped to its QR code at creation. The rule is enforced at the API level β€” not in the interface:

POST /api/v1/medicine-units
β†’ 422 Unprocessable Entity

{
  "error": "LICENCE_REQUIRED",
  "message": "A medicine unit cannot be created without an active licence for this drug type."
}

02 β€” Distribution

The provider receives stock through the company-side workflow. Ownership isn't updated later through a separate reconciliation process β€” the transfer is recorded when the provider accepts the stock. Every handoff writes an event:

{
  "unitId": "MED-2024-000123",
  "event": "OWNERSHIP_TRANSFER",
  "from": "acme-pharma",
  "to": "medsupply-co",
  "recordedAt": "2024-06-14T09:32:11Z"
}

That gives the system a clean answer to the most basic supply-chain question: who actually had this product, and when?

Retail, and the moment the customer scans

03 β€” Retail

The shop receives the product from the provider and dispenses it to the customer. The shop-side transaction closes the operational part of the chain and updates the unit's state β€” at this point the system holds a connected custody trail, not a collection of disconnected records.

04 β€” Customer verification

A customer scans the QR code printed on the package. The verification page returns the product's status and custody history β€” no account, no login, no app to install. The customer doesn't need to understand the architecture; they just need an answer: is this product what it says it is, and does its history make sense?

Smartphone showing a medicine verification page with the product marked genuine and a custody timeline listing each handoff from manufacturer through provider to pharmacy
The public verification page: product status and custody history in one scan.

What happens when a scan doesn't check out

Verification is only useful if it also fails loudly. An unknown code returns an explicit not recognised result β€” never a blank screen. A unit whose history doesn't add up shows that status plainly. The failure states are where the anti-counterfeit value lives, so they're treated as first-class outcomes, not error pages.

The QR code wasn't the hard part

Key architectural decisions
  • One traceable record per medicine unit β€” the QR code points to it; the record tells the story.
  • Licence-gated creation β€” enforced at the API, not the interface.
  • Forward-only ownership transfers β€” recorded at acceptance, never sideways or backwards.
  • Separated public verification endpoint β€” rate-limited, minimal data exposure.
  • PostgreSQL as the single source of truth β€” every handoff writes an audit event.

It's tempting to think the QR code is the product. It isn't β€” the QR code is the doorway. The hard part is everything that has to be true after someone scans: a reliable record of the unit, who created it, who received it, who holds it now, no invalid ownership movements β€” and enough exposed to be useful without leaking internal identifiers. Four layers deliver that:

Role-based access

Company and provider users operate through role-based panels, creating, receiving and transferring stock according to the permissions assigned to their stage. Every important action is tied to an audit record.

Server-side business rules

The REST API doesn't leave critical rules to the frontend. Ownership can move forward through the defined chain β€” never sideways or backwards. A button being hidden in React is not a security rule. The backend has to enforce it too.

ConcernWhere it's enforced
No unit created without an active licenceREST API (server-side)
Ownership moves forward only β€” never sideways or backwardsREST API (server-side)
Who can create, receive or transfer stockRole-based panels + audit records
Public access without exposing internal identifiersSeparated, rate-limited verification endpoint

A single source of truth

A relational PostgreSQL layer maintains the traceable record for each individual unit β€” a digital identity that follows every package through the supply chain.

A public verification layer

The customer-facing endpoint is intentionally separated from the internal management environment. It's rate-limited and returns only the information needed for verification. Simple from the outside; controlled underneath.

Built for a regulated industry

Pharmaceutical traceability doesn't exist in a regulatory vacuum. In the US, the DSCSA requires unit-level serialization and interoperable electronic tracing of prescription drugs. In the EU, the Falsified Medicines Directive mandates a unique identifier on each pack, verified at the point of dispensing. Underneath both sits the GS1 serialization model β€” a unique identity per saleable unit, plus batch and expiry β€” which has become the industry's common language.

The platform's design β€” unit-level identifiers, event-recorded custody changes at every handoff, licence-gated creation β€” is the same pattern those regulations are built around. Market-specific requirements layer on top of this foundation rather than requiring a rebuild.

Because traceability isn't just knowing where something is β€” it's establishing a trustworthy history:

  • Who created it?
  • Who received it?
  • Who transferred it?
  • Who currently holds it?
  • Was that movement allowed?
  • Can the customer verify the product without access to the internal system?

These questions get harder when a product passes through multiple organisations. The same pattern extends well beyond pharmaceuticals: give every unit an identity, enforce the rules at every handoff, and make the history available to the people who need it. That's the core of any multi-stage logistics platform β€” and where existing enterprise systems are involved, ERP integration services can bring them into the traceability flow instead of forcing a replacement.

Eleven weeks to production

The sequence was deliberate:

  1. Backend and data model β€” the foundation had to be stable first.
  2. Business rules and API β€” built around the actual supply-chain workflow, not around the screens.
  3. Role-based panels and the QR verification experience β€” once the chain underneath was solid.

Testing wasn't saved for the final few days; it was folded in as each part came together. That worked because the project was never four separate interfaces β€” it was one chain. If the manufacturing logic was wrong, the provider workflow would expose it. If the transfer logic was wrong, the customer's verification history would be wrong.

The stack was chosen for fit, not fashion: Node.js for the backend and API layer, React.js for the operational interfaces, and PostgreSQL as the relational source of truth for every traceable record.

When the workflow itself is the product and no off-the-shelf system fits, this is the territory of custom software development β€” the platform is shaped around the chain, not the other way round.

What happened after go-live

The numbers since launch:

MetricResultWhy it matters
Delivery11 weeks to productionOne quarter from kickoff to live
API response~230ms averageA QR scan feels instant on a phone
Uptime99.9% since go-liveReliable enough for daily operations
Friction0 logins, 0 app installsEvery customer can verify, not just the committed ones
Units tracked47,000+Scale of real operational use
Reconciliation~80% effort removedHandoffs recorded at acceptance instead of manual cleanup

The ~230ms response time matters in a slightly boring but very real way: someone points a phone at a package and expects an answer almost immediately. A verification page shouldn't feel like an old database lookup.

The quieter win was operational. Manual reconciliation between the company, provider and shop sides was largely reduced β€” the system records each handoff as it happens instead of relying on people to reconcile separate records afterward.

β€œReconciliation between our company, provider and shop records used to be a manual chore. Now it happens the moment stock is accepted, and our customers can verify any package with a scan.” β€” Roman Harris, Operations Director, Virtual Tech Gurus Inc.

That's the kind of improvement that matters six months after launch, when the novelty has worn off and people are simply using the system every day.

Frequently Asked Questions

No. The verification layer is public: scanning the QR code opens a page showing the product's status and custody history. No login and no app installation. Removing that friction was a deliberate product decision.
An unverifiable scan is treated as a first-class outcome, not an error. Unknown codes return an explicit not-recognised result, and units whose history doesn't add up show that status plainly. The failure states are where the anti-counterfeit value lives.

Project Details

Client
Virtual Tech Gurus Inc.
Industry
Pharmaceutical Supply Chain
Timeline
11 weeks from kickoff to production
Technology Stack
Node.jsReact.jsPostgreSQLTailwind CSSRedisGS1 Barcode / QRREST API
Key Result
Weeks to production

Scope Your Project

Connect with our technical architects to get a complete scope of work and execution plan.

  • Strict NDA Protected
  • Free Technical Estimate
  • Direct Architect Call
Technical Scoping

Ready to build high-performance infrastructure?

Our senior technical architects analyze your requirements, design real-time data flows, and build a production-ready execution roadmap.

  • Tailored System Architecture
  • Performance & Security Audit
  • Clear Production Roadmap
Lead Diagnostic

Let's build something serious.

Diagnose your system architecture, budget ranges, and roadmap parameters with an expert.

AI Fit Finder

Scoping Diagnostic

Analyze your workflows in 60 seconds. A senior AI architect reviews every parameter personally.

Real Client Outcomes
+22%
Revenue Growth
$5.12M from $4.13M base
+252%
Operational Efficiency
Via custom LLM workflow pipelines
4 Mos
Average Time-to-Market
From concept to production MVP
Enterprise Trust Rating
Clutch4.9/5.0 Partner
GoodFirms4.8/5.0 Leader
Google4.9/5.0 Rated
Trustpilot4.8/5.0 Excellent

Not sure where AI actually moves the needle for you?

Answer a few brief questions. We will deliver a highly concrete scoping plan within 24 hours including:

  • Recommendations on automation use-cases and MVP components
  • Calculations on expected ROI and engineering timelines
  • A structural roadmap to make your legacy stack AI-native