Bug Description
When using openai-responses API with Azure OpenAI (e.g. gpt-5.2-codex-4), multi-turn conversations fail with:
HTTP 400: Item with id 'rs_...\ not found. Items are not persisted when `store` is set to false.
Try again with `store` set to true, or remove this item from your input.
Root Cause
The Responses API returns reasoning output items with an id (e.g. rs_xxx) and encrypted_content: null. On the next turn, OpenClaw includes these reasoning items in the input array. Since the items were not persisted server-side (store: false or Azure default behavior), the API cannot resolve the referenced id and returns 400.
Expected Behavior
OpenClaw should either:
- Strip reasoning items (type
reasoning) with encrypted_content: null from the input when building multi-turn requests
- Or set
store: true explicitly when using the Responses API
- Or provide a model-level config option to control
store behavior
Reproduction
- Configure a provider with
"api": "openai-responses" pointing to Azure OpenAI
- Start a conversation (first turn succeeds)
- Send a second message in the same session → 400 error
Environment
- OpenClaw: 2026.2.19-2
- Provider: Azure OpenAI (
east-us-grandline-prod.openai.azure.com)
- Model:
gpt-5.2-codex-4
- API:
openai-responses
Related
Same issue reported in Vercel AI SDK: vercel/ai#7543
Bug Description
When using
openai-responsesAPI with Azure OpenAI (e.g.gpt-5.2-codex-4), multi-turn conversations fail with:Root Cause
The Responses API returns reasoning output items with an
id(e.g.rs_xxx) andencrypted_content: null. On the next turn, OpenClaw includes these reasoning items in theinputarray. Since the items were not persisted server-side (store: falseor Azure default behavior), the API cannot resolve the referencedidand returns 400.Expected Behavior
OpenClaw should either:
reasoning) withencrypted_content: nullfrom the input when building multi-turn requestsstore: trueexplicitly when using the Responses APIstorebehaviorReproduction
"api": "openai-responses"pointing to Azure OpenAIEnvironment
east-us-grandline-prod.openai.azure.com)gpt-5.2-codex-4openai-responsesRelated
Same issue reported in Vercel AI SDK: vercel/ai#7543