Body:
I’ve encountered a persistent “socket hang up” error when using the MCP server with GPT-5:
- OS/Environment: (Mac OS X Sequoia 15.5, Node.js 24.5, Local)
- Server version: (
@dannyboy2042/gpt5-mcp-server npm / git SHA if built from source)
- OpenAI API: GPT-5 access confirmed, key verified (works fine with direct curl calls)
Steps to Reproduce:
- Register the MCP server in Claude Code using the recommended command, supplying my valid API key.
- MCP server reports successful registration and shows as connected.
- Initiate a search (e.g., text generation or conversation).
- Result:
First tries gpt5_generate → returns:
https://api.openai.com/v1/responses failed, reason: socket hang up
Falls back to gpt5_messages → same error.
I’ve attached a screenshot showing the error dialog (see below).
Additional Info:
- Direct
curl requests to the same endpoint with the same key work perfectly.
- The issue occurs immediately after attempting to use the MCP server—but only with the MCP, not with direct OpenAI API use.
- Confirmed the API key and setup are correct in
.env and config.
- No apparent network/firewall issues (other outbound requests function).
- MCP server confirms “connected” before making the request.
Screenshots:
Troubleshooting already attempted:
- Fresh API key
- Reinstalled/updated server
- Short and simple prompts for testing
Expected behavior:
MCP server should successfully relay the prompt to GPT-5 and return results, as happens when using curl directly.
Actual behavior:
Fails with “socket hang up” after successful connection and upon first use.
Any ideas or similar experiences? Would appreciate debugging and/or guidance.
Body:
I’ve encountered a persistent “socket hang up” error when using the MCP server with GPT-5:
@dannyboy2042/gpt5-mcp-servernpm / git SHA if built from source)Steps to Reproduce:
First tries
gpt5_generate→ returns:gpt5_messages→ same error.I’ve attached a screenshot showing the error dialog (see below).
Additional Info:
curlrequests to the same endpoint with the same key work perfectly..envand config.Screenshots:
Troubleshooting already attempted:
Expected behavior:
MCP server should successfully relay the prompt to GPT-5 and return results, as happens when using
curldirectly.Actual behavior:
Fails with “socket hang up” after successful connection and upon first use.
Any ideas or similar experiences? Would appreciate debugging and/or guidance.