File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -540,14 +540,14 @@ export const createServer = () => {
540540 inputSchema : zodToJsonSchema ( StructuredContentSchema . input ) as ToolInput ,
541541 outputSchema : zodToJsonSchema ( StructuredContentSchema . output ) as ToolOutput ,
542542 } ,
543- {
543+ ] ;
544+ if ( clientCapabilities ! . roots ) tools . push ( {
544545 name : ToolName . LIST_ROOTS ,
545546 description :
546- "Lists the current MCP roots provided by the client. Demonstrates the roots protocol capability even though this server doesn't access files." ,
547+ "Lists the current MCP roots provided by the client. Demonstrates the roots protocol capability even though this server doesn't access files." ,
547548 inputSchema : zodToJsonSchema ( ListRootsSchema ) as ToolInput ,
548- } ,
549- ] ;
550-
549+ } ) ;
550+
551551 return { tools } ;
552552 } ) ;
553553
You can’t perform that action at this time.
0 commit comments