Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
There was a problem hiding this comment.
Additional Suggestion:
The JSDoc comment for the baseURL option in GatewayProviderSettings still references the old API version (v1/ai) but the actual default has been updated to v3/ai.
View Details
📝 Patch Details
diff --git a/packages/gateway/src/gateway-provider.ts b/packages/gateway/src/gateway-provider.ts
index ed2cdbb53..ae7e5c4a3 100644
--- a/packages/gateway/src/gateway-provider.ts
+++ b/packages/gateway/src/gateway-provider.ts
@@ -65,7 +65,7 @@ Creates a model for generating images.
export interface GatewayProviderSettings {
/**
-The base URL prefix for API calls. Defaults to `https://ai-gateway.vercel.sh/v1/ai`.
+The base URL prefix for API calls. Defaults to `https://ai-gateway.vercel.sh/v3/ai`.
*/
baseURL?: string;
Analysis
Outdated JSDoc comment for baseURL option in GatewayProviderSettings
What fails: The JSDoc comment for the baseURL option in the GatewayProviderSettings interface documents an outdated default API version (v1/ai) that does not match the actual implementation.
How to reproduce: Open packages/gateway/src/gateway-provider.ts and compare:
- Line 68: JSDoc comment states "Defaults to
https://ai-gateway.vercel.sh/v1/ai" - Line 117: Actual implementation uses
'https://ai-gateway.vercel.sh/v3/ai'
Result: Developers reading the interface JSDoc will see incorrect documentation, believing the default API version is v1 when the actual default is v3.
Expected: JSDoc comment should match the actual implementation, stating "Defaults to https://ai-gateway.vercel.sh/v3/ai"
Evidence: The v3 API is confirmed as the current default in:
- Actual implementation at line 117
- All test expectations (lines 412, 435, 935)
- MDX documentation line 83 explicitly states "The default prefix is
https://ai-gateway.vercel.sh/v3/ai"

Background
AI Gateway is moving to a separate route for AI SDK v6. The embed call options have also changed since v5.
Summary
Updated base url for new route path, and embed params to reflect new call options.
Manual Verification
Ran an embed query manually against local gateway server with new route handlers.
Checklist
pnpm changesetin the project root)