delimit_redact
Scans and redacts sensitive data like API keys, secrets, and PII from text to prevent credential leakage when sharing content externally.
Instructions
Scan or redact sensitive data (API keys, secrets, PII) from text.
When to use: before sending text to external LLMs or publishing output, to prevent leaking credentials or PII. When NOT to use: to manage stored secrets (use delimit_secret_store family) — this is in-memory text redaction.
Sibling contrast: delimit_secret_* manages credentials at rest; this scrubs them out of arbitrary text.
Side effects: read-only on input text — produces a sanitized copy in action="redact". Calls ai.pii_redact.scan / redact. Detects: API keys (OpenAI, xAI, Google, GitHub, npm), passwords, bearer tokens, emails, phone numbers, SSNs, credit cards, IPs, database URLs.
The internal token map is intentionally NOT exposed via MCP — it stays local. action="redact" returns only the redacted text and counts; the original cannot be recovered through this tool.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| action | No | "scan" (preview, default) or "redact" (replace). | scan |
| text | No | Text to process. | |
| categories | No | Comma-separated categories — "api_key", "secret", "pii", "infra". Empty = all categories. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||