unstale

npm / @ai-sdk/gateway

@ai-sdk/gateway

What changed in @ai-sdk/gateway 2 to 7, from its official release notes, upgrade guides and advisories. Sources checked 2026-11-30.

62 breaking25 deprecations85 new APIs and options1 performance27 behavior and defaults2 tooling20 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli on npm

@ai-sdk/gateway 784 changes

Breaking changes 47

  • OpenTelemetry span collection moved out of ai; install this package and register an OpenTelemetry instance globally to receive traces.

    7.0.0upgrade guide

  • Top-level generateText and streamText result content now accumulates across all steps; use finalStep.content for final-step-only values.

    7.0.0upgrade guide

  • Renames the tool callback's experimental_context to context, now scoped and typed from the tool's contextSchema.

    7.0.0upgrade guide

  • All packages are ESM-only; consumers using require() must switch to ESM import syntax.

    4.0.0, 7.0.0release notesupgrade guide

  • This deprecated option is removed; replace remaining usages with activeTools in generateText and streamText calls.

    7.0.0upgrade guide

  • The deprecated export was removed; use customProvider instead.

    7.0.0upgrade guide

  • The deprecated export was removed; use generateImage instead.

    7.0.0upgrade guide

  • The deprecated type export was removed; use GenerateImageResult instead.

    7.0.0upgrade guide

  • The deprecated option and generateText result property were removed; use output for call options and result access.

    7.0.0upgrade guide

  • The deprecated option was removed; use prepareStep instead.

    7.0.0upgrade guide

  • Removes the tracer property; pass a custom OpenTelemetry Tracer to the OpenTelemetry constructor instead.

    7.0.0upgrade guide

  • Top-level generated-file results now accumulate across all steps; use finalStep.files for final-step-only values.

    7.0.0upgrade guide

  • Request bodies are no longer included in generateText and streamText step results by default; opt in with include.requestBody.

    7.0.0upgrade guide

  • generateText no longer includes response bodies by default; opt in with include.responseBody.

    7.0.0upgrade guide

  • The tool-loop stop condition helper is renamed from stepCountIs to isStepCount.

    7.0.0upgrade guide

  • This deprecated function is removed; use isToolUIPart instead.

    7.0.0upgrade guide

  • Removes the deprecated top-level cachedInputTokens field; use inputTokenDetails.cacheReadTokens instead.

    7.0.0upgrade guide

  • Removes the deprecated top-level reasoningTokens field; use outputTokenDetails.reasoningTokens instead.

    7.0.0upgrade guide

  • The redirect option for HTTP and SSE transports now defaults to 'error', rejecting redirects by default to help prevent SSRF; set it to 'follow' if redirects are needed.

    7.0.0upgrade guide

  • The deprecated { type: 'media' } tool-result content part is removed; use a file part for inline tool-result file content.

    7.0.0upgrade guide

  • Raises the minimum supported Node.js version to 22; supported versions are 22, 24, and 26.

    4.0.0, 7.0.0release notesupgrade guide

  • Renames the telemetry integration callback and tracing-channel event type from onEmbedFinish to onEmbedEnd.

    7.0.0upgrade guide

  • Renames the per-call completion callback for embed and embedMany from experimental_onFinish to onEnd.

    7.0.0upgrade guide

  • Renames the per-call completion callback for rerank from experimental_onFinish to onEnd.

    7.0.0upgrade guide

  • The onEnd callback follows the updated multi-step result shape: usage and listed collections cover all steps, while final-step-only properties are available on finalStep.

    7.0.0upgrade guide

  • Renames the telemetry integration callback and tracing-channel event type from onRerankFinish to onRerankEnd.

    7.0.0upgrade guide

  • The generation start callback is renamed from experimental_onStart to onStart for generateText, streamText, and agents.

    7.0.0upgrade guide

  • Renames the per-step lifecycle callback from onStepFinish to onStepEnd across text and object generation, agents, workflow agents, and UI message stream helpers.

    7.0.0upgrade guide

  • The per-step start callback is renamed from experimental_onStepStart to onStepStart for generateText, streamText, and agents.

    7.0.0upgrade guide

  • Instructions returned by prepareStep now carry forward to future steps until overridden, rather than applying only to the current step.

    7.0.0upgrade guide

  • Messages returned by prepareStep now form the base for subsequent steps, combined with the previous step's response messages.

    7.0.0upgrade guide

  • The cacheCreationInputTokens field was removed from generateText and streamText responses; use usage.inputTokenDetails.cacheWriteTokens and cacheReadTokens for cache token counts.

    7.0.0upgrade guide

  • When reasoning is enabled with a value other than 'none', reasoning summaries now default to 'detailed'. Set this option to null to keep them disabled.

    7.0.0upgrade guide

  • Register a telemetry integration globally at application startup to enable telemetry collection.

    7.0.0upgrade guide

  • Use runtimeContext for shared generation or agent state visible to prepareStep, events, and step results; shared top-level context usage moves to this name.

    7.0.0upgrade guide

  • Top-level sources now accumulate across all steps; use finalStep.sources for final-step-only values.

    7.0.0upgrade guide

  • Each step's response.messages now contains only messages produced by that step; use result.responseMessages for the full response message history.

    7.0.0upgrade guide

  • Moves the deprecated top-level includeRawChunks option into the include object as rawChunks.

    7.0.0upgrade guide

  • onChunk now receives every TextStreamPart, including lifecycle, boundary, and terminal parts; handlers should guard the chunk types they process.

    7.0.0upgrade guide

  • System messages in prompt or messages fields are rejected by default; move instructions to the top-level instructions option or opt in with allowSystemInMessages: true.

    7.0.0upgrade guide

  • This deprecated type is removed; replace imports and references with ToolExecutionOptions.

    7.0.0upgrade guide

  • Top-level tool-call results now accumulate across all steps; use finalStep.toolCalls for final-step-only values.

    7.0.0upgrade guide

  • Top-level tool-result results now accumulate across all steps; use finalStep.toolResults for final-step-only values.

    7.0.0upgrade guide

  • Pass tool-specific context values keyed by tool name, separating them from shared generation or agent state.

    7.0.0upgrade guide

  • generateText and streamText result usage now totals token usage across all steps; use finalStep.usage for final-step-only usage.

    7.0.0upgrade guide

  • Top-level warnings now accumulate across all steps; use finalStep.warnings for final-step-only values.

    7.0.0upgrade guide

  • xai(modelId) and xai.languageModel(modelId) now use the xAI Responses API by default; use xai.chat(modelId) to keep using Chat Completions.

    7.0.0upgrade guide

Deprecations 21

  • CallSettings is split into LanguageModelCallOptions and RequestOptions; replace usages with LanguageModelCallOptions & Omit<RequestOptions, 'timeout'>. The deprecated type remains available in v7.

    7.0.0upgrade guide

  • The @ai-sdk/vue Chat class is deprecated in favor of the reactive useChat composable.

    7.0.0upgrade guide

  • Google provider types, classes, and functions containing GoogleGenerativeAI were renamed to use Google; old names remain available as deprecated aliases.

    7.0.0upgrade guide

  • Use the canonical tool-result content part with mediaType and tagged data to replace image-* and legacy file-* variants; runtime auto-migration keeps existing outputs working.

    7.0.0upgrade guide

  • The user-message { type: 'image' } part is deprecated; use a file part with image mediaType instead.

    7.0.0upgrade guide

  • The tool() and dynamicTool() property is deprecated; move approval logic to toolApproval on the call or agent.

    7.0.0upgrade guide

  • Renames the final lifecycle callback from onFinish to onEnd for generateText, streamText, agents, and ToolLoopAgent settings; onFinish remains a deprecated alias, and onEnd takes precedence.

    7.0.0upgrade guide

  • Renames experimental_onToolCallFinish for generateText and streamText; the old name remains a deprecated fallback.

    7.0.0upgrade guide

  • Renames experimental_onToolCallStart for generateText and streamText; the old name remains a deprecated fallback.

    7.0.0upgrade guide

  • The streamText result method is deprecated; use the stateless top-level helper to pipe a text stream to a Node.js response.

    7.0.0upgrade guide

  • The streamText result method is deprecated; use the stateless top-level helper to pipe a UI message stream to a Node.js response.

    7.0.0upgrade guide

  • The top-level final-step provider metadata result property is deprecated; use finalStep.providerMetadata.

    7.0.0upgrade guide

  • The top-level final-step reasoning result property is deprecated; use finalStep.reasoning.

    7.0.0upgrade guide

  • The top-level final-step reasoning text result property is deprecated; use finalStep.reasoningText.

    7.0.0upgrade guide

  • The top-level final-step request result property is deprecated; use finalStep.request.

    7.0.0upgrade guide

  • The top-level final-step response result property is deprecated; use finalStep.response.

    7.0.0upgrade guide

  • Renames the full event stream property from fullStream to stream; fullStream remains available as a deprecated alias.

    7.0.0upgrade guide

  • This result property is deprecated; use usage for total token usage across all steps.

    7.0.0upgrade guide

  • The streamText result method is deprecated; use top-level stateless text-stream helpers to create the response.

    7.0.0upgrade guide

  • The streamText result method is deprecated; use the stateless top-level helper, which can transform any stream.

    7.0.0upgrade guide

  • The streamText result method is deprecated; compose top-level stateless helpers to create the UI message stream response.

    7.0.0upgrade guide

New APIs and options 7

  • Declare tool-specific context fields with contextSchema so tool callbacks receive typed context scoped to that tool.

    7.0.0upgrade guide

  • The top-level system prompt option is renamed from system to instructions across functions accepting prompt or messages; system remains a deprecated fallback, and instructions takes precedence when both are provided.

    7.0.0upgrade guide

  • The callback receives instructions for the current step and initialInstructions for the top-level instruction value.

    7.0.0upgrade guide

  • Use the top-level reasoning option for provider-agnostic reasoning effort and remove overlapping settings from providerOptions, which take precedence if both are present.

    7.0.0upgrade guide

  • Models can return files in reasoning as a distinct content type; update exhaustive part handling and account for these files in content or reasoning rather than generated-file lists.

    7.0.0upgrade guide

  • Move tool approval policy from needsApproval on tool() or dynamicTool() to per-call or agent toolApproval, allowing policy to vary by request.

    7.0.0upgrade guide

  • The Vue composable exposes reactive refs and recreates the underlying chat when its init object changes, so reactive inputs can flow through without manual orchestration.

    7.0.0upgrade guide

Behavior and default changes 8

  • Repair-tool-call options use instructions instead of system for the current system instructions.

    7.0.0upgrade guide

  • The speech generation function graduated from experimental status and is available under the stable name generateSpeech; the old name remains a deprecated alias.

    7.0.0upgrade guide

  • Renames experimental_include to include for generateText, streamText, and ToolLoopAgent; the old name remains a deprecated alias.

    7.0.0upgrade guide

  • The speech result type has a stable name; the old name remains a deprecated alias.

    7.0.0upgrade guide

  • Telemetry is enabled by default for AI SDK calls once an integration is registered; set isEnabled to false per call to opt out.

    7.0.0upgrade guide

  • Renames experimental_telemetry to telemetry; the old name remains a deprecated alias during the migration window.

    7.0.0upgrade guide

  • The transcription API graduated from experimental status and is available under the stable name transcribe; the old name remains a deprecated alias.

    7.0.0upgrade guide

  • The transcription result type has a stable name; the old name remains a deprecated alias.

    7.0.0upgrade guide

Tooling 1

  • Run this command to add the migration skill and guide your agent through migrating from AI SDK 6 to 7.

    7.0.0upgrade guide

@ai-sdk/gateway 497 changes

Breaking changes 10

  • AI Gateway access_policy_denied responses (HTTP 403) now map to this error instead of GatewayInternalServerError; it supports isInstance(error) and exposes policyIds, removedModels, and removedProviders when present.

    2.0.182, 3.0.238, 4.0.147release notesrelease notesrelease notes

  • Corrects the result type and schema to match the gateway response, including renamed fields, nullable values, and optional metadata; update code reading removed fields.

    2.0.172, 3.0.220, 4.0.122release notesrelease notesrelease notes

  • Arrays passed directly as state now contain decision state parts; wrap JSON arrays in an object or a json part.

    4.0.108release notes

  • The API name evaluate was renamed to decide.

    4.0.104release notes

  • Unsupported batch request types are now rejected.

    4.0.79release notes

  • Support for Imagen models and their integration was dropped following the API shutdown.

    4.0.59release notes

  • The baseUrl option has been removed from all providers; use baseURL instead.

    4.0.0upgrade guide

  • Changes file part data to be tagged with a type and removes the image part type.

    4.0.0release notes

  • Mints a single-use, short-lived client secret instead of returning the long-lived Gateway credential; expiresAfterSeconds is forwarded and expiresAt is returned.

    4.0.0release notes

  • Forbidden error responses are now mapped to GatewayForbiddenError instead of GatewayInternalServerError.

    4.0.0release notes

Deprecations 1

New APIs and options 59

  • Adds support for the GPT-6.2 Astra model.

    4.0.148release notes

  • Adds support for the GPT-6.2 Sol model.

    4.0.148release notes

  • Adds the Hydrogen model ID, supports its xhigh thinking level in Google Generate Content and Interactions provider options, and maps portable reasoning: 'xhigh' to xhigh only for Hydrogen models.

    4.0.144release notes

  • Adds support for gemini-4-carbon with the same capabilities as gemini-4-argon.

    2.0.180, 3.0.235, 4.0.142release notesrelease notesrelease notes

  • GatewayRealtimeModel provides a server-side realtime WebSocket URL and Authorization header auth, with optional team scoping for trusted server-side clients.

    4.0.136release notes

  • Opt in to streaming decoding of canonical base64 images of at least 64 KiB. Extracted images are returned as Uint8Array; smaller images stay base64 strings, and mixed results are normalized to bytes.

    4.0.136release notes

  • Adds Search and Fetch tools for DeepSeek.

    3.0.227, 4.0.133release notesrelease notes

  • Tako tool errors now accept the gateway_rate_limit case, which exhaustive error switches may need to handle.

    3.0.227, 4.0.133release notesrelease notes

  • Parallel and Tako tool errors gain an optional retryAfter field.

    3.0.227, 4.0.133release notesrelease notes

  • Parallel and Tako tool errors gain an optional statusText field.

    3.0.227, 4.0.133release notesrelease notes

  • API key and token settings now support promises and synchronous or asynchronous callbacks, resolving credentials per authenticated request while preserving existing authentication behavior and synchronous credential serialization.

    4.0.131release notes

  • Adds support for the GPT-6.1 Terra model.

    3.0.223, 4.0.128release notesrelease notes

  • Added kimi-k3.1-pro support to the Moonshot AI provider.

    2.0.172, 3.0.221, 4.0.125release notesrelease notesrelease notes

  • Added kimi-k3.1-pro-highspeed support to the Moonshot AI provider.

    2.0.172, 3.0.221, 4.0.125release notesrelease notesrelease notes

  • Adds experimental streaming speech through the AI Gateway speech WebSocket, callable like speech(modelId); server-side getToken() mints a short-lived speech-bound client secret for browser use.

    4.0.123release notes

  • Adds Voxtral 3 offline transcription and speech model IDs, transcription context phrases and detected language, updated timestamp validation, and speech expressiveness and pronunciation hints.

    4.0.122release notes

  • Adds fetchPolicy.disableCacheFallback.

    2.0.172, 3.0.220, 4.0.122release notesrelease notesrelease notes

  • Adds fetchPolicy.timeoutSeconds.

    2.0.172, 3.0.220, 4.0.122release notesrelease notesrelease notes

  • Adds the location option.

    2.0.172, 3.0.220, 4.0.122release notesrelease notesrelease notes

  • Adds top-level maxCharsTotal; excerpts.maxCharsTotal is deprecated in favor of it.

    2.0.172, 3.0.220, 4.0.122release notesrelease notesrelease notes

  • Accepts the turbo, fast, basic, and advanced modes; one-shot and agentic remain accepted but are deprecated.

    2.0.172, 3.0.220, 4.0.122release notesrelease notesrelease notes

  • Experimental decision calls accept maxOutputTokens and forward it to language-model-backed decisions; native decision providers warn when it is unsupported.

    4.0.119release notes

  • The MiniMax M3.1 Flash model ID is now available in the MiniMax and AI Gateway providers.

    4.0.119release notes

  • Experimental decision calls accept reasoning and forward it to language-model-backed decisions. Language-model adapters keep reasoning disabled when omitted; native decision providers warn when it is unsupported.

    4.0.119release notes

  • Adds support for the GPT-6.1 Sol model.

    2.0.161, 3.0.206, 4.0.101release notesrelease notesrelease notes

  • GatewayProviderOptions now accepts conditional evaluation fallbacks.

    4.0.96release notes

  • Gemini 3.8 speech model IDs were added to Gateway types.

    4.0.91release notes

  • Adds model IDs for GPT-6 Sol and Luna.

    2.0.156, 3.0.199, 4.0.90release notesrelease notesrelease notes

  • Adds support for cancelling batches with experimental_cancelBatch.

    4.0.88release notes

  • Adds the Grok 4.7 model ID.

    2.0.154, 4.0.88release notesrelease notes

  • The has model filter now supports reasoning.

    4.0.88release notes

  • The has model filter now supports tool-use.

    4.0.88release notes

  • Image generation requests are now supported in batches.

    4.0.79release notes

  • Batch requests can now use per-request models.

    4.0.76release notes

  • Adds support for the gpt-6-astra model in the gateway.

    2.0.147, 3.0.189, 4.0.75release notesrelease notesrelease notes

  • Adds support for Fable 5.1, allowing developers to use it through the Gateway.

    2.0.145, 3.0.187, 4.0.72release notesrelease notesrelease notes

  • Accepts a webhookUrl for batch completion webhooks; the gateway provider registers it through the batch callbackUrl contract.

    4.0.64release notes

  • Adds Tako Search tool support to the gateway provider.

    3.0.180, 4.0.62release notesrelease notes

  • DeepSeek V4 Flash Vision Exp now supports image input.

    2.0.138, 3.0.178, 4.0.60release notesrelease notesrelease notes

  • DeepSeek V4 Flash Vision Exp now supports the Files API.

    4.0.60release notes

  • Adds experimental batch API support through the AI Gateway batch routes, with methods to start text batches and check their status and results.

    4.0.57release notes

  • Adds the disallowPromptTraining Gateway provider option.

    4.0.0release notes

  • Adds support for the Exa search tool through the Gateway provider.

    4.0.0release notes

  • Adds optional Vercel team scoping for Gateway authentication; apiKey accepts AI Gateway API keys, Vercel personal access tokens, and Vercel app access tokens.

    4.0.0release notes

  • Adds a constant for the Gateway realtime subprotocol authentication contract.

    4.0.0release notes

  • Adds bidirectional audio/text realtime sessions routed through the AI Gateway using the normalized AI SDK realtime protocol.

    4.0.0release notes

  • Adds GatewayFailedDependencyError for HTTP 424 responses.

    4.0.0release notes

  • Adds get-generation support to the Gateway provider.

    4.0.0release notes

  • Adds the server-side decoder for the versioned Gateway realtime subprotocol authentication contract.

    4.0.0release notes

  • Adds the client-side encoder for the versioned Gateway realtime subprotocol authentication contract.

    4.0.0release notes

  • Adds the hipaaCompliant Gateway provider option.

    4.0.0release notes

  • Adds sort options for Gateway models.

    4.0.0release notes

  • Adds the quotaEntityId Gateway provider option.

    4.0.0release notes

  • Adds the qwen3.7-max model ID to AI Gateway.

    4.0.0release notes

  • Adds reranking() support for Gateway reranking models.

    4.0.0release notes

  • Adds rerankingModel() and reranking() methods for Gateway reranking model support.

    4.0.0release notes

  • Adds serviceTier values flex and priority to GatewayProviderOptions.

    4.0.0release notes

  • Adds speech and transcription model support to the Gateway provider.

    4.0.0release notes

  • Adds spend reporting support to the Gateway provider.

    4.0.0release notes

Behavior and default changes 11

  • String model ids passed to experimental_extract now resolve through the AI Gateway by default.

    4.0.149release notes

  • Results include optional marketCost, surchargeCost, and gatewayCost fields from the AI Gateway generation lookup API; unavailable fields are omitted.

    4.0.136release notes

  • The gateway adapter warns when shared timestampGranularities requests are not forwarded.

    4.0.136release notes

  • Tako tool errors now accept the unknown case, which exhaustive error switches may need to handle.

    3.0.227, 4.0.133release notesrelease notes

  • Now accepts Parallel Search results.

    2.0.172, 3.0.220, 4.0.122release notesrelease notesrelease notes

  • The gateway sends image files in decision state.

    4.0.110release notes

  • Decision refusals are reported as refusal answers.

    4.0.106release notes

  • Conditional evaluation fallback models with any non-empty value are now accepted.

    4.0.96release notes

  • The has provider option now supports quantization conditions.

    4.0.91release notes

  • The video model now implements handleWebhookOption, so generateVideo({ webhook }) registers the factory URL as callbackUrl and awaits delivery instead of falling back to polling.

    4.0.60release notes

  • Provider warnings are surfaced in embedding and reranking responses.

    4.0.0release notes

Tooling 1

  • Conditional evaluation fallbacks are now typed in the Gateway provider.

    4.0.95release notes

Fixes and other changes 15

  • Restores this deprecated optional field on takoSearch results so code that reads it compiles again; Tako always sends 0 and will stop sending it.

    4.0.142release notes

  • The headquarters provider option is now typed.

    3.0.232, 4.0.139release notesrelease notes

  • Transcription responses preserve optional normalized word timings.

    4.0.136release notes

  • Image and video models pass through seed: 0 instead of dropping it; KlingAI reports it as an unsupported setting like any other seed.

    4.0.136release notes

  • Video generation and status responses accept explicit uploaded-video outcomes.

    4.0.136release notes

  • Preserves AbortError and TimeoutError cancellation reasons in speech and transcription input streams, propagating them to output streams without leaving reads pending or causing unhandled rejections.

    4.0.130release notes

  • Batch result downloads limit JSONL rows to 64 MB.

    4.0.105release notes

  • getCredits() now forwards the configured team as a query parameter, preventing authentication errors for credentials that can access multiple teams.

    4.0.102release notes

  • getAvailableModels() now includes evaluation models instead of filtering them out as unknown model types.

    4.0.85release notes

  • The gateway provider now forwards server-returned warnings in doGenerate instead of overwriting them with an empty array.

    2.0.151, 3.0.193, 4.0.80release notesrelease notesrelease notes

  • Preserves retryability returned by the AI Gateway for image results.

    4.0.77release notes

  • Transient network errors while reading successful response bodies are now marked retryable, including for AI Gateway responses.

    2.0.144, 3.0.185, 4.0.68release notesrelease notesrelease notes

  • Gateway errors now support retries.

    4.0.0release notes

  • Adds reranking to modelType validation and types so getAvailableModels() accepts Gateway reranking models.

    4.0.0release notes

  • The Gateway model list is resilient to unknown model types.

    4.0.0release notes

@ai-sdk/gateway 332 changes

Breaking changes 5

  • Removes excerpt, which was never populated.

    3.0.220release notes

  • Removes publishDate, which was never populated.

    3.0.220release notes

  • Removes relevanceScore, which was never populated.

    3.0.220release notes

  • Removes searchId, which was never populated.

    3.0.220release notes

  • The package has a major version bump for AI SDK v6.

    3.0.0release notes

Deprecations 3

  • Marks export_pricing.free_rows as deprecated and optional; Tako always sends 0 and will stop sending it.

    3.0.235release notes

  • The agentic mode is deprecated but remains accepted.

    3.0.220release notes

  • The one-shot mode is deprecated but remains accepted.

    3.0.220release notes

New APIs and options 17

  • Adds the gemini-4-hydrogen model ID for Google Generate Content and Interactions.

    3.0.236release notes

  • Adds support for Hydrogen's xhigh thinking level in Google Generate Content and Interactions provider options.

    3.0.236release notes

  • Adds types for premium pricing fields.

    3.0.235release notes

  • Adds a type for relevance_score.

    3.0.235release notes

  • Adds types for Tako placeholder cards.

    3.0.235release notes

  • Adds the developer-only extraBody option to takoSearch.

    3.0.235release notes

  • Adds the developer-only maxVariableCostUsd option to takoSearch.

    3.0.235release notes

  • Adds the developer-only variableCost option to takoSearch.

    3.0.235release notes

  • Adds a type for usage.variable_cost.

    3.0.235release notes

  • Adds a provider option for resuming responses that used up their maxOutputTokens budget.

    3.0.213release notes

  • Adds the gemini-4-argon model id.

    2.0.166, 3.0.213release notesrelease notes

  • Exposes the first request's prompt token count in Google provider metadata.

    2.0.166, 3.0.213release notesrelease notes

  • Adds Browserbase Search and Fetch tool support.

    3.0.202release notes

  • The has provider option now supports quantization conditions.

    2.0.157, 3.0.200release notesrelease notes

  • Model filtering with has now supports reasoning and tool-use.

    2.0.154, 3.0.197release notesrelease notes

  • Added the gemini-3.8-flash model for use with the Google provider.

    2.0.146, 3.0.188release notesrelease notes

  • Adds support for the GLM-5.3-Flash model through the Z.AI provider and AI Gateway.

    3.0.183release notes

Performance 1

  • Validation schema construction is deferred until first use to reduce provider import time.

    3.0.219release notes

Behavior and default changes 4

  • generateText with the Interactions API now polls background model calls until they finish.

    3.0.213release notes

  • Requests that reach the per-request CONTINUATION cap continue automatically, with usage summed across requests.

    3.0.213release notes

  • The has provider option now accepts structured-output.

    2.0.159, 3.0.202release notesrelease notes

  • Retryability classification is provider-independent and preserved through the AI Gateway; Google and Google Vertex content-filtered results are terminal.

    3.0.191release notes

Fixes and other changes 2

  • Cancellation reasons AbortError and TimeoutError are preserved instead of being wrapped in retryable GatewayResponseError errors with status 500.

    2.0.175, 3.0.227release notesrelease notes

  • Unclassified empty image results are retried, and retry-attempt accounting is preserved.

    3.0.191release notes

@ai-sdk/gateway 29 changes

New APIs and options 2

  • Adds meta/muse-ember to the available language model IDs.

    2.0.178release notes

  • Adds a provider option and provider metadata for resuming responses that used up their maxOutputTokens budget.

    2.0.166release notes

Behavior and default changes 4

  • Requests that reach the per-request CONTINUATION cap are continued automatically, with usage summed across requests and the first request's prompt token count exposed.

    2.0.166release notes

  • Thinking can be disabled up to high effort; when disabled, xhigh and max effort are lowered to high with a warning.

    2.0.164release notes

  • Thinking token budgets are unsupported; enabled thinking with budgetTokens is converted to adaptive thinking with a warning.

    2.0.164release notes

  • Adds provider-independent retryability classification and preserves it through the AI Gateway.

    2.0.149release notes

Fixes and other changes 3

  • Diagnostics from completed attempts are preserved, making them available after retries.

    2.0.149release notes

  • Unclassified empty image results are retried, changing how image-generation failures are handled.

    2.0.149release notes

  • Google Vertex RAI-filtered results are marked terminal, so they are not treated as retryable.

    2.0.149release notes