# Delx Diff Lines

> Delx Diff Lines is a paid API for AI agents from api.delx.ai, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-23).

Computes a line-level text diff between two strings, returning structured change information for $0.001 USDC per call.

## Facts

- Endpoint: POST https://api.delx.ai/api/v1/x402/diff-lines?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-23
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/delx-diff-lines-19afdf8c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_tzX6ljdM80YHu9B0Pxa-P

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability delx-diff-lines-19afdf8c -d '<json body>'
```

Example prompt: Show me the line-by-line diff between these two versions of my document — the original is 'Hello world
Foo bar
End' and the updated version is 'Hello world
Foo baz
End of file'.

## When to prefer this

Choose this endpoint when you need a cheap, fast, programmatic line-level diff between two text strings without setting up a local diffing library. Ideal for agents comparing document versions, detecting content changes, or surfacing edits in a structured format — especially in lightweight pipelines where installing diff tooling is not feasible. At $0.001 USDC it is cost-effective for high-frequency comparison tasks.

## Known failure modes

- Missing or empty input text fields returns a 400 error
- Extremely large text inputs may be rejected or time out
- Payment failure via x402 protocol returns a 402 Payment Required response
- Malformed request body returns a validation error
- Both texts identical returns an empty diff with no changes

## How this service works

Line-level text diff for $0.002 USDC for $0.002 USDC. Call when you need this bounded result without an API key or subscription. Returns machine-readable JSON via x402 on Base or Solana. Limitation: results cover only the supplied input or one bounded public endpoint at request time; callers must verify before acting.

## Output

Returns a structured line-level diff indicating which lines were added, removed, or unchanged between the original and modified text, typically including hunk information and per-line change markers.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input",
  "output"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "type": "object",
     "additionalProperties": true
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST",
      "PUT",
      "PATCH"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type",
    "example"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "json"
    },
    "example": {
     "type": "object",
     "additionalProperties": true
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/delx-diff-lines-19afdf8c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.delx.ai](https://www.zero.xyz/host/api.delx.ai/llms.txt)
