API Backend
The Logbook API is a TypeScript backend built with Express 5 and TSOA for type-safe API development with automatic OpenAPI documentation.
Tech Stack
- Framework: Express 5 with TSOA
- Database: TypeORM (PostgreSQL) with Redis caching
- Graph Database: Neo4j via
neo4j-driver - Authentication: JWT + API keys
- Dependency Injection: typescript-ioc
- Email: SendGrid
- Payments: Stripe
- Queues: AWS SQS
Key Features
- Automatic OpenAPI/Swagger generation from TypeScript
- Comprehensive security guards (account, permission, subscription)
- Repository pattern with automatic cache invalidation
- CypherBuilder for type-safe Neo4j queries
Quick Commands
bash
pnpm dev # Start dev server with hot reload
pnpm test # Run tests (vitest)
pnpm build # Build for production
pnpm check:fix # Lint and format with Biome
pnpm generate:openapi # Regenerate TSOA routes after controller changesDatabase Commands
bash
pnpm db:migrate # Run pending migrations
pnpm db:generate # Generate migration from entity changes
pnpm db:revert # Revert last migration
pnpm db:schema:sync # Sync schema directly (dev only)Next Steps
- Getting Started - Set up your development environment
- Architecture - Understand the codebase structure
- Controllers - Learn the TSOA controller pattern