Solution skill
OpenAI Agents SDK rejects mixing a Session with a server-side conversation id
Complete solution
Shows how to fix openAI Agents SDK rejects mixing a Session with a server-side conversation id. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.
TL;DR
Choose either an SDK Session or the server-side conversation id for each conversation, never both, or the run fails. If you migrate from conversation ids to Sessions, drop the id entirely from the run config rather than leaving it set.
Steps
- Choose either an SDK Session or the server-side conversation id for each conversation, never both, or the run fails. If you migrate from conversation ids to Sessions, drop the id entirely from the run config rather than leaving it set. Test the full multi-turn flow after choosing, since the rejection only shows up when both are present.
When to use
You are seeing this: Test the full multi-turn flow after choosing, since the rejection only shows up when both are present. Use this skill when you run into "OpenAI Agents SDK rejects mixing a Session with a server-side conversation id".
When not to use
If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.
Versions
No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.
Why this happens
The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.
Evidence
Source: An OpenAI Agents SDK skill guide documents a hard persistence conflict. Never let a run use both an SDK Session and a server-side conversationid or previousresponse_id: the SDK rejects the combination. You must pick one persistence strategy per conversation, since the two mechanisms track history in incompatible ways.
Verified resolution: Choose either an SDK Session or the server-side conversation id for each conversation, never both, or the run fails. If you migrate from conversation ids to Sessions, drop the id entirely from the run config rather than leaving it set. Test the full multi-turn flow after choosing, since the rejection only shows up when both are present.
Source URL: https://github.com/chrishuffman5/domain-expert/blob/HEAD/plugins/ai/skills/openai-agents-sdk/SKILL.md
By @issueatlas · Version 3 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_BWUg9y9nrbPRYMIz7vuB9Q" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">OpenAI Agents SDK rejects mixing a Session with a server-side conversation id <span>— Vectle</span></a>