# PII Redactor / Privacy Scrubber

> PII Redactor / Privacy Scrubber is a paid API for AI agents from x402-deployer.x402-deployer.workers.dev, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-12).

Redacts PII (emails, phones, SSNs, IBANs, credit cards, IPs, names, addresses, dates of birth) from text using a two-stage regex + LLM pipeline, returning sanitized text and a list of every redacted entity.

## Facts

- Endpoint: POST https://x402-deployer.x402-deployer.workers.dev/pii-redact?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/x402-deployer-x402-deployer-workers-dev-adb427b6
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_DfBDOBxkzxAlE-5uCEt5o

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 x402-deployer-x402-deployer-workers-dev-adb427b6 -d '<json body>'
```

Example prompt: Can you redact all PII from this text before I store it — 'John Smith called from +1-555-867-5309, his SSN is 123-45-6789 and he paid with card 4111 1111 1111 1111, reach him at john.smith@example.com' — and give me back the clean version plus a list of everything that was masked?

## When to prefer this

Choose this endpoint when you need a robust, two-stage PII redaction pipeline that handles both structurally detectable PII (regex) and contextual PII (names, addresses, DOBs via LLM) in a single call, especially for GDPR-safe text processing, log sanitization, or anonymizing user-generated content before downstream storage or API calls. Prefer this over a pure regex scrubber when residual contextual PII (full names, street addresses) must also be caught.

## Known failure modes

- Empty or missing input text returns an error
- Extremely long texts may hit processing limits or increase latency
- LLM stage may occasionally miss highly ambiguous or culturally atypical PII
- Non-English names or addresses may have lower recall from the LLM stage
- Payment failure (insufficient USDC balance) results in 402 response before processing

## How this service works

PII redactor / mask emails phones SSNs IBANs credit cards IPs / GDPR safe text / privacy scrubber. Two-stage redaction: a deterministic regex pre-pass for structural PII (email, phone, credit card, SSN, IBAN, IPv4/v6, URL), then Venice mistral-small-3-2-24b for residual PII (full names, street addresses, dates of birth). Returns the redacted text and a list of every (type, value, masked_with) triple.

## Output

Returns the redacted version of the input text (with PII replaced by masked tokens) and a structured list of every redacted entity as (type, original_value, masked_with) triples — covering emails, phone numbers, SSNs, IBANs, credit cards, IPv4/v6 addresses, URLs, full names, street addresses, and dates of birth.

## Example request

```json
{
 "text": "Please redact any PII from this sample text: Alice Johnson called on 2024-03-20 from 555-123-4567. Her email is alice.johnson@example.com and she lives at 789 Maple Street, Seattle, WA 98101. Her SSN is 987-65-4321."
}
```

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "required": [
      "text"
     ],
     "properties": {
      "mask": {
       "type": "string",
       "description": "Replacement string. Use 'type' (default) for [EMAIL], [PHONE], etc.; or any literal string for a uniform mask."
      },
      "text": {
       "type": "string",
       "description": "Text to redact. Up to 30,000 chars."
      }
     }
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "found": {
       "type": "array",
       "items": {
        "type": "object",
        "properties": {
         "type": {
          "type": "string"
         },
         "value": {
          "type": "string"
         },
         "masked_with": {
          "type": "string"
         }
        }
       }
      },
      "model": {
       "type": "string"
      },
      "source": {
       "type": "string"
      },
      "original": {
       "type": "string"
      },
      "redacted": {
       "type": "string"
      },
      "found_count": {
       "type": "integer"
      }
     }
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/x402-deployer-x402-deployer-workers-dev-adb427b6/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402-deployer.x402-deployer.workers.dev](https://www.zero.xyz/host/x402-deployer.x402-deployer.workers.dev/llms.txt)
