@ai-sdk/openai
4.0.108 · 3 Nov 2026Apache-2.022M / weekRepositoryHomepagenpmAtom feed
523 stable releases, newest first, by release line. Notes are quoted as the maintainers published them.
- 3.x
3.0.38 – 3.0.403 releases with no change for you2 dependency updates, 1 maintenance@ai-sdk/provider-utils 4.0.18Show each
- 3.0.405 Mar 2026@ai-sdk/provider-utils 4.0.18
- 3.0.392 Mar 2026@ai-sdk/provider-utils 4.0.17
- 3.0.382 Mar 2026docs, tests or tooling
3.0.37
28 Feb 2026provider/openai: Support custom tools with alias mapping
Patch Changes
provider/openai: Support custom tools with alias mapping
3.0.36
26 Feb 2026openai: Allow null/undefined type in streaming tool call deltas
Azure AI Foundry and Mistral deployed on Azure omit the
typefield in
streaming tool_calls deltas. The chat stream parser now accepts a missingtypefield (treating it as"function") instead of throwingInvalidResponseDataError: Expected 'function' type.Fixes #12770
3.0.35
26 Feb 2026openai: Include reasoning parts without itemId when encrypted_content is present
When
providerOptions.openai.itemIdis absent on a reasoning content part,
the converter now usesencrypted_contentas a fallback instead of silently
skipping the part with a warning. The OpenAI Responses API accepts reasoning
items without anidwhenencrypted_contentis supplied, enabling
multi-turn reasoning even when item IDs are stripped from provider options.Also makes the
idfield optional on theOpenAIResponsesReasoningtype to
reflect that the API does not require it.Fixes #12853
3.0.34
26 Feb 2026Support
phaseparameter on Responses API message items. Thephasefield ('commentary'or'final_answer') is returned by models likegpt-5.3-codexon assistant message output items and must be preserved when sending follow-up requests. The phase value is available inproviderMetadata.openai.phaseon text parts and is automatically included on assistant messages sent back to the API.
3.0.33
24 Feb 2026Added missing model IDs to OpenAIChatModelId, OpenAIResponsesModelId, OpenAIImageModelId, OpenAISpeechModelId, OpenAITranscriptionModelId, and OpenAICompletionModelId types for better autocomplete support.
3.0.32
24 Feb 2026provider/openai: Add
gpt-5.3-codex
3.0.31
23 Feb 2026openai: Change web search tool action to be optional
3.0.30
18 Feb 2026provider/openai: Support native skills and hosted shell
3.0.29
13 Feb 2026Differentiate text vs image input tokens
3.0.28
12 Feb 2026Only updates a dependency:@ai-sdk/provider-utils 4.0.15
3.0.27
11 Feb 2026Normalize provider specific model options type names and ensure they are exported
3.0.20 – 3.0.267 releases with no change for you5 dependency updates, 2 maintenance@ai-sdk/provider 3.0.8@ai-sdk/provider-utils 4.0.14Show each
- 3.0.266 Feb 2026@ai-sdk/provider 3.0.8@ai-sdk/provider-utils 4.0.14
- 3.0.251 Feb 2026@ai-sdk/provider 3.0.7@ai-sdk/provider-utils 4.0.13
- 3.0.2431 Jan 2026@ai-sdk/provider-utils 4.0.12
- 3.0.2329 Jan 2026@ai-sdk/provider-utils 4.0.11@ai-sdk/provider 3.0.6
- 3.0.2229 Jan 2026docs, tests or tooling
- 3.0.2127 Jan 2026docs, tests or tooling
- 3.0.2027 Jan 2026@ai-sdk/provider-utils 4.0.10
3.0.19
26 Jan 2026Provide Responses API providerMetadata types at the message / reasoning level.
3.0.18
22 Jan 2026Only updates dependencies:@ai-sdk/provider 3.0.5@ai-sdk/provider-utils 4.0.9
3.0.17
22 Jan 2026openai: Preserve tool id for apply patch tool
3.0.14
21 Jan 2026openai: Add o4-mini model to OpenAIChatModelId type
3.0.13
20 Jan 2026openai: Filter duplicate items when passing conversationID
3.0.9 – 3.0.124 releases that only update dependencies@ai-sdk/provider 3.0.4@ai-sdk/provider-utils 4.0.8Show each
3.0.8
12 Jan 2026Fix Responses
code_interpreterannotations and add typed providerMetadata
3.0.7
6 Jan 2026openai/azure: Passing response_format correctly
3.0.6
6 Jan 2026Fix handling of
image-urltool result content type in OpenAI Responses API conversion
3.0.4 – 3.0.52 releases that only update dependencies@ai-sdk/provider 3.0.2@ai-sdk/provider-utils 4.0.4Show each
3.0.3
5 Jan 2026azure: Allow 'azure' as a key for providerOptions
3.0.2
30 Dec 2025Trigger release to update
@latest
Patch Changes
Trigger release to update
@latest
3.0.1
23 Dec 2025Add MCP tool approval
Patch Changes
Add MCP tool approval
3.0.0
22 Dec 2025- breaking
Ai SDK 6 beta
provider: Add specificationVersion to ProviderV3
Fix the "incomplete_details" key from nullable to nullish for openai compatibility
Major Changes
- breaking
Ai SDK 6 beta
Patch Changes
provider: Add specificationVersion to ProviderV3
Fix the "incomplete_details" key from nullable to nullish for openai compatibility
provider: Shared spec v3
openai: Additional settings for file search tool
openai: Add the new provider 'apply_patch' tool
fix(openai); fix url_citation schema in chat api
openai: Extract meta data from first chunk that contains any
provider: Speech model v3 spec
provider/openai: Send assistant text and tool call parts as reference ids when store: true
Remove code for unsuported o1-mini and o1-preview models
Support OPENAI_BASE_URL env
Enables image_generation capabilities in the Azure provider through the Responses API.
feat(openai); update spec for mcp approval
provider/openai:
OpenAIChatLanguageModelOptionstypeimport { openai, type OpenAIChatLanguageModelOptions } from '@ai-sdk/openai'; import { generateText } from 'ai'; await generateText({ model: openai.chat('gpt-4o'), prompt: 'Invent a new holiday and describe its traditions.', providerOptions: { openai: { user: 'user-123', } satisfies OpenAIChatLanguageModelOptions, }, });provider/openai: Support conversations api
openai: Add support for 'promptCacheRetention: 24h' for gpt5.1 series
openai: Adding provider mcp tool for openai
provider/openai: Automatically add reasoning.encrypted_content include when store = false
openai: Allow custom names for provider-defined tools
Enables code_interpreter and file_search capabilities in the Azure provider through the Responses API
EmbeddingModelV3provider/openai: Add GPT 5.1 Codex Max to OpenAI Responses model IDs list
Feat (provider/openai): include more image generation response metadata
Tool execution approval
Provider-V3Extended token usage
Add provider version to user-agent header
openai: Add sources in web-search actions
Set the annotations from the Responses API to doStream
provider/openai: Fix web search tool input types
provider/openai: Add gpt-5-codex model id
openai: Fix parameter exclusion logic
LanguageModelV3Add streaming support for apply_patch partial diffs.
Error schema for Responses API
refactoring(provider/openai): simplify code
provider/openai: Add providerExecuted flag to tool start chunks
openai: Preserve file_id when converting file citations
openai: Support openai code-interpreter annotations
Expose usage tokens for 'generateImage' function
openai: Add 'gpt-5.1' modelID
provider/openai: Local shell tool
openai: Treat unknown models as reasoning
Image editing
provider/openai: Only send item references for reasoning when store: true
The built in Code Interpreter tool input code is streamed in
tool-input-<start/delta/end>chunks.provider/openai: Add new model IDs
gpt-image-1-mini,gpt-5-pro,gpt-5-pro-2025-10-06Added support for external_web_access parameter on web_search tool
openai: Add
o3-deep-researchando4-mini-deep-researchmodelsprovider/openai: Preview image generation results
openai: Allow open_page action type url to be nullish
openai: revised_prompt sometimes returns null, causing errors
provider/openai: Add truncation parameter support for Responses API
feat(openai); adding OpenAI's new shell tool
Azure OpenAI enabled web-search-preview
provider/openai: End reasoning parts earlier
Feat (provider/openai): add gpt-image-1.5 model support
openai: Refactor apply-patch tool
Fix openai responses input: process all provider tool outputs (shell/apply_patch) so parallel tool results aren’t dropped and apply_patch outputs are forwarded.
openai: Add gpt-5.2 models
provider: Transcription model v3 spec
ImageModelV3Add 'default' as service tier
Change
isReasoningModeldetection from blocklist to allowlist and add override optionprovider/openai: Support file and image tool results
Flexible tool output content support
Expose raw finish reason
Moved dependency
@ai-sdk/test-serverto devDependenciesAdd GPT-5.2 support for non-reasoning parameters (temperature, topP, logProbs) when reasoningEffort is none.
openai: Allow temperature etc setting when reasoning effort is none for gpt-5.1
openai: Change find action type to find_in_page action type
openai: Add support for sources type 'api'
provider/openai: Add support for OpenAI xhigh reasoning effort
tool-specific strict mode
Distinguish between OpenAI and Azure in Responses API providerMetadata
fix(openai); fix url_citation schema in chat api
- 2.x
2.0.140
3 Nov 2026openai: Preserve valid JSON string tool arguments and serialize BigInt and cycles in tool calls and results, retaining malformed argument replay fallbacks
Forward
languagesandkeywordstranscription hints as repeated multipart fields instead of silently dropping them.
Patch Changes
openai: Preserve valid JSON string tool arguments and serialize BigInt and cycles in tool calls and results, retaining malformed argument replay fallbacks
Forward
languagesandkeywordstranscription hints as repeated multipart fields instead of silently dropping them.
2.0.139
30 Oct 2026Only updates a dependency:@ai-sdk/provider-utils 3.0.43
2.0.138
27 Oct 2026openai: Report unfinished web searches as tool errors
Report failed and incomplete web searches as tool errors instead of successful tool results in OpenAI Responses API calls.
2.0.137
27 Oct 2026Fix
gpt-transcribeREST transcription. Requests with OpenAI provider options now useresponse_format: 'json'forgpt-transcribeand datedgpt-4o-mini-transcribesnapshots, which rejectverbose_json.durationInSecondsis read fromusage.secondswhen a duration-billed response has no top-levelduration.
2.0.136
21 Oct 2026Defer validation schema construction until first use to reduce provider import time.
Patch Changes
Defer validation schema construction until first use to reduce provider import time.
2.0.135
13 Oct 2026openai: Send assistant text and function calls with content instead of an item reference when their reasoning was removed
With reasoning models, pruning reasoning (e.g.
pruneMessages({ reasoning: 'all' })) caused follow-up requests to fail with "Item 'msg*...' of type 'message' was provided without its required 'reasoning' item" or "Item 'fc*...' of type 'function_call' was provided without its required 'reasoning' item". Assistant text and function call parts are now only sent as item references, or with their item id, when they are preceded by reasoning in the same assistant message.
2.0.134
12 Oct 2026openai: Replay web search results, including tools with custom names, when response storage is disabled
2.0.133
30 Sep 2026Only updates a dependency:@ai-sdk/provider-utils 3.0.41
2.0.132
30 Sep 2026openai: Add GPT-6.1 Sol model support