Healthcare · Mental health
EASE neurofeedback therapy
Real-time EEG data pipeline for clinical therapy sessions
NestJS backend with dual databases (MongoDB + PostgreSQL), MQTT ingestion for live EEG sensor data, and multi-role clinical workflows.
EASE - Neurofeedback Therapy Platform
Domain: Healthcare / Mental Health / Neuroscience Engagement: Client project (backend development, alongside client's in-house team) Team Size: Backend-focused
The Problem
A mental health startup was developing a neurofeedback therapy platform that required processing real-time EEG (electroencephalogram) brain data during therapy sessions. The client had an in-house team handling frontend and product, and brought us on to build the backend. They needed a backend that could:
- Manage complex patient-doctor-admin relationships
- Ingest and process live EEG sensor data via MQTT
- Track therapy sessions with clinical-grade data integrity
- Generate clinical reports and analytics
- Handle multi-role access with healthcare-grade security
- Scale to support multiple clinics and practitioners
Off-the-shelf healthcare platforms couldn't handle the real-time EEG data pipeline or the specialized neurofeedback workflow.
What We Built
We handled the entire backend for the therapy management platform, delivering real-time brain data processing capabilities while the client's in-house team managed frontend and product.
Patient & Doctor Management
- Full patient profiles with medical history
- Doctor profiles with specialization and scheduling
- Patient-doctor assignment and session tracking
- Multi-clinic support with institutional isolation
Therapy Session Engine
- Session creation, scheduling, and lifecycle management
- Real-time EEG data capture during sessions
- Session notes and clinical observations
- Progress tracking across multiple sessions
- Protocol-based therapy workflows
EEG Data Pipeline
- MQTT integration for real-time sensor data ingestion
- EEG signal processing and storage
- Session-linked brain data with temporal indexing
- Data export for clinical analysis
Clinical Reporting
- Automated report generation from session data
- Progress analytics across therapy programs
- Patient outcome tracking
- Exportable clinical summaries
Multi-Role Access Control
| Role | Capabilities |
|---|---|
| Patient | View sessions, reports, progress |
| Doctor | Manage patients, run sessions, write reports |
| Admin | Clinic management, staff oversight |
| Finance | Billing, payment tracking |
Technical Highlights
Architecture
- NestJS with modular, feature-based architecture
- Dual database: MongoDB (Mongoose) for flexible clinical data + PostgreSQL (TypeORM) for relational structures
- Bull queues (Redis-backed) for async processing (emails, reports)
- MQTT protocol for real-time EEG sensor communication
- AWS S3 for secure document and data storage
- AWS SES for transactional emails
- Sentry for error tracking and monitoring
Codebase Scale
- 25,000+ lines of TypeScript
- 150+ source files
- Feature-based module organization
- Comprehensive DTO validation layer
Security & Compliance
- JWT authentication with role-based guards
- Healthcare data isolation between clinics
- Secure file storage on AWS S3
- Audit-ready session and data logs
Tech Stack
| Layer | Technology |
|---|---|
| Backend | NestJS 8, TypeScript 4.3 |
| Primary DB | MongoDB (Mongoose) |
| Secondary DB | PostgreSQL (TypeORM) |
| Queue | Bull (Redis-backed) |
| Real-Time | MQTT for EEG sensor data |
| Storage | AWS S3 |
| AWS SES | |
| Monitoring | Sentry |
| Auth | JWT with refresh tokens |
Outcome
- Production platform managing therapy sessions with real-time EEG data capture
- Dual-database architecture balancing flexibility (MongoDB for clinical data) with integrity (PostgreSQL for relational models)
- MQTT pipeline enabling sub-second EEG data ingestion during live sessions
- Multi-role system supporting the full clinical workflow from scheduling to reporting
Key Takeaway
Working alongside the client's in-house team, we owned the backend entirely -- from the MQTT-based EEG pipeline and dual-database strategy to clinical-grade access controls. This demonstrates our ability to integrate into existing teams and deliver specialized healthcare backend systems that go far beyond standard CRUD applications.
More recent work
Healthcare · Patient management
Multi-stakeholder healthcare platform
A six-app healthcare ecosystem — the product our client took to Shark Tank
Patient app, resident web, staff portal, admin dashboard, shared SDK, and an AI emergency dispatcher — all sharing a single backend with role-isolated access. Built for a healthcare startup that was later featured on Shark Tank with the product we delivered.
Read the case study
Transportation · Smart city
TransitPal
Multi-modal routing and cashless ticketing for public transit
Proprietary IP we built and productised — launched on the App Store and Play Store. 150+ APIs, dynamic fare engine, real-time vehicle tracking, ONDC-certified, and a voice AI for 250+ metro stations.
Read the case study
Have a project like this?
Tell us what you're trying to build. Discovery calls this week, scope within 3 business days.