Skip to main content

validate_tool_input

Function validate_tool_input 

Source
pub fn validate_tool_input(
    name: &str,
    input: &Value,
    tools: &[ToolDefinition],
) -> Result<(), String>
Expand description

Validate tool input against the tool’s JSON Schema. Returns Ok(()) if valid, or Err with a human-readable error message.

Matches TypeScript’s Zod schema validation with structured error messages.