data_diff
Compare two configuration files in JSON, YAML, or TOML formats and get structured differences with statistics and a human-readable summary. Supports cross-format comparison.
Instructions
Compare two configuration files and return structured differences.
Performs a deep comparison of two configuration files (JSON, YAML, TOML) and returns a structured diff with statistics and a human-readable summary. Supports cross-format comparison (e.g. JSON vs YAML).
Output contract: Returns DiffResponse with has_differences, differences dict, statistics, and summary. Side effects: None (read-only). Failure modes: ToolError if files not found or formats disabled.
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": {
"file_path1": "<file_path1>",
"file_path2": "<file_path2>"
},
"name": "data_diff"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_path1 | Yes | Path to first file (base) | |
| file_path2 | Yes | Path to second file (comparison) | |
| ignore_order | No | Ignore list/array ordering in comparison |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | No | ||
| file1 | No | ||
| file2 | No | ||
| success | Yes | ||
| summary | No | ||
| statistics | No | ||
| differences | No | ||
| file1_format | No | ||
| file2_format | No | ||
| has_differences | No |