Skip to main content
Glama

prompt_injection_check

Read-only

Prompt-injection risk check for agents: GET ?url= scans a public page (visible and hidden text, comments, attributes, meta, JSON-LD) or POST JSON {"text"} (max 50 KB) scans raw text. Flags instruction overrides, role/system-prompt spoofing, secret exfiltration asks, tool-call coercion, hidden or unicode-smuggled text, base64 instructions and markdown image exfil links. Returns a 0-100 risk score, low/medium/high verdict and findings. Heuristic; not charged on failure. — $0.002 USDC per call via x402 v2 (Base or Solana).

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": "prompt_injection_check"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoPublic http(s) URL of the page to scan (use this or text)
textNoRaw text/Markdown/HTML to scan instead of a URL (max 50 KB; best sent as POST JSON body)

Output Schema

NameRequiredDescriptionDefault
okYes
urlNo
noteNo
adviceNo
countsNo
sourceNo
verdictNo
findingsNo
final_urlNo
risk_scoreNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.2/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond readOnlyHint/openWorldHint, it discloses the 50 KB input cap, that the result is heuristic (accuracy caveat), that failures are not charged, and the exact cost and payment rails ($0.002 USDC via x402 v2 on Base or Solana). The described behavior (GET/POST reads, no mutation) is fully consistent with readOnlyHint=true.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The scan semantics are front-loaded and the field list is dense but scannable; the payment line is tacked on with an em dash and is slightly crammed. Little waste overall, but the pricing clause could be a separate, shorter sentence.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With an output schema present, the return description (0-100 score, low/medium/high verdict, findings) is a bonus rather than a requirement, and the input limits, payment model, and heuristic caveat cover the complexity of a paid scanning tool. Missing only edge-case behavior such as non-public/unreachable URLs or rate limits.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, so the baseline is 3, but the description adds meaning: url must be a public page, text is capped at 50 KB, and the GET-vs-POST transport distinction is spelled out. It does not clarify what happens if both parameters are supplied, but the mutual exclusivity is implied.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific verb and resource ("prompt-injection risk check") and enumerates exactly what it inspects (visible and hidden text, comments, attributes, meta, JSON-LD) and what it flags. This is clearly distinct from siblings like read_url or security_headers, though it never explicitly names an alternative to route away from.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It states the two operating modes and their inputs clearly (GET ?url= for a public page, POST JSON {"text"} for raw text up to 50 KB), which is actionable guidance for choosing a mode. It stops short of naming when not to use it or pointing to a sibling for related checks.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources