Skip to main content
Glama

x402 Agent Toolkit — Quant Arb, TWSE & Agent Security

mcp_security_scan

[$0.01 USDC via x402] Before your AI agent connects to an unknown remote Streamable HTTP MCP server, scan it: executes initialize + tools/list, inspects every tool description & JSON schema for hidden prompt injections, zero-width/bidi unicode stealth chars, credential/wallet exfiltration instructions, and dangerous shell/execution surfaces, returning a 0-100 risk score, verdict & SHA-256 manifest digest.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "url": "<url>"
    },
    "name": "mcp_security_scan"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlYesPublic Streamable HTTP MCP endpoint URL to audit (e.g. https://example.com/mcp).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the full load and does most of it: it discloses the cost and payment rail ('$0.01 USDC via x402'), the exact remote actions taken against the target (initialize + tools/list), and the return shape (0-100 risk score, verdict, SHA-256 manifest digest). It omits operational edge behavior — timeouts, what happens on an unreachable or non-MCP endpoint, and whether the fee is charged on failure.

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?

Front-loaded with the price and the usage trigger, then the mechanics, then the outputs — good ordering with no filler. It is a single dense sentence whose detection checklist is long, so it reads slightly packed, but every clause conveys a distinct capability.

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

Completeness5/5

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

For a one-parameter tool with no output schema, the description supplies everything an agent needs: cost, when to call, what is executed remotely, what is inspected, and what comes back. Return values are described inline precisely because no output schema exists.

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 100% for the single 'url' parameter, so the baseline is 3. The description adds real meaning beyond the schema: the target must be a live Streamable HTTP MCP server that will actually be contacted and initialized, not an arbitrary URL to fetch, which constrains what values are valid.

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

Purpose5/5

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

States a specific verb and resource ('scan it: executes initialize + tools/list, inspects every tool description & JSON schema') plus the concrete defects it hunts for. An agent can tell immediately that this is a pre-connection security audit of an MCP endpoint, which is distinct from the sibling utilities (safe_fetch, web_to_markdown, x402_preflight) that do not audit server payloads for injections.

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?

The trigger is explicit: 'Before your AI agent connects to an unknown remote Streamable HTTP MCP server, scan it.' That gives a clear when-to-use condition tied to unknown/untrusted endpoints. It does not name a when-not condition or an alternative sibling to use instead, so it stops short of a 5.

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.