Skip to main content
SHIPPING Q1 · 3 AI-NATIVE SaaS PRODUCTS300+ SALESFORCE PROJECTS DELIVERED15+ YEARS · TRUSTED IMPLEMENTATION PARTNERAI AGENTS · LLM · RAG · MLOPS · NOW HIRINGLIVE IN PRODUCTION ACROSS 3 INDUSTRIESSHIPPING Q1 · 3 AI-NATIVE SaaS PRODUCTS300+ SALESFORCE PROJECTS DELIVERED15+ YEARS · TRUSTED IMPLEMENTATION PARTNERAI AGENTS · LLM · RAG · MLOPS · NOW HIRINGLIVE IN PRODUCTION ACROSS 3 INDUSTRIES
Dear Brightly logodearbrightly.com
Case Study · Telemedicine

Dear Brightly: Telehealth Platform Engineering

A custom NestJS platform for a teledermatology brand. Built modular. Run by one team.

Failing prescription syncs, manual order rescues, a Retool ops patchwork. replaced by a purpose-built platform designed for reliability, operational clarity, and long-term extensibility.

Skincare product styled on a clean studio backdrop, representative imagery for Dear Brightly teledermatology
~72%
Lower infrastructure cost
60,000+
Users migrated, with full history
1 codebase
In place of two
1 admin
In place of three
ScopeArchitecture · Backend · Admin Dashboard · Integrations · Data Migration · DevOps
01Client

A licensed teledermatology brand

Dear Brightly offers prescription-strength skincare through online consultation. Patients submit a structured skin profile, are evaluated by board-certified dermatologists, and receive ongoing care through a built-in provider chat experience.

Recognition: 2024 Beauty Innovation Award · NYT · Well+Good · The Cut · TechCrunch

02The challenge

The team was firefighting its own platform.

Telemedicine consultation, clinical workflows that depend on system reliability
Prescription sync was unreliable.
The external prescribing integration frequently required manual intervention from operations teams.
Routine operations required engineering support.
Refunds, reorders, replacements, and account-level fixes were routed through fragmented internal tools.
Two stacks held the business together.
Core systems were split across different runtimes and codebases, reflecting different phases of growth rather than a unified architecture.
The cost of fragmentation was paid daily.
Multiple deploy pipelines, inconsistent data models, and limited type sharing created operational overhead and slowed iteration.
Scaling operations was increasingly difficult.
Growth introduced complexity across subscriptions, clinical workflows, and fulfillment that the system wasn't designed to absorb.
03Strategy

Five decisions that shaped the rebuild.

  1. 01

    One language, one runtime.

    Consolidate backend systems into a single TypeScript-based platform.

  2. 02

    Modular monolith architecture.

    Domain-bounded modules with clear ownership, unified deployment, and transactional consistency.

  3. 03

    Decouple external dependencies.

    Move third-party systems behind isolated, retry-safe background workflows.

  4. 04

    Operational self-service.

    Replace engineering-dependent workflows with internal tools and dashboards.

  5. 05

    Zero-downtime migration.

    Rebuild the system while safely migrating all existing data and users.

04Architectural principles

Build for clarity. Optimize for replaceability.

Modular monolith over microservices

Reduced operational overhead and preserved transactional consistency across business domains. Each module encapsulates its own state and logic. One runtime, one deploy.

Single unified runtime

Eliminated cross-language fragmentation and integration complexity. TypeScript end-to-end with shared schemas between backend and internal tools.

Asynchronous external workflows

Third-party systems live behind isolated, retry-safe background workers so user-facing operations stay fast and resilient under variable load.

Business-aligned domain modeling

Modules map to real operational domains (prescriptions, subscriptions, fulfillment, clinical), not technical layers. The system shape matches how the business actually runs.

Strict integration boundaries

External providers sit behind replaceable interfaces. Edge-case provider behavior stays contained instead of leaking into the rest of the platform.

05Architecture

The stack we shipped on.

LayerStack
BackendNestJS · TypeScript · GraphQL
DataPostgreSQL · Redis · Queue workers · Object storage
PaymentsStripe
ClinicalExternal e-prescribing provider
FulfillmentMultiple shipping and pharmacy partners
Tax · Email · TrackingTax automation · Email delivery · Attribution
InfraDocker · CI/CD pipelines · Cloud infrastructure
06What we built

Eight modules. One runtime.

01

Subscription system

Custom subscription engine. Trial → active → paused → cancelled lifecycle, configurable renewal and retry behavior, pre-renewal notifications, safe state transitions without data loss.

02

Prescription pipeline

Idempotent processing of external prescription events. Order gating on validation, full traceability between prescriptions and fulfilled items, observability across every external interaction.

03

Clinical workflow engine

State-based visit lifecycle. Dynamic questionnaires, provider review and approval workflows, automated patient reminders for incomplete steps, configurable clinical review flags.

04

Fulfillment system

Multi-channel fulfillment with a unified order view. Rule-driven routing per product category, reconciliation of order states across systems.

05

Provider payout system

Marketplace-style compensation for clinical work. Automated payouts on completed visits, licensing-aware eligibility, geographic and regulatory routing of clinical assignments.

06

Promotion engine

Campaign-aware promotions with attribution tracking, differentiated order flows, and clean separation of promotional vs subscription metrics.

07

Admin platform

One internal dashboard replaces three. Refunds, reorders, replacements, subscription management, clinical oversight, promotion configuration. Operations execute without filing an engineering ticket.

08

Migration system

Full-platform migration of 60,000+ users with orders, subscriptions, prescriptions, clinical data, and support history. Idempotent, batch-safe, validated and reconciled across systems.

07Tradeoffs

What we optimized for.

The architecture deliberately optimized for operational simplicity, consistency, and delivery speed over theoretical scalability extremes.

  • Modular monolith over distributed services: less independent deploy flexibility, far less operational surface to babysit.
  • Unified data model: better consistency, demands discipline on module boundaries.
  • GraphQL-based API: accelerates internal development, adds schema governance overhead.
  • Heavy async workflows: improves resilience, raises the bar on observability and retry handling.
  • Strict abstraction of external systems: better replaceability, requires per-provider edge-case handling.
  • Strong typing across systems: fewer runtime bugs, coordination cost during schema evolution.
08Results

Stability today. Headroom for tomorrow.

Skincare product line, DTC Rx commerce that runs reliably under load

Infrastructure

  • ~72% reduction in infrastructure cost
  • Two backend stacks consolidated into a single platform

Reliability

  • External system failures isolated from the user experience
  • Manual operational intervention on prescription + fulfillment dropped sharply
  • Improved observability across critical workflows

Operations

  • Routine workflows moved from engineering-dependent to self-serve
  • Unified operational tooling across clinical, commerce, and support
  • Less fragmentation across teams

Migration

  • 60,000+ users migrated with full historical operational data
  • Safe cutover from legacy systems with validation + reconciliation safeguards

Platform velocity

  • Faster iteration through unified architecture and shared types
  • New features ship as modular extensions, not cross-system rewrites
09Outcome

Fragmented firefighting to unified platform.

The platform evolved from a fragmented system requiring constant operational intervention into a unified architecture designed for resilience, clarity, and extensibility.

Core workflows now operate reliably under load, external dependencies are isolated from user experience, and operational teams execute independently without engineering bottlenecks.

The result is a system that supports both stability today and controlled expansion over time.

Next step

Building something similar?

Systems where commerce, clinical workflows, and operations have to work as one platform, that's what we ship. Start a conversation; we'll tell you honestly whether we're the right fit.