Text · Diff
Purpose: diff two texts or JSON documents and return the changes. Diff two texts or JSON documents in one deterministic call (no LLM, no network). lines/words mode: Myers diff with a unified diff string, hunks (aStart, aLines, bStart, bLines, lines with op ' '|'+'|'-'), stats {added, removed, unchanged} and similarity 0-1; options context 0-20 (default 3), ignoreWhitespace, ignoreCase. json mode (auto when both inputs are JSON objects/arrays): structural changes as {path (JSON Pointer), op add|remove|replace, from, to}, object key order ignored, arrays compared by index. Max 500 KB per side. F
POST https://newbotlabor--254ecdfcc2de11f19b541607ee4eb77e.web.val.run/api/text/diff
0.002 USDC on Base · payTo 0x174897b2c5B133feB08A8FB90856B08F9fce8647
Status: verified · payable
Settlement: via OMNIGATE (https://omnigate.scriptmasterlabs.com) — seller opted in; receipt token per settlement; 0.005 USDC fee inside settlement, waived inside the daily budget
Payment routes
{
"a": "alpha\nbeta\ngamma\n",
"b": "alpha\nBETA\ngamma\ndelta\n"
}{
"mode": "lines",
"identical": false,
"similarity": 0.5714,
"stats": {
"added": 2,
"removed": 1,
"unchanged": 2
},
"unified": "--- a\n+++ b\n@@ -1,3 +1,4 @@\n alpha\n-beta\n+BETA\n gamma\n+delta\n",
"hunks": [
{
"aStart": 1,
"aLines": 3,
"bStart": 1,
"bLines": 4,
"lines": [
{
"op": " ",
"text": "alpha"
},
{
"op": "-",
"text": "beta"
},
{
"op": "+",
"text": "BETA"
},
{
"op": " ",
"text": "gamma"
},
{
"op": "+",
"text": "delta"
}
]
}
]
}