Skip to main content

InProcessToolHandler

Type Alias InProcessToolHandler 

Source
pub type InProcessToolHandler = Arc<dyn Fn(&str, Map<String, Value>) -> Result<ClapMcpToolOutput, ClapMcpToolError> + Send + Sync>;
Expand description

Type for in-process tool execution handler.

Called with (command_name, arguments) and returns Result<ClapMcpToolOutput, ClapMcpToolError>. Used when reinvocation_safe is true to avoid spawning subprocesses.

Aliased Typeยง

pub struct InProcessToolHandler { /* private fields */ }