This repository was archived by the owner on May 21, 2026. It is now read-only.
File tree Expand file tree Collapse file tree
packages/mcp-use/src/server Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -112,14 +112,7 @@ export class McpServer {
112112 inputSchema ,
113113 async ( params : any ) => {
114114 const result = await definition . fn ( params )
115- return {
116- content : [
117- {
118- type : 'text' ,
119- text : result ,
120- } ,
121- ] ,
122- }
115+ return result
123116 } ,
124117 )
125118 return this
Original file line number Diff line number Diff line change 1- // Removed unused import
2- import type { UIResource } from '@mcp-ui/server'
1+ import type { CallToolResult } from '@modelcontextprotocol/sdk/types.js'
32export interface ServerConfig {
43 name : string
54 version : string
@@ -46,5 +45,5 @@ export interface PromptDefinition {
4645
4746export type ResourceHandler = ( ) => Promise < string >
4847export type TemplateHandler = ( params : Record < string , string > ) => Promise < string >
49- export type ToolHandler = ( params : Record < string , any > ) => Promise < string | UIResource >
48+ export type ToolHandler = ( params : Record < string , any > ) => Promise < CallToolResult >
5049export type PromptHandler = ( params : Record < string , any > ) => Promise < string >
You can’t perform that action at this time.
0 commit comments