- Schedule: last column is the Preauth column; "Claim for Column with AI" is now
"Claim/Preauth for Column with AI" — that column's appointments go to PreAuth
(MH, CCA, Tufts SCO, United/DentalHub; other insurances are skipped), the rest
to Claim. Preauthorized appointments (hasPreauth) aren't resubmitted
- PreAuth payloads carry appointmentId; appointment X-rays/attachments are sent
with MH/CCA/UnitedDH/Tufts preauths (shared appendAppointmentFiles helper)
- Patient form: policy holder is searchable from patients in the DB, plus
"Relationship to Policy Holder/Subscriber" (Self, Spouse, Dependent Child,
Other). New Patient columns policyHolderPatientId, policyHolderRelationship;
browser-side schema updated so the fields aren't stripped on save
- ADA form: box 12-14 filled from the linked policy holder's record; box 18
ticks the relationship (Self when the patient is the holder)
- AI notes: a bare "2PA" is an image count, not tooth #2 — restored before CDT
lookup so it maps to D0220 #8 / D0230 #24
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Backend insurance ID check now accepts letters + digits (BCBS IDs have
a letter prefix), matching the frontend schema; create route validates
the normalized body
- Patient.state column (default "MA") with State select on the patient
form; ADA claim form uses the patient's state instead of the office's
- Rebuild stale packages/db compiled .js so the runtime schemas include
new fields (state, office billing NPI fields, Telnyx settings)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Add remainingBenefit and thirdPartyInsurance columns to Patient; extract both
from the MassHealth accumulator/member-detail pages during the eligibility
check and surface them in the eligibility table
- Add an updated-date display and a toggle to suppress the post-check PDF
viewer popup (default off) on the insurance eligibility page
- Rename CMSP-prefixed PDF filenames and UI copy to MH, since CMSP and MH now
share the same worker
- Fold CMSP into MassHealth/MH across patient/claim insurance-type dropdowns
and the chatbot's eligibility routing, since they're the same insurance
- Remove auto-download of saved eligibility PDFs; downloading is now manual
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
- Add floating chat window Hand-off to AI toggle (per-patient) and after-hours AI toggle (global)
- Add LangGraph-powered appointment reminder flow: AI introduces itself, classifies YES/NO, handles confirmation with appointment date/time
- Add multi-step rescheduling flow: ASAP vs next week, tomorrow offer, Mon/Tue/Wed picker, morning/afternoon time slot — automatically updates appointment in DB
- Add new patient / after-hours flow: new vs existing patient, dental insurance check, MassHealth Selenium eligibility check (auto-uses saved member ID + DOB for existing patients), self-pay fallback
- Add AI Chat Settings page (Settings → Advanced) with editable greeting templates and LangGraph flow diagrams for both reminder and new-patient flows
- Add Schedule a New Patient template option in chat window, starts new-patient conversation flow
- Add GET/PUT endpoints for AI handoff, after-hours handoff, and AI chat templates
- Add multilingual support (7 languages) across all AI reply nodes with LLM generation and hardcoded fallbacks
- Add pending reschedule in-memory store and conversation stage tracking across all flows
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Filter patient list by userId so each user sees only their own patients
- Sort patients by updatedAt DESC so recently checked patients appear first
- Add updatedAt field to Patient model (DB migration via raw SQL + db:generate)
- Fix DDMA name extraction: read from detail page "Name:" label, not search
results row text which included appended dates
- Fix PDF capture: use driver.get() instead of click() to avoid race condition
that was saving the search results page instead of the patient detail page
- Strip trailing bare dates from extracted names (e.g. "Rodriguez 04/27/2026")
- Handle "Last, First" comma format and single-word last names in splitName
- Normalize insuranceId consistently in createOrUpdatePatientByInsuranceId
- Fix OTP persistent session: stop clearing LocalStorage/IndexedDB on startup
(these hold the DDMA device trust token that skips OTP on subsequent logins)
- Increase post-navigation wait time for full page render before PDF generation
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>