File tree Expand file tree Collapse file tree 3 files changed +25
-3
lines changed
simple-streamablehttp-stateless/mcp_simple_streamablehttp_stateless
simple-tool/mcp_simple_tool Expand file tree Collapse file tree 3 files changed +25
-3
lines changed Original file line number Diff line number Diff line change @@ -99,6 +99,14 @@ async def list_tools() -> list[types.Tool]:
9999 },
100100 },
101101 },
102+ outputSchema = {
103+ "type" : "array" ,
104+ "items" : {
105+ "type" : "object" ,
106+ "description" : "TextContent with notification information" ,
107+ },
108+ "description" : "List of text content with notification results" ,
109+ },
102110 )
103111 ]
104112
Original file line number Diff line number Diff line change @@ -54,6 +54,17 @@ async def list_tools() -> list[types.Tool]:
5454 }
5555 },
5656 },
57+ outputSchema = {
58+ "type" : "array" ,
59+ "items" : {
60+ "anyOf" : [
61+ {"type" : "object" , "description" : "TextContent" },
62+ {"type" : "object" , "description" : "ImageContent" },
63+ {"type" : "object" , "description" : "EmbeddedResource" },
64+ ]
65+ },
66+ "description" : "List of content from the fetched website" ,
67+ },
5768 )
5869 ]
5970
Original file line number Diff line number Diff line change @@ -38,6 +38,7 @@ async def list_tools():
3838 },
3939 "required" : ["message" ],
4040 },
41+ outputSchema = {"type" : "string" , "description" : "The echoed message" },
4142 annotations = ToolAnnotations (
4243 title = "Echo Tool" ,
4344 readOnlyHint = True ,
@@ -54,9 +55,11 @@ async def list_tools():
5455
5556 # Message handler for client
5657 async def message_handler (
57- message : RequestResponder [ServerRequest , ClientResult ]
58- | ServerNotification
59- | Exception ,
58+ message : (
59+ RequestResponder [ServerRequest , ClientResult ]
60+ | ServerNotification
61+ | Exception
62+ ),
6063 ) -> None :
6164 if isinstance (message , Exception ):
6265 raise message
You can’t perform that action at this time.
0 commit comments