MCP handshake fails with JetBrains idea server: Unexpected content type "missing-content-type"
What version of Codex CLI is running?
0.114.0
What subscription do you have?
pro
Which model were you using?
gpt-5.3-codex
What platform is your computer?
Darwin 25.3.0 arm64 arm
What terminal emulator and version are you using (if applicable)?
Warp
What issue are you seeing?
Description
When attempting to connect to a JetBrains IDE MCP server (IntelliJ IDEA) via Streamable HTTP transport, the MCP client fails during the initialization handshake with a content type error.
Error Message
<img width="991" height="394" alt="Image" src="https://github.com/user-attachments/assets/dc5c29db-4621-47ff-b324-9bb9cfc57462" />
What steps can reproduce the bug?
Steps to Reproduce
Start JetBrains IDE MCP server enabled
Configure Codex CLI to connect to http://localhost:64342/sse
Run codex and observe the handshake failure
modify config is ~/.codex/config.toml
[mcp_servers.idea]
enabled = true
url = "http://127.0.0.1:64342/sse"
What is the expected behavior?
Expected Behavior
Successful MCP handshake and initialization with the JetBrains idea server.
Actual Behavior
Handshake fails because the server responds with Content-Type: missing-content-type (or empty/malformed content type) to the initialize request.
Additional information
_No response_
13 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
@small-thanks Has this issue been resolved? I'm encountering the same problem when using IDEA MCP.
@AlchemyDing
you need update JetBrains idea 2026.1+ and use
[mcp_servers.idea]
url = "http://127.0.0.1:64342/stream"
我是这么使用的,但是我用了clashx 并且开启了tun模式(否则使用不了codex)。我的codex根本识别不到idea的mcp
你用的官方还是中转?我的就是这样配置一下,tun模式开不开都行,你的报错是什么?可以贴出来吗?
<img width="1644" height="1362" alt="Image" src="https://github.com/user-attachments/assets/796a94b0-cf17-445d-9741-5a87db2e305d" />
<img width="3330" height="848" alt="Image" src="https://github.com/user-attachments/assets/848d42b8-69fc-42be-b3a7-226a2c43de0c" />
<img width="1528" height="1228" alt="Image" src="https://github.com/user-attachments/assets/2ccdaa98-d3a6-4b31-8d1c-328cd55391ac" />
试试这样呢
<img width="1007" height="563" alt="Image" src="https://github.com/user-attachments/assets/e5412ffd-6c08-4663-81aa-3577a5378915" />
我的就是直接配置的config.toml
JetBrains idea 2026+版本好像才支持的这个版本,你看一下你的idea版本
https://youtrack.jetbrains.com/issue/LLM-26126/I-encountered-a-problem-where-MCP-was-not-working.
<img width="2652" height="1006" alt="Image" src="https://github.com/user-attachments/assets/757d8257-dbcb-4fc0-a1e3-1b2a003d1c43" />
<img width="880" height="1400" alt="Image" src="https://github.com/user-attachments/assets/41954e55-d050-4e5f-abc9-d2c82d76da2c" />
你在看一下toml配置文件的下方有没有 /sse协议的配置,我之前用cc switch 的时候,cc switch老默认给我添加sse的,
如果下面没有被默认添加,确认一下端口,
如果端口也确认,那你看一下是否有其他的配置文件覆盖了
如果以上方案都没有问题,我目前对问题爱莫能助了
我怀疑是我clashx的问题,虽然我已经关掉了tun模式。太麻烦你了,谢谢
不客气,希望你在别人遇到困的时候也能保持赤子之心 [笑脸][笑脸]