Context
PR #214 introduced the trails database table and admin management endpoints. During this transition period, V1 pack create/update endpoints still accept trail names (strings) and resolve them to trail_id internally.
Scope
Create V2 pack create/update endpoints that accept trail_id (integer) directly instead of trail name strings:
POST /api/v2/mypack - create pack with trail_id field
PUT /api/v2/mypack/:id - update pack with trail_id field
- Admin equivalents under
/api/admin
Additional cleanup (once V2 is stable)
- Remove the legacy
trail TEXT column from the pack table
- Remove dual-write logic from V1 handlers
- Remove V1 trail name resolution code
References
Context
PR #214 introduced the trails database table and admin management endpoints. During this transition period, V1 pack create/update endpoints still accept trail names (strings) and resolve them to
trail_idinternally.Scope
Create V2 pack create/update endpoints that accept
trail_id(integer) directly instead of trail name strings:POST /api/v2/mypack- create pack withtrail_idfieldPUT /api/v2/mypack/:id- update pack withtrail_idfield/api/adminAdditional cleanup (once V2 is stable)
trailTEXT column from thepacktableReferences