Skip to content

getAllMcpTools

function getAllMcpTools<TContext>(
mcpServersOrOpts,
runContext?,
agent?,
convertSchemasToStrict?): Promise<Tool<TContext>[]>;

Returns all MCP tools from the provided servers, using the function tool conversion. If runContext and agent are provided, callable tool filters will be applied.

Type Parameter Default type

TContext

unknown

Parameter Type Default value

mcpServersOrOpts

| MCPServer[] | GetAllMcpToolsOptions<TContext>

undefined

runContext?

RunContext<TContext>

undefined

agent?

Agent<TContext, any>

undefined

convertSchemasToStrict?

boolean

false

Promise<Tool<TContext>[]>