Privacy & Logging Controls
Control request body capture, PII redaction, zero-data-retention routing, blocked providers and data residency.
The Privacy & safety page holds every retention and routing-policy control. Settings are global: they apply to every key and override preset settings. Controls on Request Logs inherit from here and cannot widen logging beyond it. Changes save immediately and reach the router within seconds. A card at the top summarizes your current stance.
| Control | Default | What it changes |
|---|---|---|
| Log request/response bodies | On | Whether the full prompt and completion are stored |
| PII redaction | On (when logging is on) | Strips emails, phone numbers and common secrets from stored bodies |
| Always enforce ZDR | Off | Routes only to zero-data-retention providers; rejects requests none can serve |
| Blocked providers | None | Upstreams that never receive this account's traffic |
| Moderation plugin | Off | Scans prompts and completions against a content policy |
Metadata logging (model, tokens, cost, latency, status) is on for every request. Body capture is on by default on every plan (since 27 July 2026) and controlled by the Body logging switch. PII redaction is still rolling out: your preference is saved and applies as the pipeline reaches your region. ZDR, blocked providers and moderation are live.
Body capture
With Log request/response bodies on, AnyRouter stores messages, model output, tool calls and attached images, so you can open any log entry and see the exact prompt and completion. With it off, only metadata is kept (model, provider, token counts, latency, status, timestamp, truncated cache key): enough for spend and latency questions, not for replay or eval sets.
Storage grows with traffic, and anything in a body lands in your logs. Caching is unaffected. Turning it off does not redact existing entries; they stay visible until they leave your plan's retention window.
PII redaction
When body logging is on, stored prompts and completions pass through a redactor before persistence:
| Pattern | Replaced with |
|---|---|
| Email addresses | [REDACTED_EMAIL] |
| Phone numbers (NANP, E.164, most international) | [REDACTED_PHONE] |
| Credit card numbers (Luhn-valid, 13-19 digits) | [REDACTED_CC] |
API keys and tokens (sk-, sk-ar-, ghp_, xoxb-, AWS keys, JWTs) | [REDACTED_SECRET] |
| IP addresses (IPv4 and IPv6) | [REDACTED_IP] |
SSN-shaped sequences (NNN-NN-NNNN) | [REDACTED_SSN] |
Only the stored copy is redacted; the upstream receives the original prompt. To scrub data before it leaves your app, do it client-side. The redactor is conservative (favors false positives) and never blocks delivery: if it errors, the log entry is dropped and the request still succeeds. Plans with custom redaction rules can add a regex through the API described under Request Logs.
Zero data retention
Always enforce ZDR is the only privacy routing control.
- Off (default): every provider can serve you, including free tiers and hosts that train on prompts. Model pages and the Decisions picker mark such hosts Trains on prompts, and the models list marks the model May retain. The badge is information only and never blocks a request.
- On: only providers that guarantee zero retention receive your requests. A provider that does not say so is skipped, so free and community-hosted models are often unavailable. Providers that publish prompt-completion pairs to public datasets are not ZDR.
If ZDR leaves no provider for the model, the request returns 403 zdr_required naming the setting. If something else also empties the list (for example you blocked every provider), you get the usual no-route error. Turn it on for any account handling customer data.
Blocked providers
In Provider restrictions, tap a provider to block it for this account and tap again to unblock. A blocked provider never receives a request from your keys, whatever the model, preset or fallback chain; the router picks the next eligible upstream. If the only upstream for a model is blocked, the request returns 503 no_eligible_provider with the reason. The list is account-wide; to block a provider on one key only, route that key through a preset that pins upstreams (see Routing).
Data residency
AnyRouter runs on Cloudflare Workers, so requests land at the nearest edge.
| Data | Where it lives |
|---|---|
| In-flight request data | In memory at the edge for the request, then discarded; bodies stream to the upstream, not to disk |
| Request metadata | Cloudflare D1 in the account's primary region (reads replicate globally, writes go to one region) |
| Request bodies (when logging on) | Same D1 instance, encrypted at rest with a per-row salt |
| API keys | Encrypted at rest in D1 with a per-row salt; plaintext shown once at creation |
| Usage counters | Cloudflare KV for credit checks, globally replicated, eventually consistent |
Upstream providers follow their own residency commitments; pin regional providers with a preset. If no prompt may cross a border, turn body logging off, block every region you cannot use, and enforce ZDR.
Retention
- Request logs: read access is clamped to the plan window: 7 days on Free and Go, 30 days on Pro and Max, 90 days on Enterprise, with or without bodies. Older rows are not returned; body logging only changes entry size.
- Aggregated usage (tokens, cost, latency) is kept 365 days and never contains prompt text.
- Custom windows are available with a signed DPA; contact support.
Audit
Every change to a switch here records who (user id and email), the field with old and new value, when (UTC, to the millisecond) and where from (IP and user agent). Records are kept 365 days and cannot be edited or deleted from the dashboard. In personal workspaces only the owner can change settings; in organizations only admin members can, and others can view.
Recommended setup
For a production support agent handling PII that needs bodies for offline evaluation: body logging on, PII redaction on, Always enforce ZDR on, block any provider outside your DPA, moderation on. Then check real routing decisions on Request Logs after a few requests.
AnyRouter routes requests to third-party models. Models and outputs are provided as is, with no warranty; you use them at your own risk. Disclaimer