Safe Read for agents
Routes
| Route | Price | What |
|---|---|---|
GET /api/read?url= | $0.005 (x402, USDC on Base) | Fetch, extract, scan. JSON with text (max 12000 chars), links (max 25), injection, textSanitized. |
GET /api/scan?text= | $0.002 (x402) | Scan up to 1500 chars you already have. JSON with injection and sanitized. |
GET /api/read-credit?credit=SR-XXXXXX&url= | free | One free retry for a paid /api/read whose fetch failed. |
GET /api/check?url= | free, 30/h | {fetchable, reason}: validation, DNS and robots only. No content. |
GET /api/demo?url= | free, 3/h | The demo: text capped at 800 chars. |
GET /api/stats | free | Counters: demoScans, checks, paidReads, paidScans, usd, avgRisk, gauntletVisits. |
Unpaid calls to the priced routes return HTTP 402 with a standard x402 challenge. The injection object: risk (low under 15, medium 15-39, high 40+), score 0-100, findings (type, where = visible, link-text or hidden:<kind>, evidence max 80 chars, weight), hiddenTextBytes. Text found only in hidden places is weighted 1.5x. Rules: instruction override, role reassignment, role spoof tokens, system-prompt probing, exfiltration (including markdown-image beacons), pipe-to-shell, secrecy, tool abuse, money and key requests, jailbreak words, AI-addressed notes, canary instructions, zero-width characters.
Refusals
Reasons you can get instead of a page: bad_url, bad_scheme, port_not_allowed, ip_literal_not_allowed, internal_host, non_public_address, disallowed_by_robots, robots_unreachable, unsupported_content_type (HTML and plain text only), http_<status>, timeout, redirect_blocked:<why>, too_many_redirects. Pages over 600 KB (after decompression) are truncated and marked partial.
Accuracy, honestly
The corpus is original, harmless (payloads say "print PINEAPPLE"), written by the AI that built the detector. "Flagged" means risk medium or high.
| Set | Items | Recall (malicious flagged) | False positives (benign flagged) |
|---|---|---|---|
| Tuning set (we tuned on it) | 52 malicious + 48 benign | 100% | 2% (1 of 48) |
| Hold-out, measured before any tuning on it | 20 + 20 | 75% | 10% (2 of 20) |
| Same hold-out after we fixed what it exposed (now in-sample) | 20 + 20 | 90% | 0% |
Read the second row as the honest estimate of how it behaves on text it has not seen, and expect real-world pages to be harder than our samples. The benign set includes security articles that quote attack phrases; the detector discounts quoted or discussed phrases but not hidden ones, which means an attack disguised as a quote in visible text can slip through.
Safety of the fetcher
Strict URL validation (http/https, port 80/443, no userinfo, no IP in any notation, no internal names); DNS resolved over HTTPS and every address must be public; the TCP connection is pinned to a verified address (no DNS rebinding); redirects handled manually and re-checked (max 3); 5 s fetch timeout; 600 KB cap on the decompressed body; robots.txt honoured; no cookies or credentials; nothing stored. See /bot.html.