-
Notifications
You must be signed in to change notification settings - Fork 598
🐛 mcp-chat: Azure OpenAI Models Not Working #8387
Copy link
Copy link
Open
Labels
Description
Workspace
mcp-chat
📜 Description
However, when making requests against an Azure OpenAI deployment, the plugin fails with:
mcp-chat error [openai] Request failed (404) after 180ms responseData="{\"error\":{\"code\":\"404\",\"message\": \"Resource not found\"}}"
Root cause:
My Azure OpenAI /chat/completions endpoint requires a mandatory api-version query parameter. Currently, the plugin always calls:
without any way to include api-version, which causes the 404 error.
Proposed solution:
Allow specifying query parameters when calling the /chat/completions endpoint. For example:
mcpChat:
providers:
- id: openai
baseUrl: 'https://xxx.openai.azure.com/openai/deployments/yyy/'
chatCompletionsQueryParameter: 'api-version=2024-10-21'
token: 'zzz'
model: gpt-4o-miniAlternatively, if we only want to pass api-version:
mcpChat:
providers:
- id: openai
baseUrl: 'https://xxx.openai.azure.com/openai/deployments/yyy/'
apiVersion: '2024-10-21'
token: 'zzz'
model: gpt-4o-miniThis would make the plugin compatible with older Azure OpenAI deployments.
👍 Expected behavior
I would expect Azure OpenAI to work when using the plugin
👎 Actual Behavior with Screenshots
mcp-chat error [openai] Request failed (404) after 180ms responseData="{\"error\":{\"code\":\"404\",\"message\": \"Resource not found\"}}"
👟 Reproduction steps
- Configure the plugin with:
mcpChat:
providers:
- id: openai
baseUrl: 'https://xxx.openai.azure.com/openai/deployments/yyy/'
token: 'zzz'
model: gpt-4o-mini- Send a message in the chat
📃 Provide the context for the Bug.
No response
👀 Have you spent some time to check if this bug has been raised before?
- I checked and didn't find similar issue
🏢 Have you read the Code of Conduct?
- I have read the Code of Conduct
Are you willing to submit PR?
Yes I am willing to submit a PR!
Reactions are currently unavailable