Bug Report
Version: 2026.3.13
Problem
Azure OpenAI requires api-version as a URL query parameter, not an HTTP header. The OpenClaw runtime sends it as a header, which causes Azure to return 404 Resource not found for all requests.
Root Cause
The runtime builds the request URL as:
${baseUrl}/chat/completions
…with api-version passed in the headers object. Azure ignores it there and returns 404.
Verified: all three header variants fail:
api-version: 2024-12-01-preview (header) → 404
x-ms-version: 2024-12-01-preview → 404
openai-version: 2024-12-01-preview → 404
The only working form:
https://<resource>.openai.azure.com/openai/deployments/<model>/chat/completions?api-version=2024-12-01-preview
Note: The onboarding probe correctly injects api-version as a query param (in onboard-custom-*.js), so onboarding succeeds — but the runtime doesn't do the same injection.
Config (openclaw.json)
"azure-gpt53-chat": {
"baseUrl": "https://executive-assistant-resource.openai.azure.com/openai/deployments/gpt-5.3-chat",
"api": "openai-completions",
"headers": {
"api-version": "2024-12-01-preview",
"api-key": "<key>"
}
}
Workaround
None available in current config schema — there is no queryParams field in ModelProviderSchema.
Suggested Fix
Option 1: Detect Azure URLs (hostname ends with .openai.azure.com) and auto-inject api-version header value as a query param at request time.
Option 2: Add a queryParams field to ModelProviderSchema for arbitrary query param injection.
Option 3: Document that users should include ?api-version= in the baseUrl and change the URL construction to handle query strings correctly when appending /chat/completions (e.g. use URL constructor instead of string concat).
Bug Report
Version: 2026.3.13
Problem
Azure OpenAI requires
api-versionas a URL query parameter, not an HTTP header. The OpenClaw runtime sends it as a header, which causes Azure to return404 Resource not foundfor all requests.Root Cause
The runtime builds the request URL as:
…with
api-versionpassed in theheadersobject. Azure ignores it there and returns 404.Verified: all three header variants fail:
api-version: 2024-12-01-preview(header) → 404x-ms-version: 2024-12-01-preview→ 404openai-version: 2024-12-01-preview→ 404The only working form:
Note: The onboarding probe correctly injects
api-versionas a query param (inonboard-custom-*.js), so onboarding succeeds — but the runtime doesn't do the same injection.Config (openclaw.json)
Workaround
None available in current config schema — there is no
queryParamsfield inModelProviderSchema.Suggested Fix
Option 1: Detect Azure URLs (hostname ends with
.openai.azure.com) and auto-injectapi-versionheader value as a query param at request time.Option 2: Add a
queryParamsfield toModelProviderSchemafor arbitrary query param injection.Option 3: Document that users should include
?api-version=in thebaseUrland change the URL construction to handle query strings correctly when appending/chat/completions(e.g. useURLconstructor instead of string concat).