Skip to main content

Ghasi-eHealth Mobile App — specification pack

This folder defines implementation guidance for @ghasi/ehr-mobile — the single React Native mobile application that serves every mobile persona on the Ghasi-eHealth platform.

The app is one bundle, one store listing per platform, one codebase, surfacing role-based navigation and feature gating so the same binary serves:

PersonaRole
PatientSelf-care — own appointments, results, messaging, meds
CaregiverProxy care for family or assigned subjects (per consent grant)
GuardianLegal proxy for minors or dependants
CHW / Local health workerCommunity health — household registry, visits, commodity dispensing, offline-heavy field capture

See PERSONAS_AND_ROLES.md for the full persona model, capability matrix, and gating.


Authority and reading order

RuleDetail
Specs vs docsWhen ambiguous, specs/ wins over docs/.
Normative product behaviour (patient workflows)../../modules/patient-portal/ (SPEC, TECHNICAL_REQUIREMENTS, patient-portal-requirements-doc).
Normative product behaviour (CHW workflows)specs/modules/community-health/ (where licensed).
Normative product behaviour (proxy care)specs/modules/consent-service/ + specs/modules/patient-portal/ proxy sections.
Theme, tokens, RTL, motion../../common/THEME.md — canonical source across all surfaces.
Standards alignmentSTANDARDS_ALIGNMENT.md — SMART/PKCE, FHIR/IPS, privacy, WCAG.
TraceabilityTRACEABILITY_MATRIX.md + per-module matrices.
Backend gaps & roadmapBACKEND_GAPS_AND_ROADMAP.md.
Platform cross-cuttingREGIONAL_PROFILE.md, API_PATH_CONVENTIONS.md, COMPLIANCE_SECURITY.md.
Frontend indexdocs/ehr-frontend-specs-index.md.

Start here (scaffolding and delivery):

  1. BUILD_GUIDE.md — monorepo, env, DoD, IAM pointers
  2. IMPLEMENTATION_ROADMAP.md — phased delivery and exit criteria
  3. BACKEND_AND_SERVICE_MAP.md — feature → service → Kong → screen

Deep-dive read order:

  1. ARCHITECTURE_AND_MONOREPO.md
  2. PERSONAS_AND_ROLES.md
  3. AUTH_AND_SESSION.md
  4. API_CLIENT_AND_KONG.md
  5. I18N_AND_RTL.md
  6. UI_UX_PATTERNS.md
  7. SCREENS_AND_NAVIGATION.md
  8. PUSH_AND_DEEP_LINKS.md
  9. OFFLINE_AND_CACHING.md
  10. OBSERVABILITY_AND_PRIVACY.md
  11. TESTING_AND_RELEASE.md

Pattern reference (desktop monorepo): desktop-electron/AI_AGENT_BUILD_GUIDE.md.


Audience

Engineers and AI agents implementing the unified mobile client across patient, caregiver, guardian, and CHW personas. Normative clinical and product requirements remain in each module spec; this pack describes how to build the React Native app against Kong-public APIs and OIDC, share one theme with desktop + web, and surface the correct persona-scoped experience.


Relationship to other surfaces

SurfaceSpec pointer
Single theme / design system../../common/THEME.md — MUI + Tailwind (desktop/web), React Native Paper + NativeWind (mobile), shared tokens, per-tenant overrides, Motion + Reanimated.
Web patient portalapps/patient-portal — Next.js BFF. Same FR/NFR family as patient-portal SPEC; browser uses cookie + server-forwarded tokens.
Shared API types@ghasi/patient-portal-client — mobile and web use the same DTO shapes.
Clinician desktop (ehr-desktop)Different surface class; reuse only Kong base URL and theme tokens (API_PATH_CONVENTIONS.md, ../../common/THEME.md).
Clinician web (future)Same pattern — consumes the same theme tokens.

Architecture overview

Mobile, web, and desktop SHALL share the same authorisation model (SPEC.md §2, TECHNICAL_REQUIREMENTS.md §1) and the same theme pipeline (../../common/THEME.md).


Document index

DocumentPurpose
BUILD_GUIDE.mdMonorepo setup, env, CI, Definition of Done
IMPLEMENTATION_ROADMAP.mdPhases 0–5, exit criteria, backend dependencies
BACKEND_AND_SERVICE_MAP.mdFeature → module → service → Kong → mobile screen
PERSONAS_AND_ROLES.mdPersona model, capability matrix, proxy access, CHW specifics
STANDARDS_ALIGNMENT.mdMobile security / a11y checklist vs international patterns
OBSERVABILITY_AND_PRIVACY.mdTelemetry, crashes, analytics without PHI
ARCHITECTURE_AND_MONOREPO.mdapps/ehr-mobile, Expo vs bare, stack, licensing, persona feature bundles
AUTH_AND_SESSION.mdOIDC + PKCE, secure storage, biometrics, proxy context
API_CLIENT_AND_KONG.md/v1/* routes, errors
I18N_AND_RTL.mdLocales, RTL, calendars, numbers — see also ../../common/THEME.md §10
UI_UX_PATTERNS.mdPer-persona UX patterns, a11y
SCREENS_AND_NAVIGATION.mdTabs, stacks, persona-scoped navigation, licensing gates
PUSH_AND_DEEP_LINKS.mdFCM/APNs, universal links, persona-aware notification routing
OFFLINE_AND_CACHING.mdCache policy per persona (CHW offline-heavy, consumer lightweight)
TESTING_AND_RELEASE.mdTests, store checklist

Application path

Implementation package: apps/ehr-mobile (@ghasi/ehr-mobile, private; aligns with root pnpm-workspace.yaml and Turbo). Normative requirements remain in this specs/ pack plus the relevant module specs (patient-portal, community-health, consent-service).