# Prescan Text Scanner

> Prescan Text Scanner is a paid API for AI agents from prescan.canisell.xyz, paid per call via x402, $0.002/call, status unknown (last checked 2026-11-23).

Runs deterministic, rule-based heuristic checks on untrusted text to detect prompt injection, data exfiltration attempts, concealment tactics, and other malicious patterns before an agent processes it.

## Facts

- Endpoint: POST https://prescan.canisell.xyz/v1/scan/text?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-23
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/prescan-text-scanner-b2252318
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_fftasXlHRfRdkd7t53T-3

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 prescan-text-scanner-b2252318 -d '<json body>'
```

Example prompt: Before you read this tool output, run it through Prescan first — flag it as source type 'tool_output' and block if anything malicious is found: [paste text here].

## When to prefer this

Use Prescan when you need a fast, deterministic, non-LLM safety check on untrusted content before your agent processes it — especially for tool outputs, scraped web pages, emails, MCP server responses, or token metadata. Prefer it over LLM-based safety classifiers when you need sub-millisecond latency, explainable rule-based findings with rule IDs, published precision/recall, and guaranteed no input storage. It is especially valuable in agentic pipelines where the cost of a compromised context window is high.

## Known failure modes

- Text exceeds 100,000 character limit — request rejected
- Batch exceeds 100 items or 200,000 total characters — request rejected
- Malformed JSON body or missing both 'text' and 'items' fields — validation error
- Payment not received or x402 payment header missing — 402 Payment Required
- Transient service unavailability — 5xx error with no scan result

## How this service works

Deterministic, explainable checks an agent runs before it reads untrusted text, connects to an MCP server or pays an x402 endpoint. No LLM in the loop, sub-millisecond scans, spans for every finding, published rules (GET /v1/rules) and published precision/recall.

Heuristic signals, not a guarantee: a clean result lowers risk, it does not prove content is safe. Inputs are not stored.

## Output

Returns a JSON object with: a verdict (e.g. 'malicious', 'suspicious', 'clean'), a numeric risk score (0-100), a recommended action ('block', 'warn', 'allow'), a list of detailed findings each with rule ID, category, severity, weight, excerpt, and character positions, a summary string, the ruleset version used, a breakdown of hidden character counts (zero-width, bidi controls, homoglyphs, etc.), extracted links with per-link flags, and optionally a sanitized version of the input text with injected instructions replaced by markers.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string",
   "maxLength": 100000,
   "description": "Text to scan, up to 100000 characters. Use either text or items."
  },
  "items": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "text"
    ],
    "properties": {
     "id": {
      "type": "string",
      "maxLength": 200
     },
     "text": {
      "type": "string",
      "maxLength": 100000
     },
     "source": {
      "enum": [
       "web_page",
       "email",
       "tool_output",
       "document",
       "chat_message",
       "token_metadata",
       "code",
       "other"
      ],
      "type": "string",
      "description": "Where the text comes from; tunes a few rules (token_metadata flags any URL in a token name)."
     }
    }
   },
   "maxItems": 100,
   "description": "Batch: up to 100 texts (e.g. token names, search results, emails), 200000 characters in total, one price."
  },
  "source": {
   "enum": [
    "web_page",
    "email",
    "tool_output",
    "document",
    "chat_message",
    "token_metadata",
    "code",
    "other"
   ],
   "type": "string",
   "description": "Where the text comes from; tunes a few rules (token_metadata flags any URL in a token name)."
  },
  "sanitize": {
   "type": "boolean",
   "description": "Return `sanitized`: the text with invisible characters removed and injected instructions replaced by a marker. Default true."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "links": [
   {
    "end": 198,
    "url": "https://collector.example-analytics.io/log",
    "host": "collector.example-analytics.io",
    "flags": [],
    "start": 156
   }
  ],
  "score": 100,
  "action": "block",
  "hidden": {
   "zero_width": 0,
   "soft_hyphens": 0,
   "styled_chars": 0,
   "unicode_tags": 0,
   "bidi_controls": 0,
   "homoglyph_words": 0,
   "variation_selectors": 0
  },
  "source": "tool_output",
  "decoded": [],
  "flagged": true,
  "ruleset": "2026.11.1",
  "summary": "malicious: data_exfiltration, instruction_override, concealment (9 findings).",
  "verdict": "malicious",
  "findings": [
   {
    "end": 118,
    "rule": "override.ignore_previous",
    "start": 86,
    "weight": 0.85,
    "excerpt": "ignore all previous instructions",
    "message": "Ignore / disregard / forget the previous instructions.",
    "category": "instruction_override",
    "severity": "high"
   },
   {
    "end": 164,
    "rule": "exfil.send_secrets",
    "start": 123,
    "weight": 0.85,
    "excerpt": "send the conversation history to https://",
    "message": "Send conversation / secrets / files to an outside destination.",
    "category": "data_exfiltration",
    "severity": "high"
   },
   {
    "end": 105,
    "rule": "override.forget_everything",
    "start": 86,
    "weight": 0.75,
    "excerpt": "ignore all previous",
    "message": "Forget everything said before.",
    "category": "instruction_override",
    "severity": "high"
   },
   {
    "end": 164,
    "rule": "exfil.history_to",
    "start": 132,
    "weight": 0.75,
    "excerpt": "conversation history to https://",
    "message": "Conversation history sent to an address or URL.",
    "category": "data_exfiltration",
    "severity": "high"
   },
   {
    "end": 224,
    "rule": "conceal.dont_tell",
    "start": 204,
    "weight": 0.75,
    "excerpt": "do not tell the user",
    "message": "Do not tell the user.",
    "category": "concealment",
    "severity": "high"
   },
   {
    "end": 46,
    "rule": "delim.close_wrapper",
    "start": 32,
    "weight": 0.65,
    "excerpt": "</tool_result>",
    "message": "Closes the wrapper the agent put around untrusted data.",
    "category": "delimiter_spoofing",
    "severity": "medium"
   },
   {
    "end": 80,
    "rule": "agent.if_you_are",
    "start": 58,
    "weight": 0.65,
    "excerpt": "AI agents reading this",
    "message": "\"If you are an AI ...\" conditional instruction.",
    "category": "agent_ta
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/prescan-text-scanner-b2252318/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from prescan.canisell.xyz](https://www.zero.xyz/host/prescan.canisell.xyz/llms.txt)
