mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-22 17:42:18 -05:00
[GH-ISSUE #24872] issue: Azure OpenAI provider fails on custom URLs (verify error, no chat response) #123729
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @sergey-zinchenko on GitHub (May 18, 2026).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/24872
Check Existing Issues
Installation Method
Docker
Open WebUI Version
v0.9.5
Ollama Version (if applicable)
No response
Operating System
Windows
Browser (if applicable)
No response
Confirmation
README.md.Expected Behavior
When adding a new Azure OpenAI connection whose base URL uses a custom domain (not
*.openai.azure.comor*.cognitive.microsoft.com— e.g. enterprise gateway, APIM, DIAL), and filling in endpoint URL, API key, API version, and deployment names as for a normal Azure setup:Actual Behavior
When adding a new Azure OpenAI connection with a non-standard domain (custom hostname without
azure./cognitive.microsoft.com), using the same fields (URL, API key, API version, deployment names):Steps to Reproduce
https://<your-gateway-host>(base URL only; no deployment path)Hello.Example:
URL
https://llms.mycompany.com· API version2025-01-01-preview· Model IDqwen3-vl-235b-a22b-instructLogs & Screenshots
docker-logs.txt
Additional Information
This flow is meant to cover Azure OpenAI on custom base URLs without relying on hostname auto-detection — the same scenario as #17121 (accept custom URL for Azure OpenAI): gateways such as Azure APIM, or private endpoints whose host does not contain
azure.orcognitive.microsoft.com.The product already exposes that via the Azure OpenAI entry in the connection Provider dropdown (
AddConnectionModal.svelte), plus Azure-only fields (API version, deployment Model IDs,api-keyon the backend). So the Provider → Azure OpenAI path is the intended manual “this is Azure” switch described in #17121 — not a missing feature, but a broken wiring between UI and backend.How Azure mode is decided today
UI (
AddConnectionModal.svelte): reactiveazureis true when:provider === 'azure', orazure./cognitive.microsoft.comand Provider is Default (empty).On save / verify, the config was built as:
So if the user picks Azure OpenAI, only
provider: "azure"is stored —azure: trueis omitted.If the user leaves Provider Default but the URL matches
azure.*, onlyazure: trueis stored (noproviderfield).Backend (
routers/openai.py): routing usesapi_config.get('azure', False)only (before fix), for example:GET {url}/openai/models?api-version=...+api-keyPOST {url}/openai/deployments/{model}/chat/completions?api-version=...+api-keyThe bug
provider: "azure",api_version,model_idsazure: false*.openai.azure.comazure: true*.openai.azure.comprovider: "azure"only (noazure: true)azure: falseSo the regression is: the Provider control and the
azureflag are out of sync — the form shows Azure settings, but the proxy does not enable Azure URL/auth unless the hostname triggers auto-detection.Why users see “Network error” and no chat reply
{url}/modelsinstead of{url}/openai/models→ connection check fails → UI toast (Network error).Relation to other issues
/openai/v1+ Entra ID).@owui-terminator[bot] commented on GitHub (May 18, 2026):
🔍 Related Issues Found
I found some existing issues that might be related. Please check if any of these are duplicates or contain helpful solutions:
🟣 #17121 feat: accept custom url for Azure Open AI
This is the direct precursor feature request for manually supporting Azure OpenAI with custom base URLs / APIM gateways. The new issue appears to be the broken implementation of that requested behavior in the Azure OpenAI provider path.
by fugabri97
🟣 #18075 issue: Azure OpenAI URL not working
This issue reports Azure OpenAI URL handling failures and verify/model lookup errors when the base URL/version formatting is off. It is closely related to the same Azure connection wiring and custom URL/API-version behavior.
by attilaolah ·
bug🟣 #24190 issue: Azure OpenAI - Open WebUI: Server Connection Error
This bug involves Azure OpenAI connections in Open WebUI returning a server connection error after the model is used. While the symptoms differ, it is another Azure OpenAI provider failure path and may share the same request-routing/authentication handling.
by burkhat ·
bug🟣 #24761 Issue #24761
Although this one focuses on Azure AI Foundry and Entra ID, it is the most recent open Azure OpenAI-related issue and covers Azure endpoint/auth plumbing in the same router area. It may overlap if the custom URL flow is also hitting the newer Azure OpenAI endpoint logic.
by unknown
💡 If your issue is a duplicate, please close it and add any additional details to the existing issue instead.
This comment was generated automatically. React with 👍 if helpful, 👎 if not.
@sergey-zinchenko commented on GitHub (May 20, 2026):
Addressed in dev