fix(api): add global /api prefix to resolve frontend route mismatch #507
Reference in New Issue
Block a user
Delete Branch "fix/api-global-prefix"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Test plan
🤖 Generated with Claude Code
Frontend API client prefixes all paths with /api/ (e.g. /api/projects, /api/knowledge/entries) but backend controllers had no global prefix, causing 404s on all data-fetching pages in production. - Add setGlobalPrefix('api') in main.ts with exclusions for /health (Docker healthcheck) and /auth/* (BetterAuth OAuth flow) - Strip redundant 'api/' from federation and CSRF controller paths that already included the prefix manually Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>