Skip to content

Commit 156410f

Browse files
Shawclaude
andcommitted
fix(cloud/api): make legacy /api/v1/proxy/birdeye redirect public
The legacy birdeye proxy mount returns a 308 redirect to /api/v1/apis/birdeye/* so old clients can discover the new URL. With the path missing from publicPathPrefixes, auth middleware ran first and returned 401 before the redirect could fire, breaking the e2e contract: Group H — GET /api/v1/proxy/birdeye/* > legacy mount redirects to /api/v1/apis/birdeye (308): Expected 308, Received 401 The redirect target /api/v1/apis/birdeye is still auth-gated (the next test in the same group covers that), so making the legacy mount public only exposes the URL rewrite, not the proxy itself. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent ca3bf5c commit 156410f

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

  • cloud/apps/api/src/middleware

cloud/apps/api/src/middleware/auth.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,10 @@ const publicPathPrefixes = [
5858
"/api/agents",
5959
"/api/v1/track",
6060
"/api/v1/discovery",
61+
// Legacy birdeye proxy is a 308 redirect to /api/v1/apis/birdeye/*. The
62+
// redirect itself is public so unauthenticated clients learn the new URL;
63+
// the target /api/v1/apis/birdeye is still auth-gated.
64+
"/api/v1/proxy/birdeye",
6165
"/api/v1/discord/callback",
6266
"/api/v1/twitter/callback",
6367
"/api/v1/oauth/providers",

0 commit comments

Comments
 (0)