@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.
- 2.x
2.0.29
12 Sep 2025provider/openai: Code interpreter tool calls and results
2.0.28
10 Sep 2025Fix (provider/openai): send sources action as include
Fix (provider/openai): fix code interpreter tool in doGenerate
2.0.27
8 Sep 2025Feat (provider/openai): add jsdoc for openai tools
2.0.26
8 Sep 2025Fix (provider/openai): only send tool calls finish reason for tools that are not provider-executed
Feat (provider/openai): add web_search tool
2.0.25
7 Sep 2025Fix timestamp granularities support for openai transcription
2.0.24
4 Sep 2025provider/openai: Safe practice to include filename and fileExtension to avoid
experimental_transcribefails with valid Buffer
Patch Changes
provider/openai: Safe practice to include filename and fileExtension to avoid
experimental_transcribefails with valid Buffer
2.0.23
29 Aug 2025Add serviceTier to provider metadata for OpenAI responses
2.0.22
26 Aug 2025provider/openai: Make file_citation annotation fields optional for responses api compatibility
Patch Changes
provider/openai: Make file_citation annotation fields optional for responses api compatibility
2.0.21
26 Aug 2025provider/openai: Support websearch tool results without query property
provider/openai: Do not set
response_formattoverbose_jsonif model isgpt-4o-transcribeorgpt-4o-mini-transcribeThese two models do not support it:
platform.openai.com/docs/api-reference/audio/cr…
Patch Changes
provider/openai: Support websearch tool results without query property
provider/openai: Do not set
response_formattoverbose_jsonif model isgpt-4o-transcribeorgpt-4o-mini-transcribeThese two models do not support it:
platform.openai.com/docs/api-reference/audio/cr…
2.0.20
25 Aug 2025provider/ai: Do not set
.providerMetadata.openai.logprobsto an array of empty arrays when usingstreamText()
2.0.19
21 Aug 2025Only updates a dependency:@ai-sdk/provider-utils 3.0.5
2.0.18
21 Aug 2025Support Responses API input_file file_url passthrough for PDFs.
This adds:
2.0.17
20 Aug 2025provider/openai: Correct web search tool input
2.0.16
19 Aug 2025Only updates a dependency:@ai-sdk/provider-utils 3.0.4
2.0.15
15 Aug 2025provider/openai: Expose web search queries in responses api
Patch Changes
provider/openai: Expose web search queries in responses api
2.0.14
14 Aug 2025provider/openai: Support file_citation annotations in responses api
2.0.13
14 Aug 2025Implements
logprobsfor OpenAIproviderOptionsandproviderMetaDatainOpenAIResponsesLanguageModelYou can now set
providerOptions.openai.logprobswhen usinggenerateText()and retrieve logprobs from the response viaresult.providerMetadata?.openai
2.0.12
13 Aug 2025provider/openai: Add response_format to be supported by default
provider/openai: Exclude gpt-5-chat from reasoning model
Patch Changes
provider/openai: Add response_format to be supported by default
provider/openai: Exclude gpt-5-chat from reasoning model
2.0.11
12 Aug 2025openai, azure: Add configurable file ID prefixes for Responses API
provider/openai: Add support for prompt_cache_key
provider/openai: Add support for safety_identifier
Patch Changes
openai, azure: Add configurable file ID prefixes for Responses API
Added
fileIdPrefixesoption to OpenAI Responses API configurationAzure OpenAI now supports
assistant-prefixed file IDs (replacing previousfile-prefix support)OpenAI maintains backward compatibility with default
file-prefixFile ID detection is disabled when
fileIdPrefixesis undefined, gracefully falling back to base64 processing
provider/openai: Add support for prompt_cache_key
provider/openai: Add support for safety_identifier
openai: Add missing file_search_call handlers in responses streaming
2.0.10
11 Aug 2025provider/openai: Add code interpreter tool (responses api)
Patch Changes
provider/openai: Add code interpreter tool (responses api)
2.0.9
11 Aug 2025providers: Use convertToBase64 for Uint8Array image parts to produce valid data URLs; keep mediaType normalization and URL passthrough
2.0.8
9 Aug 2025openai: Add verbosity parameter support for chat api
Allow
minimalinreasoningEffortfor openai chat
2.0.7
8 Aug 2025openai: Add flex processing support for gpt-5 models
openai: Add verbosity parameter support for responses api
openai: Add priority processing support for gpt-5 models
2.0.6
8 Aug 2025provider/openai: Models ids on chat
provider/openai: Models ids
Patch Changes
provider/openai: Models ids on chat
provider/openai: Models ids
2.0.5
7 Aug 2025Feat (provider/openai): add reasoning model config
Patch Changes
Feat (provider/openai): add reasoning model config
2.0.4
6 Aug 2025Files from the OpenAI Files API are now supported, mirroring functionality of OpenAI Chat and Responses API, respectively. Also, the AI SDK supports URLs for PDFs in the responses API the same way it did for completions.
2.0.3
5 Aug 2025Only updates a dependency:@ai-sdk/provider-utils 3.0.1
2.0.2
4 Aug 2025openai: Missing url citations from web search tools
2.0.1
4 Aug 2025openai: Add file_search_call support to responses api
2.0.0
31 Jul 2025- breaking
AI SDK 5
- breaking
Chore (provider/openai): switch default to openai responses api
- breaking
Move Image Model Settings into generate options
Image Models no longer have settings. Instead,
maxImagesPerCallcan be passed directly togenerateImage(). All other image settings can be passed toproviderOptions[provider].Before
await generateImage({ model: luma.image('photon-flash-1', { maxImagesPerCall: 5, pollIntervalMillis: 500, }), prompt, n: 10, });After
await generateImage({ model: luma.image('photon-flash-1'), prompt, n: 10, maxImagesPerCall: 5, providerOptions: { luma: { pollIntervalMillis: 5 }, }, });Pull Request: #6180
Major Changes
- breaking
AI SDK 5
- breaking
Chore (provider/openai): switch default to openai responses api
- breaking
Move Image Model Settings into generate options
Image Models no longer have settings. Instead,
maxImagesPerCallcan be passed directly togenerateImage(). All other image settings can be passed toproviderOptions[provider].Before
await generateImage({ model: luma.image('photon-flash-1', { maxImagesPerCall: 5, pollIntervalMillis: 500, }), prompt, n: 10, });After
await generateImage({ model: luma.image('photon-flash-1'), prompt, n: 10, maxImagesPerCall: 5, providerOptions: { luma: { pollIntervalMillis: 5 }, }, });Pull Request: #6180
- breaking
Fix (provider/openai): default strict mode to false
Patch Changes
Feat (provider/openai): o4 updates for responses api
Fix streaming and reconstruction of reasoning summary parts
Add reasoning-part-finish parts for reasoning models in the responses API
Feat (providers/openai): add gpt-image-1 model id to image settings
Adding support for gpt-4o-search-preview and handling unsupported parameters
Add raw chunk support
Feat (providers/openai): add gpt-4.1 models
Chore (providers): remove model shorthand deprecation warnings
Add missing file_search tool support to OpenAI Responses API
Fix (provider/openai): multi-step reasoning with text
openai: Add priority processing service tier support
Feat (providers/openai): add o3 and o4-mini models
Add transcription with experimental_transcribe
embedding-model-v2: Add response body field
provider/openai: Add serviceTier option for flex processing
openai: Add file_search filters and update field names
packages: Export node10 compatible types
Propagate openai transcription fixes
openai: Update file_search fields to match API changes
Feat (providers/openai): add support for reasoning summaries
Refactor (image-model): rename
ImageModelV1toImageModelV2Core (ai): change transcription model mimeType to mediaType
Add speech with experimental_generateSpeech
Fix (provider/openai): correct default for chat model strict mode
Fix (provider/openai): multi-step reasoning with tool calls
Feat (provider/openai): add support for encrypted_reasoning to responses api
Do not warn if empty text is the first part of a reasoning sequence
Fix (provider/openai): push first reasoning chunk in output item added event
provider/openai: Add missing reasoning models to responses API
openai: Add file_search_call.results support to include parameter
Chore (provider/openai): standardize on itemId in provider metadata
Feat (provider): add providerMetadata to ImageModelV2 interface
The
experimental_generateImagemethod from theaipackage now returnes revised prompts for OpenAI's image models.const prompt = 'Santa Claus driving a Cadillac'; const { providerMetadata } = await experimental_generateImage({ model: openai.image('dall-e-3'), prompt, }); const revisedPrompt = providerMetadata.openai.images[0]?.revisedPrompt; console.log({ prompt, revisedPrompt, });provider/openai: Add o3 & o4-mini with developer systemMessageMode
Using Zod 4 for internal stuff
Fix (provider/openai): handle responses api errors
providers/openai: Logprobs for stream alongside completion model
Fix (provider/openai): increase transcription model resilience
Fix (openai): structure output for responses model
Improve Zod compatibility
providers/openai: Zod parse error with function
providers: Always use optional instead of mix of nullish for providerOptions
tool-calling: Don't require the user to have to pass parameters
Fix PDF file parts when passed as a string url or Uint8Array
Feat (providers/openai): support gpt-image-1 image generation
- 1.x
1.3.24
8 Aug 2025Feat (provider/openai): gpt 5 support
1.3.23
7 Jul 2025Fix (provider/openai): handle responses api errors
1.3.22
7 May 2025Only updates a dependency:@ai-sdk/provider-utils 2.2.8
1.3.21
30 Apr 2025providers/openai: Zod parse error with function
1.3.20
25 Apr 2025provider/openai: Add o3 & o4-mini with developer systemMessageMode
1.3.19
25 Apr 2025Feat (providers/openai): add gpt-image-1 model id to image settings
1.3.18
23 Apr 2025Feat (providers/openai): support gpt-image-1 image generation
1.3.17
23 Apr 2025Feat (providers/openai): add support for reasoning summaries
1.3.16
17 Apr 2025Feat (provider/openai): o4 updates for responses api
1.3.15
16 Apr 2025Feat (providers/openai): add o3 and o4-mini models
1.3.14
16 Apr 2025Fix (openai): structure output for responses model
1.3.13
16 Apr 2025Adding support for gpt-4o-search-preview and handling unsupported parameters
1.3.12
14 Apr 2025Feat (providers/openai): add gpt-4.1 models
1.3.11
14 Apr 2025Add speech with experimental_generateSpeech
Patch Changes
Add speech with experimental_generateSpeech
1.3.10
10 Apr 2025Adding support for gpt-4o-search-preview and handling unsupported parameters
Propagate openai transcription fixes
1.3.9
8 Apr 2025Core (ai): change transcription model mimeType to mediaType
Fix (provider/openai): increase transcription model resilience
Patch Changes
Core (ai): change transcription model mimeType to mediaType
Fix (provider/openai): increase transcription model resilience
1.3.8
8 Apr 2025Add transcription with experimental_transcribe
Patch Changes
Add transcription with experimental_transcribe
1.3.6 – 1.3.72 releases that only update dependencies@ai-sdk/provider-utils 2.2.4Show each
- 1.3.74 Apr 2025@ai-sdk/provider-utils 2.2.4
- 1.3.631 Mar 2025@ai-sdk/provider-utils 2.2.3
1.3.5
31 Mar 2025Fix (provider/openai): force web search tool
Patch Changes
Fix (provider/openai): force web search tool