Skip to content

Commit 9853d7b

Browse files
danbarrCopilot
andauthored
Update the default proxy mode for stdio servers (#279)
Signed-off-by: Dan Barr <[email protected]> Co-authored-by: Dan Barr <[email protected]> Co-authored-by: Copilot <[email protected]>
1 parent 4efbbb1 commit 9853d7b

File tree

4 files changed

+39
-36
lines changed

4 files changed

+39
-36
lines changed

docs/toolhive/guides-cli/client-configuration.mdx

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -115,13 +115,13 @@ thv list
115115
Example output (some fields omitted for brevity):
116116

117117
```text
118-
NAME PACKAGE STATUS URL PORT
119-
github ghcr.io/github/github-mcp-server:latest running http://127.0.0.1:55264/sse#github 55264
120-
osv ghcr.io/stackloklabs/osv-mcp/server:latest running http://127.0.0.1:22089/mcp 22089
118+
NAME PACKAGE STATUS URL PORT
119+
github ghcr.io/github/github-mcp-server:latest running http://127.0.0.1:55264/mcp 55264
120+
sqlite ghcr.io/stackloklabs/sqlite-mcp/server:latest running http://127.0.0.1:22089/sse#sqlite 22089
121121
```
122122

123-
In this example, the `github` server uses the SSE transport (URL ends in
124-
`/sse`), and the `osv` server uses Streamable HTTP (URL ends in `/mcp`).
123+
In this example, the `github` server uses the Streamable HTTP transport (URL
124+
ends in `/mcp`), and the `sqlite` server uses SSE (URL ends in `/sse`).
125125

126126
You can also get the list in JSON format, which works with many clients that use
127127
the standard configuration format:
@@ -136,10 +136,10 @@ Example output:
136136
{
137137
"mcpServers": {
138138
"github": {
139-
"url": "http://127.0.0.1:55264/sse#github"
139+
"url": "http://127.0.0.1:55264/mcp"
140140
},
141-
"osv": {
142-
"url": "http://127.0.0.1:22089/mcp"
141+
"sqlite": {
142+
"url": "http://127.0.0.1:22089/sse#sqlite"
143143
}
144144
}
145145
}

docs/toolhive/guides-cli/run-mcp-servers.mdx

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -365,15 +365,12 @@ ToolHive supports the following transport methods:
365365

366366
:::info
367367

368-
We are actively monitoring the adoption of the Streamable HTTP protocol across
369-
the client ecosystem. Once we confirm that ToolHive's supported clients support
370-
Streamable HTTP, we will make it the default proxy transport method for stdio
371-
servers.
372-
373-
Currently, you can add the `--proxy-mode streamable-http` flag to the
374-
[`thv run`](../reference/cli/thv_run.md) command to use Streamable HTTP for
375-
stdio servers. This will ensure that the server is compatible with the latest
376-
MCP specification and can be used with clients that support Streamable HTTP.
368+
As of ToolHive CLI version 0.6.0, the default proxy mode for `stdio` MCP servers
369+
is `streamable-http`.
370+
371+
For backward compatibility with the deprecated SSE transport, you can explicitly
372+
set the transport to `sse` using the `--proxy-mode sse` flag when running the
373+
server.
377374

378375
:::
379376

docs/toolhive/reference/client-compatibility.mdx

Lines changed: 22 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -105,9 +105,9 @@ Example configuration:
105105
```json
106106
{
107107
"servers": {
108-
"github": { "url": "http://localhost:19046/sse#github", "type": "sse" },
108+
"github": { "url": "http://localhost:19046/mcp", "type": "http" },
109109
"fetch": { "url": "http://localhost:43832/mcp", "type": "http" },
110-
"osv": { "url": "http://localhost:51712/mcp", "type": "http" }
110+
"sqlite": { "url": "http://localhost:51712/sse#sqlite", "type": "sse" }
111111
}
112112
}
113113
```
@@ -129,9 +129,9 @@ Example configuration:
129129
```json
130130
{
131131
"mcpServers": {
132-
"github": { "url": "http://localhost:19046/sse#github" },
132+
"github": { "url": "http://localhost:19046/mcp" },
133133
"fetch": { "url": "http://localhost:43832/mcp" },
134-
"osv": { "url": "http://localhost:51712/mcp" }
134+
"sqlite": { "url": "http://localhost:51712/sse#sqlite" }
135135
}
136136
}
137137
```
@@ -157,9 +157,9 @@ Example configuration:
157157
// Other Claude Code settings...
158158

159159
"mcpServers": {
160-
"github": { "url": "http://localhost:19046/sse#github", "type": "sse" },
160+
"github": { "url": "http://localhost:19046/mcp", "type": "http" },
161161
"fetch": { "url": "http://localhost:43832/mcp", "type": "http" },
162-
"osv": { "url": "http://localhost:51712/mcp", "type": "http" }
162+
"sqlite": { "url": "http://localhost:51712/sse#sqlite", "type": "sse" }
163163
}
164164
}
165165
```
@@ -199,9 +199,12 @@ Example configuration:
199199
```json
200200
{
201201
"mcpServers": {
202-
"github": { "url": "http://localhost:19046/sse#github", "type": "sse" },
202+
"github": {
203+
"url": "http://localhost:19046/mcp",
204+
"type": "streamable-http"
205+
},
203206
"fetch": { "url": "http://localhost:43832/mcp", "type": "streamable-http" },
204-
"osv": { "url": "http://localhost:51712/mcp", "type": "streamable-http" }
207+
"sqlite": { "url": "http://localhost:51712/sse#sqlite", "type": "sse" }
205208
// Note: Cline uses "streamableHttp" instead of "streamable-http"
206209
}
207210
}
@@ -226,11 +229,14 @@ Example configuration:
226229
```yaml
227230
mcpServers:
228231
- name: github
229-
type: sse
230-
url: http://localhost:19046/sse#github
232+
type: streamable-http
233+
url: http://localhost:19046/mcp
231234
- name: fetch
232235
type: streamable-http
233236
url: http://localhost:43832/mcp
237+
- name: sqlite
238+
type: sse
239+
url: http://localhost:51712/sse#sqlite
234240
```
235241
236242
Continue supports SSE (`type: sse`) and Streamable HTTP
@@ -254,11 +260,11 @@ For [PydanticAI](https://ai.pydantic.dev/), set the MCP server URL in your code:
254260
from pydantic_ai.mcp import MCPServerSSE
255261
from pydantic_ai.mcp import MCPServerStreamableHTTP
256262
257-
# For Server-Sent Events (SSE)
258-
server = MCPServerSSE(url='http://localhost:43832/sse#github')
259-
260263
# For Streamable HTTP
261-
server = MCPServerStreamableHTTP(url='http://localhost:51712/mcp')
264+
server = MCPServerStreamableHTTP(url='http://localhost:43832/mcp')
265+
266+
# For Server-Sent Events (SSE)
267+
server = MCPServerSSE(url='http://localhost:51712/sse#sqlite')
262268
```
263269

264270
### Example: Copilot for JetBrains IDEs
@@ -271,8 +277,8 @@ to include the MCP server URL:
271277
```json
272278
{
273279
"servers": {
274-
"github": { "url": "http://localhost:43832/sse#github", "type": "sse" },
275-
"fetch": { "url": "http://localhost:51712/mcp", "type": "http" }
280+
"github": { "url": "http://localhost:43832/mcp", "type": "http" },
281+
"sqlite": { "url": "http://localhost:51712/sse#sqlite", "type": "sse" }
276282
}
277283
}
278284
```

docs/toolhive/tutorials/quickstart-cli.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -229,11 +229,11 @@ thv list
229229
You should see output similar to this:
230230

231231
```text
232-
NAME PACKAGE STATUS URL PORT TOOL TYPE CREATED AT
233-
fetch ghcr.io/stackloklabs/gofetch/server:latest running http://127.0.0.1:15266/sse#fetch 15266 mcp 2025-07-10 08:41:56 -0400 EDT
232+
NAME PACKAGE STATUS URL PORT TOOL TYPE CREATED AT
233+
fetch ghcr.io/stackloklabs/gofetch/server:latest running http://127.0.0.1:15266/mcp 15266 mcp 2025-07-10 08:41:56 -0400 EDT
234234
```
235235

236-
This confirms that the fetch server is running and available on port 49226.
236+
This confirms that the fetch server is running and available on port 15266.
237237

238238
:::info[What's happening?]
239239

0 commit comments

Comments
 (0)