Compare two texts by line, word or character. Get structured ops, a unified diff, an escaped HTML redline and a similarity score, or apply a unified patch. Deterministic, stateless, with a REST API and an MCP server.
curl -s https://diffmint.mike-tusa.workers.dev/v1/diff -H 'content-type: application/json' \
-d '{"a":"one\ntwo\n","b":"one\n2\n","formats":["ops","unified"]}'
POST /v1/diff: ops, unified diff (lines mode), HTML redline, statsPOST /v1/patch: apply a unified diffPOST /v1/similarity: 0-1 similarity ratioGET /v1/info: modes and limitsRemote MCP server (Streamable HTTP, no auth needed for the free tier): https://diffmint.mike-tusa.workers.dev/mcp. Tools: diff_text, apply_patch, text_similarity. Also llms.txt and OpenAPI 3.1.
{
"mcpServers": {
"diffmint": {
"type": "http",
"url": "https://diffmint.mike-tusa.workers.dev/mcp"
}
}
}
Deterministic diff (Myers algorithm via jsdiff), not an AI or semantic comparison. Limits per side: lines mode 64 KB and 1,000 lines, words mode 8 KB, chars mode 4 KB. If the texts need more than 250 inserted plus deleted units, the API returns 422 too_different instead of a partial diff. Patches up to 64 KB apply to text up to 64 KB. No 3-way merge, no binary files. Stateless: text is not stored or logged; no URL fetching.