Skip to main content
Glama

Agent safety checks: prompt-injection scan, honeypot check, x402 preflight + crypto data (USDC/x402)

Pre-trade check: validate a crypto setup before ordering

validate_setup
Read-only

Pre-trade sanity check before an order is placed — a crypto setup checked against the live Binance market: geometry, stop vs 1h ATR, reward-to-risk, 1h/4h trend, RSI14, entry distance — valid | weak | invalid, score 0-100, every check. 0.10 USDC base (new payers 0.10, >10 payments 0.07; 2 pack calls). After: historical_gate for the same symbol and bias.

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": {
      "symbol": "<symbol>",
      "bias": "<bias>",
      "entry": "<entry>",
      "stop": "<stop>"
    },
    "name": "validate_setup"
  }
}

Input Schema

NameRequiredDescriptionDefault
tp1No
tp2No
biasYes
stopYes
entryYes
symbolYesBinance spot pair, e.g. BTCUSDT
payment_txNoHash of a USDC transfer on Base to payTo (≥ the price, ≤ 72 h old) instead of an x402 signature.
bundle_tokenNoToken from buy_signal_pack, buy_subscription (pro/desk) or buy_enterprise instead of paying per call.
payer_addressNoWallet you pay from: the payment-required error quotes your tier (0 payments base price (new-payer surcharge paused), 1-10 base, >10 -30 %) and, from the third payment, an upgrade with your own spend.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / payer_address / description
      Previous value: -"Wallet you pay from: the payment-required error quotes your tier (0 payments +50 %, 1-10 base, >10 -30 %) and, from the third payment, an upgrade with your own spend."New value: +"Wallet you pay from: the payment-required error quotes your tier (0 payments base price (new-payer surcharge paused), 1-10 base, >10 -30 %) and, from the third payment, an upgrade with your own spend."
  2. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Beyond the readOnly/openWorld annotations, the description discloses the full check list, the output verdict shape and score range, and the cost model (0.10 USDC base, 0.07 after 10 payments, 2 pack calls). This is exactly the kind of pricing and result-shape context an agent needs before spending a paid call, and nothing contradicts the read-only annotation.

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 purpose and check list are front-loaded and the follow-up routing is placed last, which is the right order. The pricing parenthetical ('new payers 0.10, >10 payments 0.07; 2 pack calls') is densely packed and slightly harder to parse than the rest.

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?

For a 9-parameter paid tool with no output schema, the description does the heavy lifting: it defines the verdict output, the pricing tiers, and the downstream step. The remaining gap is the role of the optional tp1/tp2 parameters in the reward-to-risk check.

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 only 44% across 9 parameters, and the description compensates by explaining what the four required values feed into (stop measured against 1h ATR, entry distance, reward-to-risk implying tp1/tp2 as targets). It never explicitly states how tp1/tp2 are used or whether both are needed for the RR check, leaving some ambiguity.

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?

The description gives a specific verb and resource ('pre-trade sanity check' of a 'crypto setup') and enumerates exactly what is evaluated: geometry, stop vs 1h ATR, reward-to-risk, 1h/4h trend, RSI14, entry distance. It also states the return verdict scale (valid | weak | invalid, 0-100), which makes it clearly distinguishable from neighboring gate tools.

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?

Timing is explicit ('before an order is placed') and it names a concrete follow-up sibling: 'After: historical_gate for the same symbol and bias.' It does not say when to prefer validate_batch or preflight instead, so the alternative-selection guidance is incomplete, but the primary sequencing guidance is clear.

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