JSON Schema validator
json_schema_validateValidate JSON data against a JSON Schema (draft-07/2019-09/2020-12, formats like email/uri/date-time) and get every error with its exact path — check tool I/O before acting on it. Ajv, strict about types, all errors reported. Pass data and schema as JSON values (or JSON strings). Price: free. Errors: returns isError with a message for invalid input or an upstream failure (not charged).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"data": "<data>",
"schema": "<schema>"
},
"name": "json_schema_validate"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | Yes | any JSON value (or a JSON string with parse_strings=true) | |
| schema | Yes | The JSON Schema to validate against. | |
| parse_strings | No | true = if data is a string, parse it as JSON first. Default false. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| valid | No | ||
| errors | No | ||
| error_count | No |