Npub.Health
A decentralized health records platform built on Nostr protocol.
Project Overview
Npub.Health provides a secure, user-controlled platform for managing health data using the Nostr protocol. This application gives individuals ownership over their health information while enabling selective sharing with healthcare providers.
Features
- Secure health record storage using Nostr protocol
- User-controlled data sharing and permissions
- Provider verification system
- Cross-platform support (web, mobile)
- End-to-end encryption for sensitive health data
Tech Stack
- Frontend: React, TypeScript, TailwindCSS
- Backend: Node.js
- Database: SQLite with Drizzle ORM
- Protocol: Nostr
Getting Started
Prerequisites
- Node.js v18 or higher
- npm or yarn
Installation
Clone the repository
git clone https://github.com/HealthNoteLabs/Npub.Health.git cd Npub.HealthInstall dependencies
npm installSet up environment variables
cp .env.example .env # Edit .env with your configurationStart the development server
npm run dev
Project Structure
Npub.Health/
├── client/ # Frontend React application
├── server/ # Backend Node.js server
├── shared/ # Shared utilities and types
├── scripts/ # Utility scripts
└── ...
Development
Running the app in development mode
npm run dev
Building for production
npm run build
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Contact
For any questions or feedback, please open an issue on this repository.
AWS Integration for Blossom Server Deployment
This project includes AWS integration to automatically deploy Blossom servers for users. The implementation allows users to create their own private Blossom servers on AWS EC2 instances.
Setup Steps
Install AWS SDK:
npm install @aws-sdk/client-ec2Create Security Groups: The
scripts/create_aws_security_groups.jsscript will create the necessary security groups in each AWS region:node scripts/create_aws_security_groups.jsMake sure to update the VPC ID in the script for each region.
Configure AWS Credentials: Create a
.envfile with the following variables:AWS_ACCESS_KEY_ID=your_access_key_id AWS_SECRET_ACCESS_KEY=your_secret_access_key # Security Groups for each region (output from the script) SECURITY_GROUP_US_EAST=sg-xxxxxxxxxxxxxxxx SECURITY_GROUP_US_WEST=sg-xxxxxxxxxxxxxxxx SECURITY_GROUP_EU_CENTRAL=sg-xxxxxxxxxxxxxxxx SECURITY_GROUP_AP_SOUTHEAST=sg-xxxxxxxxxxxxxxxx # Database URL DATABASE_URL=postgres://postgres:postgres@localhost:5432/npubhealthSet up PostgreSQL database: Follow these steps to set up the database:
- Install PostgreSQL
- Create a database named
npubhealth - Run migrations to create tables:
npm run db:push
Test the integration:
npm run dev
Architecture
The AWS integration consists of:
- EC2 Manager (
server/aws/ec2Manager.ts): Handles creating and checking EC2 instances. - Server Monitor (
server/aws/serverMonitor.ts): Periodically checks and updates server status. - API Endpoints (
server/routes.ts): Provides REST endpoints for server management. - Database Integration (
server/db): Persists server information and status.
User Flow
- User selects a server tier, region, and name
- System generates a payment address
- User sends payment (simulated in development)
- System deploys an EC2 instance with the Blossom server installation script
- UI polls for server status until it’s running
- User connects to their personal Blossom server
Security Considerations
- The security groups allow HTTP, HTTPS, and the Blossom server port (3000)
- SSH access should be restricted to specific IPs in production
- AWS credentials should have limited permissions following the principle of least privilege
- For production, consider using IAM roles instead of credentials
Troubleshooting
If you encounter issues:
- Check AWS credentials and permissions
- Verify that security groups are properly configured
- Look at server logs for deployment errors
- Check the database for server status information
For more information about the AWS SDK, refer to the official documentation.
Npub.Health
Project Details
- HealthNoteLabs/Npub.Health
- MIT License
- Last Updated: 5/1/2025
Recomended MCP Servers
Model Context Protocol (MCP) server for interacting with Meta Ads API
This is MCP server for Claude that gives it terminal control, file system search and diff file editing...
A First FIWARE Model Context Protocol Server
Rest To Postman Collection MCP Server
MCP Server for the Perplexity API.
MCP server that provides LLM with tools for interacting with EVM networks
An MCP server for Apache Doris & VeloDB
MCP server
本项目是基于dify开源项目实现的dsl工作流脚本合集
Node.js Model Context Protocol (MCP) server providing secure, relative filesystem access for AI agents like Cline/Claude.
🧠 MCP server implementing RAT (Retrieval Augmented Thinking) - combines DeepSeek's reasoning with GPT-4/Claude/Mistral responses, maintaining conversation context...





