Case study

VytalDoc — a clinical platform, from zero to production

Electronic medical records, scheduling with online booking, AI voice dictation, e-signed consents and real-time multi-clinic sync. In beta with real doctors, in production, operated end to end.

Sole developerProduct to productionIn beta with real doctors
Visit vytaldoc.com
VytalDoc clinical dashboard

The problem

Small practices in Latin America still run on paper charts and Excel agendas. The doctor writes the same patient data three times per visit and nothing survives a lost notebook.

US-built EMRs ignore how these practices actually work: prescriptions must print onto each doctor's pre-printed letterhead paper, front desks share one assistant across clinics, and nobody has an IT department.

VytalDoc was built for that reality — from the folio number on a printed prescription to the WhatsApp-first way patients book appointments.

What was built

A full clinical operating system, screenshotted from the live demo clinic:

VytalDoc weekly agenda with appointments and pending online booking requests

Scheduling with online booking

Week and day agendas per doctor, appointment types, and a public booking link patients use without an account — requests land as pending and confirm in one click.

Consultation editor with AI dictation panel and structured vitals form

AI voice dictation into the chart

The doctor records the consultation; AI transcribes it and pre-fills vitals, diagnosis and plan into the structured record — review, correct, sign. Keyboard-first for power users.

Patient chart with visit history and quick actions

Electronic medical records

Full patient chart: clinical info, visit history with issued prescriptions, studies, notes, allergies and quick actions for certificates, consents and lab requests.

Patient-facing consent signing page with clinic branding, on mobile

E-signed informed consents

Template-based consents generated from a visit and signed by the patient on their own phone through a single-use link — or printed and scanned for the paper path.

Public patient questionnaire with white-label clinic branding

Clinical scales by patient link

PHQ-9 and other instruments sent to the patient's device with the clinic's own branding; results score themselves into the chart.

WHO growth curve chart for a pediatric patient

Growth curves & clinical calculators

WHO/CDC pediatric growth charts computed from visit vitals, plus dosing calculators — the tools a pediatrician opens twenty times a day, one click from the chart.

Also in production:

Prescriptions printed on pre-printed paperLab & imaging requestsMedical certificatesPer-user permissionsMulti-clinic with real-time syncAudit logPatient deduplicationLight & dark themeAccent theming per user

Engineering quality

The part clients never see — and the reason the platform can be operated by one person. Every number below is measured from the repository:

1,340+
commits
555
PHP files · 27 domains
1,079
TypeScript files
483
test files (Pest)
41
browser tests
271
internal docs

Tests don't just cover features — architecture tests enforce module boundaries, so the codebase can't quietly rot. This one is real, from the repo:

arch('App\\Scheduling internals are not imported from outside the module')
    ->expect('App\\Scheduling')
    ->classes()
    ->toOnlyBeUsedIn([
        // Allowed entry points only — keep this list small.
        'App\\Scheduling\\Models\\Appointment',
        'App\\Scheduling\\Models\\AppointmentType',
        'App\\Scheduling\\Actions',
        'App\\Scheduling\\Policies\\AppointmentPolicy',
        'App\\Scheduling\\Events',
    ]);
  • CI on GitHub Actions: lint, types, backend and frontend suites on every push
  • 29 Vitest suites on the React side, browser tests for the critical flows
  • i18n with a build-time pipeline; React 19 with the React Compiler; SSR
  • Real-time via WebSockets: bookings, signatures and scale results reach the desk without a refresh
  • 271 internal docs plus the test suite mean nothing is tribal knowledge — one developer built it, but the platform is documented and tested to be transferable

Three hard problems

The kind of work that separates a demo from a production system:

01

Millimeter-accurate printing on pre-printed paper

Every doctor already owns boxes of letterhead prescription paper. Browsers were never meant to print onto a fixed physical layout — margins drift per printer, per driver, per paper size.

A per-clinic calibration flow: sample prints, offset adjustment, and a print pipeline that positions every field to the millimeter from the browser. The doctor keeps their paper; the software adapts.

02

Voice dictation that fills a structured record

Transcribing audio is easy; turning a rambling consultation into discrete, validated fields (blood pressure, diagnosis, plan, prescriptions) without inventing data is not.

A dictation pipeline where AI output lands as a reviewable draft over the structured form — the doctor confirms field by field. Cost per session is tracked and shown to the clinic, no surprises.

03

Real-time across clinics

One assistant runs the front desk of several clinics. If an online booking or a signed consent needs a page refresh to appear, the workflow breaks exactly when the office is busiest.

WebSocket events scoped per clinic: bookings, signatures and scale results appear on the right dashboard the second they happen. The module boundary is enforced by architecture tests.

Stack

LaravelInertiaReact 19TypeScriptTailwind 4PostgreSQLWebSocketsPestPlaywrightAI APIs

Role

Sole developer: product, architecture, code, infrastructure, QA, documentation and operations. VytalDoc is an independent company; Fenix Codex builds and operates the platform.

Need a team of one with this standard?

We take on a small number of build-and-operate engagements — platforms we ship and then run in production.

Get in touch
contact@fenixcodex.com