# agent402.tools Content Cleaner

> agent402.tools Content Cleaner is a paid API for AI agents from agent402.tools, paid per call via x402, $0.05/call, status unknown (last checked 2026-09-15).

Cleans and deduplicates text in one pass: redacts PII, removes duplicate lines, and sorts lines, with a single x402 micropayment.

## Facts

- Endpoint: POST https://agent402.tools/api/skill/content-clean
- Price: $0.05/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agent402-tools-content-cleaner-3ff57cde
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_p-HYz2mlyQPUcxLr63IAU

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 agent402-tools-content-cleaner-3ff57cde -d '<json body>'
```

Example prompt: Can you clean up this text for me — redact any personal info, remove duplicate lines, and sort everything: 'John Smith, john@example.com
Jane Doe, jane@example.com
John Smith, john@example.com
Alice, alice@corp.org'?

## When to prefer this

Use this endpoint when you need to perform all three text-cleanup operations — PII redaction, deduplication, and sorting — in a single atomic call rather than chaining three separate tools. It is more cost-efficient (one $0.05 payment) and simpler than orchestrating individual steps. Prefer it for preprocessing raw user-generated content, log files, or scraped data before storage or sharing.

## Known failure modes

- Empty or missing 'text' field returns a 400 validation error
- Extremely large text payloads may time out or exceed size limits
- Payment failure (insufficient USDC balance) causes a 402 response before processing begins
- Partial success: one or more sub-steps (redact, dedupe, sort) may fail while others succeed, with per-step status reported
- Network or upstream service error returns a 5xx response

## How this service works

Bundled execution of the Content cleaner workflow — Clean and deduplicate text — redact PII, remove duplicate lines, and sort in one pass. One x402 payment runs 3 underlying tools (redact, dedupe-lines, sort-lines); partial-success per step.

## Output

Returns the cleaned text after three sequential passes: PII redacted (emails, names, phone numbers, etc. replaced or masked), duplicate lines removed, and lines sorted alphabetically — each step reporting partial success so you know which stages completed.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string",
   "description": "Text to clean"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "args": {
   "text": "line b\\nline a\\nline b\\nemail: test@test.com"
  },
  "pack": "content-clean",
  "steps": [
   {
    "ok": true,
    "slug": "redact",
    "result": {}
   },
   {
    "ok": true,
    "slug": "dedupe-lines",
    "result": {}
   },
   {
    "ok": true,
    "slug": "sort-lines",
    "result": {}
   }
  ],
  "summary": "3/3 steps succeeded"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent402-tools-content-cleaner-3ff57cde/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent402.tools](https://www.zero.xyz/host/agent402.tools/llms.txt)
