Summary
Add an in-memory todo list CRUD at app/api/routes-f/todos/route.ts and app/api/routes-f/todos/[id]/route.ts. Demonstrates standard REST patterns within the scoped folder.
Requirements
- GET /api/routes-f/todos lists todos, supports ?status=open|done&q= filtering
- POST /api/routes-f/todos body { title, description?, due_date?, priority?: low|med|high } creates
- GET /api/routes-f/todos/[id] reads
- PATCH /api/routes-f/todos/[id] partially updates any field including status
- DELETE /api/routes-f/todos/[id] deletes
- IDs are 6-char nanoid-style strings
- In-memory storage capped at 1000 todos with FIFO eviction
- Tests cover full create-update-delete lifecycle
Scope Constraint - READ BEFORE STARTING
All files for this task must live inside app/api/routes-f/. This includes the route handler, helpers/utilities, types, and tests. Do NOT modify, import from, or add files to lib/, utils/, types/, components/, or anywhere else outside app/api/routes-f/. If you need shared logic, duplicate it inside your subfolder. Keeping everything scoped to this folder is intentional - it keeps these tasks independent and mergeable in any order.
Summary
Add an in-memory todo list CRUD at app/api/routes-f/todos/route.ts and app/api/routes-f/todos/[id]/route.ts. Demonstrates standard REST patterns within the scoped folder.
Requirements
Scope Constraint - READ BEFORE STARTING
All files for this task must live inside app/api/routes-f/. This includes the route handler, helpers/utilities, types, and tests. Do NOT modify, import from, or add files to lib/, utils/, types/, components/, or anywhere else outside app/api/routes-f/. If you need shared logic, duplicate it inside your subfolder. Keeping everything scoped to this folder is intentional - it keeps these tasks independent and mergeable in any order.