{"uid":"cap_d1_JyBCEfwhtuEsQbwWhV","slug":"arch-tools-diff-text-c2c9fc57","name":"Arch Tools — diff-text","description":"Arch Tools — diff-text","url":"https://archtools.dev/v1/tools/diff-text","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"mode":{"enum":["unified","words","chars","json"],"type":"string","default":"unified","description":"Diff output format"},"text1":{"type":"string","description":"Original text"},"text2":{"type":"string","description":"Modified text"}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.01","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.01/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_xZAlQuH-WwXJSuZsg_jqM","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.01","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Compares two text strings and returns a diff showing what changed between them, in unified or other formats","exampleAgentPrompt":"Can you diff these two versions of my README file and show me what changed? Here's the original: 'Hello world. This is v1.' and the modified version: 'Hello world. This is v2. Added new features.' Use unified format.","exampleUseCases":[{"title":"Code review change summary","prompt":"I have two versions of a Python function — the original and a refactored version. Can you compare them and show me exactly what lines were added, removed, or changed in unified diff format?"},{"title":"Contract revision detection","prompt":"Here's the original contract clause and the revised version my lawyer sent back. Can you diff them so I can see exactly what wording was changed between the two?"},{"title":"Config file change audit","prompt":"I need to compare my old nginx.conf with the new one deployed to production and get a unified diff showing every line that was added or removed."}],"resultDescription":"A JSON response containing the diff output between the two input texts, showing additions, deletions, and unchanged lines. The format depends on the mode parameter (default: unified diff), similar to standard Unix diff output, indicating which lines were added (+), removed (-), and contextual lines around changes.","failureModes":["Missing required fields (text1 or text2) returns a validation error","Extremely large text inputs may be rejected or time out","Invalid mode value may return an error or fall back to default unified format","Payment failure (insufficient USDC balance) blocks the request","Empty strings for both inputs may return an empty or trivial diff"],"whenToPreferThis":"Choose this endpoint when you need a programmatic, pay-per-use text diff without setting up any infrastructure. Ideal for AI agents that occasionally need to compare text snippets, detect document changes, or summarize edits as part of a larger workflow. Prefer this over git diff or local tools when operating in a serverless or sandboxed environment with no shell access. The $0.01 USDC per-call pricing makes it cost-effective for low-to-moderate volume use cases.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T12:53:56.828Z","isFirstParty":false}