Welcome to Rego Documentation
Rego is a modern, self-hostable Kanban application built with FastAPI and Next.js. This documentation covers the backend API architecture, implementation details, and usage guidelines.
What is Rego?
Rego is a professional project management tool inspired by Trello, designed for teams that need:
- Real-time collaboration - See changes instantly across all connected clients
- Flexible workflows - Organize work with boards, columns, cards, and checklists
- Powerful automation - Create rules to automate repetitive tasks
- Self-hosted control - Deploy on your own infrastructure
- Modern architecture - Built with cutting-edge async Python and React
Project Structure
Backend
- Framework: FastAPI (Python 3.11+)
- Database: PostgreSQL with SQLAlchemy ORM
- Real-time: WebSockets with Redis pub/sub
- Authentication: JWT tokens with fastapi-users
- API Style: RESTful with comprehensive validation
Frontend
- Framework: Next.js 14 with React
- Styling: Tailwind CSS
- State Management: React Query
- Real-time: WebSocket client
- Type Safety: TypeScript
Infrastructure
- Deployment: Docker Compose
- Database: PostgreSQL 14+
- Cache: Redis 6+
- Reverse Proxy: Nginx (production)
Documentation Sections
API Documentation
Get familiar with the backend API:
- Quickstart Guide - Get up and running in minutes
- API Overview - High-level architecture and key features
- Core Components - Database, events, services, and middleware
- Authentication - JWT auth, permissions, and security
- Real-time Events - WebSocket connections and pub/sub
- Data Models - Database schema and relationships
- Domain Services - Business logic by domain
- API Reference - Complete endpoint listing
Specifications
- Requirements Specification - Project requirements and goals
Quick Links
- GitHub Repository: RegoFlow/Rego
- API Documentation (Interactive):
http://localhost:8000/docs - Health Check:
http://localhost:8000/health
Getting Started
Docker Compose (Recommended)
# Clone the repository
git clone https://github.com/RegoFlow/Rego.git
cd Rego
# Create environment file
cp .env.example .env
# Start all services
docker compose up -d
# Run migrations
docker compose exec backend alembic upgrade head
# Access the API
curl http://localhost:8000/health
Manual Setup
# Backend
cd backend/rego
uv sync
alembic upgrade head
uvicorn rego.main:app --reload
# Frontend
cd web
npm install
npm run dev
For detailed setup instructions, see the Quickstart Guide.
Key Features
Real-time Collaboration
Every change is instantly broadcast to all connected clients via WebSockets. See who's viewing each board and watch updates happen live.
Board Management
Create unlimited boards with custom columns, labels, and members. Each board has role-based access control (owner vs member).
Rich Cards
Cards support markdown descriptions, due dates, labels, assignees, checklists, and file attachments.
Automation Rules
Define trigger-action rules to automate workflows: - When card moves to column X → assign to user Y - When label Z is added → move to column W
Powerful API
RESTful API with comprehensive validation, rate limiting, and detailed error messages. Interactive documentation at /docs.
Security First
- JWT token authentication with HTTP-only cookies
- Rate limiting per user/IP
- Environment-specific security validation
- CORS protection
- Audit trails for all changes
Architecture Highlights
- Async/Await: Full async support for maximum performance
- Event-Driven: Redis pub/sub enables horizontal scaling
- Type-Safe: Pydantic models throughout for validation
- Domain-Driven: Clean separation of business logic
- Battle-Tested: Built with production-ready libraries
Contributing
We welcome contributions! Please check out our GitHub repository for:
- Issue tracking
- Pull request guidelines
- Development setup
- Code style guide
License
See the repository for license information.
Support
- Documentation: You're reading it!
- Issues: GitHub Issues
- Discussions: GitHub Discussions
Ready to dive in? Start with the Quickstart Guide or explore the API Overview.