Vital is a secure, microservice-based Healthcare Interoperability Platform built for Hack Nocturne 2.0.
It solves the challenge of fragmented patient data by enabling multiple isolated hospitals to securely share and aggregate medical records.
The platform follows Zero-Trust principles: data is standardized as FHIR bundles, gated by patient consent, encrypted at rest, and every access event is immutably logged on a local Ethereum blockchain.
- Universal Identity Resolution (MPI): Maps siloed local hospital IDs (for example,
LOC-001) into a single global patient UUID. - Consent-Gated Access: A hospital cannot access another hospital’s patient records without explicit consent.
- Encryption at Rest: Sensitive PII is encrypted at rest using Fernet-based encryption.
- Tamper-Proof Auditing: Every read, write, and consent update is hashed with SHA-256 and committed to a local Ethereum blockchain using Hardhat.
- FHIR Standardization: Medical records are normalized and served as HL7 FHIR R4 Bundles.
- Multi-Tenant Dashboard: A React-based SPA allows switching between hospital credentials to simulate cross-hospital workflows.
Healthcare systems still face two major issues:
-
Fragmented Medical Records
Hospitals often store patient data in proprietary formats that do not interoperate. This leads to incomplete medical history, duplicate testing, delayed treatment, and higher operational cost. -
Lack of Transparent Auditability
Patients and institutions usually cannot reliably verify who accessed a record, whether access was consented, or whether logs were altered.
Vital solves both problems by combining FHIR-based interoperability with blockchain-backed audit verification.
The system follows a microservice-based architecture where each service has a clear responsibility and communicates through REST APIs.
[ React Frontend SPA (:3000) ]
|
v
+-----------------------------+
| API Gateway Layer (:8000) |
| (Auth, Routing, Encryption) |
+-----------------------------+
|
+------------+-------------+---------------------------+
| | | |
v v v v
[ FHIR ] [ Consent ] [ Patient Data ] (Shared) [ MPI ] & [ Registry ]
(:8001) (:8002) (:8003/DB) (:9000) (:9001)
| | |
+------------+-------------+
|
(Logs all access events)
v
+-----------------------------+
| Blockchain Audit (:8005) |
| (Computes SHA-256 Hashes) |
+-----------------------------+
|
v
[ Hardhat Ethereum Node (:8545) ]
- Frontend: React 18 SPA with dynamic hospital switching and dashboard views.
- API Gateway (
vital-backend/ Port 8000): Central FastAPI layer that validates headers likeX-Hospital-IDandX-API-Key, routes requests, and handles secure request flow. - FHIR Service (Port 8001): Converts hospital data into HL7 FHIR R4 Bundles and validates resources.
- Consent Service (Port 8002): Stores and validates consent records before any patient data is shared.
- Patient Data Service (Port 8003): Stores patient data and FHIR bundles.
- Blockchain Audit Service (Port 8005): Receives audit events, computes SHA-256 hashes, and writes them to the blockchain.
- MPI Service (Port 9000): Resolves local patient IDs into a single global UUID.
- Hospital Registry (Port 9001): Stores and validates hospital identities and API keys.
- Database & Ledger: PostgreSQL for structured data storage and Hardhat Ethereum node for immutable audit hashing.
- Docker & Docker Compose
- Node.js (v18+)
- Python 3.10+
cd services/blockchain-audit-service
npm install
./start.shKeep this terminal running.
From the project root:
docker-compose up --buildWait until the frontend and backend services are fully up.
In a new terminal:
python3 integration_test.py
python3 demo_seed.pyThis populates demo patients, consents, and audit logs through real API calls.
http://localhost:3000
- Every inter-service request is authenticated using hospital-level headers.
- Consent is checked before any patient record is shared.
- Sensitive data is encrypted at rest.
- Only audit hashes are stored on-chain, not raw patient data.
- Both successful and denied access attempts are logged for auditability.
- Production-grade deployment and infra hardening
- Public blockchain or testnet integration
- Patient-facing consent portal
- Role-based access control at clinician or department level
- Real EHR/FHIR server integration
Built with ❤️ at Hack Nocturne 2.0

