Prompt-injection check: probability, attack types, flagged spans and a sanitized copy of text or a page
ai_prompt_injectionUse when an agent must screen untrusted text (web page, email, tool output, RAG chunk) before an LLM reads it. Input: text (up to 20,000 chars, POST JSON or GET) or url. Output: JSON probability 0-1, verdict (clean/suspicious/injection), attackTypes, spans with offsets, sanitizedText with flagged spans removed, method (rules + open-model classifier; rules only if the model is down). Heuristic, not a guarantee. Example: ?text=Ignore previous instructions Price: $0.003 USDC (Base or Solana) via x402.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "ai_prompt_injection"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | Public http(s) page to fetch and check instead of text (SSRF-safe); give text or url, not both | |
| text | No | Text to check (up to 20,000 characters). Required unless url is given; use POST JSON for long text |