Repository navigation
Description
Description
Hello,
Thank you for great AI SDK maintenance every time.
I found that Azure OpenAI the new API structure has changed endpoints.
So I wish it will be supported in AI SDK.
Summary
Vercel AI SDK currently uses the legacy Azure OpenAI endpoint format, which prevents users from accessing the latest api-version=preview features. Azure OpenAI has introduced a new v1 API architecture with different endpoint URLs that require AI SDK updates.
Background
Microsoft has significantly changed their Azure OpenAI API strategy starting May 2025. They introduced a new generation of v1 APIs.
References:
- [Azure OpenAI API version lifecycle](https://learn.microsoft.com/en-us/azure/ai-foundry/openai/api-version-lifecycle?tabs=key#api-evolution)
- Preview API (
api-version=preview) documentation - Legacy API (
2025-04-01-previewand earlier) documentation
Compare Endpoints
New v1 API endpoint format (required for latest features):
* Chat Completions: POST {endpoint}/openai/v1/chat/completions?api-version=preview
* Embeddings: POST {endpoint}/openai/v1/embeddings?api-version=preview
* Responses: POST {endpoint}/openai/v1/responses?api-version=preview
Legacy endpoint format (currently used by Vercel AI SDK):
* Chat Completions: POST {endpoint}/openai/deployments/{deployment-id}/chat/completions?api-version=2025-04-01-preview
* Embeddings: POST {endpoint}/openai/deployments/{deployment-id}/embeddings?api-version=2025-04-01-preview
* Responses: POST {endpoint}/openai/responses?api-version=2025-04-01-preview
- Please also confirm that "v1" has been added to the new endpoints.
- And the old Responses API endpoint "v1" is not existing.
Impact
- Users cannot access the latest Azure OpenAI features available in
api-version=preview - Missing support for new Responses API capabilities like:
- input PDF files streamTest on Responses API.
AI SDK Version
ai:5.0.0-beta.21
@ai-sdk/azure:2.0.0-beta.9
@ai-sdk/react:2.0.0-beta.21
Activity
tsuzaki430 commentedon Jul 17, 2025
workaround (Responses API Only)
When I tried Responses API , the baseURL was available instead of the resourceName.
ai:5.0.0-beta.21
@ai-sdk/azure:2.0.0-beta.9
update: Azure OpenAI provider to v1 API format (#7397)
tsuzaki430 commentedon Jul 20, 2025
hello,
Thank you for new azure provider build.
I tried some AI SDK functions and share the result.
V1 Preview API test result.
I'm sorry , I couldn't finish transribe API successfully.
I couldn't find where is the problem in my source or Azure API Infrastructure.
dancer commentedon Jul 22, 2025
will take a look at this soon thank you for the feedback
Kobusvdwalt commentedon Jul 28, 2025
Hi there, I'm using
"@ai-sdk/azure": "^2.0.0-beta.13",Our company has a deployment set up with these URLs
/openai/deployments/gpt-4o/chat/completions
/openai/deployments/gpt-41/chat/completions
...etc
This means that I cannot use the new version as the /v1 is forced now in the azure sdk.
Could we make this optional ? Or allow an override ?
Engaging our internal team to deploy a prefixed set of endpoints seems more daunting, than asking here for a way to override that /v1 endpoint :P
tsuzaki430 commentedon Jul 29, 2025
Hello @Kobusvdwalt
We don't need to re-create deployments for /v1 endpoint.
Existing deployments are available for /v1 endpoint.
Your "gpt-4o" and "gpt-41" deployments no need to changed on Azure OpenAI portal.
The newest Api-version is "preview".
"preview" is for /v1 endpoint ,so you need use the new version, I think you should use /v1 endpoint.
feat(azure): add speech model support and fix transcription (#7624)
dancer commentedon Jul 29, 2025
fix will be released with next patch - let me know if any issues
tsuzaki430 commentedon Jul 30, 2025
@dancer
Thank you for add speech model on azure provider.
I checked speech function works successfully.
But I couldn't see transcribe function success.
V1 Preview API test result.
transcribe function always show me this error.
{"error":{"code":"DeploymentNotFound","message":"The API deployment for this resource does not exist. If you created the deployment within the last 5 minutes, please wait a moment and try again."}}
I checked whisper models many times.
fix(provider/azure): add deployment-based URL support for transcripti…
dancer commentedon Aug 12, 2025
so i merged a fix(will be released soon) sorry for the delayed @tsuzaki430 please take a look at #7985 and try the old format as i believe this is needed let me know if this resolves it and update me, thanks for waiting
tsuzaki430 commentedon Aug 13, 2025
@dancer
Thank you for fix!
I didn't know that transcription API needs deployment-based URL.
"useDeploymentBasedUrls" is good for us and I checked the "DeploymentNotFound" error was ended.
But I met another error , so I close this issue and open the new issue #8013.
lgrammel commentedon Jul 22, 2026
Identify issue type
Identified as Feature
Confidence: High
Rationale
This is primarily a request to add compatibility with Azure OpenAI's new v1 Preview API and its capabilities, making it new provider/API support rather than a documented-behavior failure.
Evidence
/openai/v1preview API endpoint architecture, while the SDK used legacy deployment-based URLs.