Apply PR review feedback from @ksylvan

- Add changelog file for PR #1965
- Fix trailing space formatting in deploymentRoutes map

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
Baker Tamory
2026-01-25 01:39:18 +11:00
parent 4d5ee38a34
commit a61007b3b1
2 changed files with 15 additions and 7 deletions

View File

@@ -0,0 +1,8 @@
MiniMax unexpected status code: 404 from provider MiniMax, response body: 404 page not found
### PR [#1965](https://github.com/danielmiessler/Fabric/pull/1965) by [infinitelyloopy-bt](https://github.com/infinitelyloopy-bt): fix(azure): Fix deployment URL path for Azure OpenAI API
- Fixed deployment URL path construction for Azure OpenAI API to correctly include deployment names in request URLs
- Added custom middleware to transform API paths and extract deployment names from request body model fields
- Moved StreamOptions configuration to only apply to streaming requests, as Azure rejects stream_options for non-streaming requests
- Added Azure OpenAI troubleshooting documentation with technical details and configuration guidance
- Resolved SDK route matching bug that was preventing proper URL generation for Azure OpenAI endpoints

View File

@@ -79,13 +79,13 @@ func (oi *Client) configure() error {
func azureDeploymentMiddleware(req *http.Request, next option.MiddlewareNext) (*http.Response, error) {
// Routes that need deployment name injection
deploymentRoutes := map[string]bool{
"/chat/completions": true,
"/completions": true,
"/embeddings": true,
"/audio/speech": true,
"/audio/transcriptions": true,
"/audio/translations": true,
"/images/generations": true,
"/chat/completions": true,
"/completions": true,
"/embeddings": true,
"/audio/speech": true,
"/audio/transcriptions": true,
"/audio/translations": true,
"/images/generations": true,
}
path := req.URL.Path