Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 0a388b6

Browse filesBrowse files
authored
Add example for stateless server with JSON response (#704)
1 parent a00b20a commit 0a388b6
Copy full SHA for 0a388b6

File tree

1 file changed

+3
-0
lines changed
Filter options

1 file changed

+3
-0
lines changed

‎README.md

Copy file name to clipboardExpand all lines: README.md
+3Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -402,6 +402,9 @@ mcp = FastMCP("StatefulServer")
402402
# Stateless server (no session persistence)
403403
mcp = FastMCP("StatelessServer", stateless_http=True)
404404

405+
# Stateless server (no session persistence, no sse stream with supported client)
406+
mcp = FastMCP("StatelessServer", stateless_http=True, json_response=True)
407+
405408
# Run server with streamable_http transport
406409
mcp.run(transport="streamable-http")
407410
```

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.