add Tool
fun addTool(name: String, description: String, inputSchema: Tool.Input = Tool.Input(), handler: suspend (CallToolRequest) -> CallToolResult)(source)
Registers a single tool. This tool can then be called by the client.
Parameters
name
The name of the tool.
description
A human-readable description of what the tool does.
input Schema
The expected input schema for the tool.
handler
A suspend function that handles executing the tool when called by the client.
Throws
If the server does not support tools.