Skip to main content
Glama

x420_security_action-gate

Read-onlyIdempotent

Action preflight gate: Deterministic preflight for an agent action before it runs: prompt-injection scan of the action text, URL public-host check (DNS-resolved, private ranges refused) with an optional host allow-list, JSON payload parse and required-key check, and a spend-cap check (amount_usd against max_usd). Returns allow or block with every rule's result. Source: X420 rules. Not professional, legal, insurance, engineering, medical, financial or tax advice. Price: $0.002 USDC per call (x402 on Base). This hosted tool does NOT pay and does NOT return the deliverable: it validates the input and returns payment instructions (pay_to, network, price and the x402 URL to pay at). GET the url; read PAYMENT-REQUIRED from the 402; retry with PAYMENT-SIGNATURE (x402 v2). Or run the local x420-mcp server with your own wallet key to pay automatically. Deliverable once paid: JSON: verdict allow|block, checks[]{check, pass, detail}, injection.

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": "x420_security_action-gate"
  }
}

Input Schema

NameRequiredDescriptionDefault
urlNoURL the action would call (optional)
textNothe action text or untrusted content to scan (optional)
max_usdNospend cap (optional, with amount_usd)
payloadNoJSON payload the action would send (optional)
amount_usdNoamount the action would spend (optional, with max_usd)
allowed_hostsNocomma-separated hosts the URL must match (optional)
required_keysNocomma-separated keys the payload must carry (optional)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.9/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and openWorldHint, so the safety profile is covered. The description goes substantially beyond them by disclosing the payment gating: the hosted tool does not pay and does not return the deliverable, instead returning pay_to/network/price plus the x402 URL and the GET → PAYMENT-REQUIRED → PAYMENT-SIGNATURE retry flow, with a local-server alternative. That is genuine behavioral context of the kind annotations cannot express, so it sits above a bare 3.

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 purpose and then the checks, followed by the payment mechanics and the deliverable shape — a sensible order with no filler in the core content. It is dense, with the check list packed into one long clause and a legal disclaimer taking a sentence, but every part does work.

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?

No output schema exists, yet the description spells out the deliverable shape (verdict, checks[] with check/pass/detail, injection) and the full payment choreography an agent must follow to obtain it. For a seven-parameter, zero-required tool, nothing needed to call or pay for it is missing.

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%, so the baseline is 3, but the description adds real meaning by tying parameters to checks: the URL check is DNS-resolved and refuses private ranges and honours an optional host allow-list, and amount_usd is compared against max_usd. It still leaves the comma-separated convention and 'required_keys applies only when payload is present' coupling to the schema.

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?

Names a specific verb and resource ('preflight for an agent action before it runs') and enumerates the constituent checks: prompt-injection scan, URL public-host check, JSON payload/required-key check, and spend-cap check. This is far more than a tautology and clearly separates it from a single-purpose scan tool, though it never explicitly names the sibling prompt-injection-scan tool to contrast scope.

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?

States the temporal context clearly — run it before an action executes — and implies the composite nature (use this to gate an action, not to scan one string). It gives no explicit when-not guidance or named alternative for someone who only needs one check.

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