# Machine Shop – Compare Text

> Machine Shop – Compare Text is a paid API for AI agents from api.pay-forge.online, paid per call via x402, $0.004/call, status unknown (last checked 2026-10-20).

Computes word counts and similarity score between two text snippets

## Facts

- Endpoint: POST https://api.pay-forge.online/v1/compare-text?utm_source=zero.xyz
- Price: $0.004/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-20
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/machine-shop-compare-text-7185866d
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_tXw95zMElBMKUB2sI1Vr-

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 machine-shop-compare-text-7185866d -d '<json body>'
```

Example prompt: Compare these two paragraphs and tell me how similar they are — here's the original: 'The quick brown fox jumps over the lazy dog.' And here's the revised version: 'A fast brown fox leaped over a sleepy dog.'

## When to prefer this

Choose this endpoint when you need a fast, cheap, numeric similarity score and word counts for two text snippets — ideal for regression checks, document diff summaries, duplication detection, and change quantification. It does not perform live web search, scheduled monitoring, or third-party purchasing, so avoid it for real-time or external data needs.

## Known failure modes

- Combined length of a and b exceeds the 50000-character-per-field limit, resulting in a rejection error
- Either a or b field is missing from the request body
- Input is not valid JSON, causing a parse error
- Payment of 0.004 USDC is not included or fails x402 verification, resulting in a 402 Payment Required response

## How this service works

Turn Apify product scrape results into safe catalog updates with Catalog Update Gate. Find evidence in supplied documents, compare snapshots, extract typed JSON fields, inspect x402 quotes and assess API migrations. Preview inputs, evidence and cost for free. No live web search, scheduled monitoring or third-party purchasing.

## Output

Returns a JSON object containing the word count for text A (words_a), the word count for text B (words_b), and a floating-point similarity score between 0 and 1 indicating how similar the two texts are.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "a": {
   "type": "string",
   "title": "A",
   "maxLength": 50000,
   "description": "First text. The combined length of a and b is limited."
  },
  "b": {
   "type": "string",
   "title": "B",
   "maxLength": 50000,
   "description": "Second text. The combined length of a and b is limited."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "words_a": 3,
  "words_b": 4,
  "similarity": 0.5
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/machine-shop-compare-text-7185866d/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.pay-forge.online](https://www.zero.xyz/host/api.pay-forge.online/llms.txt)
