CoWork API
A multi-tenant REST API for booking coworking rooms, built to hold its rules under concurrent requests.
- Year
- 2026
- Role
- Team Binary DIU
- Context
- ICT Fest hackathon preliminary
- Type
- Backend
- Stack
- Python, FastAPI, SQLAlchemy, SQLite, JWT, Docker
cowork-api/stack.json{"name": "CoWork API","built_with": ["Python","FastAPI","SQLAlchemy","SQLite","JWT","Docker"]}
A hackathon brief with strict business rules, where every rule had to hold even when requests arrive at the same time.
- No double-booking: overlapping confirmed bookings for a room are rejected, back-to-back ones are allowed.
- A quota of three bookings per member in any 24 hours, and a rate limit of 20 booking requests per minute.
- Cancellation refunds of 100%, 50% or 0% depending on notice, with exactly one refund record per booking.
- JWT access tokens that last 15 minutes, single-use refresh tokens, and logout that revokes the token immediately.
- Strict multi-tenancy: data from another organisation behaves as if it doesn't exist.
Runs in one Docker container with the schema created on first start.
Next project
DataForge →