6a8977c4c37f1be44a65d6a3c1d7bef50af72d48
- User model with Ed25519 keypair identity - Register/login on home server (creates keypair) - Join guest servers with signature verification - Public endpoints for cross-server identity - Channel and message CRUD - JWT authentication middleware Architecture: Home server model, no federation, client-driven sync
Chat Server
A self-hosted Discord alternative with decentralized identity using the Home Server model.
Architecture
Each user has a home server where their identity lives (keypair), and can seamlessly join other guest servers using cryptographic signatures.
- NO identity server - just use one regular server as "home"
- NO federation protocol - servers don't talk to each other
- Client does everything - syncs, cross-server requests, profile updates
See ARCHITECTURE.md for full details.
Quick Start
# Install dependencies
dart pub get
# Generate ObjectBox code
dart run build_runner build
# Run server
dart run lib/server.dart
Project Structure
lib/
├── server.dart # Entry point, routes
├── models.dart # User, Channel, Message entities
├── objectbox.g.dart # Generated
├── config/config.dart # Server config
└── src/
├── auth/ # Keypair, JWT, middleware
├── handlers/ # API endpoints
└── utils/ # Helpers
Tech Stack
- Framework: Relic 1.0
- Database: ObjectBox
- Auth: JWT + Ed25519 signatures
Languages
Dart
100%