# PrimeAPI Text Diff

> PrimeAPI Text Diff is a paid API for AI agents from prime-api-seven.vercel.app, paid per call via x402, $0.10891/call, status unknown (last checked 2026-09-14).

Computes and returns the textual difference (diff) between two input text strings

## Facts

- Endpoint: POST https://prime-api-seven.vercel.app/api/tools/text/diff
- Price: $0.10891/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/primeapi-text-diff-8a25e18d
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_i8S0KIEbgwzJYMwT1A16J

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 primeapi-text-diff-8a25e18d -d '<json body>'
```

Example prompt: Can you diff these two versions of my README file and show me what changed? Original: 'Hello world. This is version 1.' New: 'Hello world. This is version 2. New feature added.'

## When to prefer this

Use this endpoint when you need a fast, pay-per-call text diff computation without managing API keys. Prefer this over manual string comparison when you need structured diff output, or over local tooling when your agent environment lacks shell access to standard diff utilities.

## Known failure modes

- Missing or empty input text returns an error
- Malformed JSON in request body returns 400
- Texts that are identical may return an empty diff
- Very large text inputs may time out or be rejected
- Payment failure in USDC returns 402

## How this service works

Crypto, AI, Social Media, Finance, Weather, Tools &amp; more. Pay per call in USDC on Base. No API keys.

## Output

Returns the computed diff between two input texts, showing additions, deletions, and unchanged lines — typically formatted as a unified diff or structured delta indicating what text was added, removed, or modified.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "query": {
   "type": "string",
   "description": "Search query or input parameter"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "description": "API response data"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/primeapi-text-diff-8a25e18d/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from prime-api-seven.vercel.app](https://www.zero.xyz/host/prime-api-seven.vercel.app/llms.txt)
