feat: add /api/v2/ai-gateway API route aliases - #26475
Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
e82564e to
70af39c
Compare
This comment has been minimized.
This comment has been minimized.
a634eaa to
95125cc
Compare
Docs preview📖 View docs preview for |
7eeb80c to
f4f8875
Compare
f4f8875 to
6c36692
Compare
6c36692 to
20f54ca
Compare
Documentation CheckUpdates Needed
PriorityThe broken link items are now addressed. The remaining URL updates are lower priority since the legacy Automated review via Coder Agents |
pawbana
left a comment
There was a problem hiding this comment.
CLI still uses old path:
Line 185 in 20f54ca
Line 200 in 20f54ca
Line 226 in 20f54ca
~7 usages in:
Line 3130 in 20f54ca
Some tests use old PATH, eg:
coder/enterprise/coderd/aibridge_test.go
Line 1293 in 20f54ca
nit: comment in:
coder/aibridge/provider/provider.go
Lines 26 to 27 in 20f54ca
Paths of UI pages are separate? eg:
Line 705 in 20f54ca
Possible followup, update path in scale tests:
coder/scaletest/bridge/strategy.go
Line 67 in 20f54ca
nit comment:
Line 1117 in 20f54ca
Good catch, For the CLI, tests and other nits, I can update in the context of this PR 👍 |
0591bf3 to
b51d159
Compare
|
@pawbana addressed the CLI, tests and other nits. There are still some other references that will be addressed in focused follow-up PRs. Updated the PR description as well with the changes meant for these follow-ups |
b51d159 to
7863ff7
Compare

Description
Registers
/api/v2/ai-gateway/*as the new API path for AI Gateway, replacing/api/v2/aibridge/*. Both prefixes share the same route builder (aiBridgeRoutes) backed by a single in-memory handler, so existing/aibridgeendpoints continue to work. New endpoints must be registered on the enterprise API handler under/api/v2/ai-gatewayonly.Swagger annotations now point to
/api/v2/ai-gatewaypaths with a backward-compatibility note referencing/aibridge. The legacy/aibridgeroutes are skipped in the swagger documentation test.Changes
aiGatewayHandler) instead of two prefix-stripped handlers/ai-gatewayand/ai-gateway/proxyroute aliases alongside legacy/aibridgeroutes/aibridge/keysto/ai-gateway/keys/api/v2/ai-gatewayprefix@Routerand@Tagsannotations fromaibridge/AI Bridgetoai-gateway/AI GatewayAIGatewayRootPath,AIBridgeRootPath)Note: the following will be addressed in follow-up PRs:
Refs https://linear.app/coder/issue/AIGOV-230