Skip to main content
Glama

pre_trade_gate

Read-onlyIdempotent

One call before you trade — GO / HOLD / STOP — Use before an agent buys or swaps into a Base token: token-risk, sellability (honeypot, tax), swap route and price impact for your size, and deployer reputation in one GO/HOLD/STOP verdict with a receipt. GO only when every check ran clean; an outage is HOLD. Coinbase tokenized stocks get stock checks (transfer policy, wallet eligibility, premium vs reference). GO/HOLD return enforce: a Cobalt condition so Base never includes your trade if the pool is drained first. Bind this tool first. Required input: address. Priced $0.10 per call over x402 on Base; send a prepaid x-credit-token header for unlimited calls (no free tier on this tool). No API key required.

Input Schema

NameRequiredDescriptionDefault
walletNoBuyer wallet — for tokenized stocks, checks it may receive (optional)
addressYesToken contract address
amountUsdNoTrade size in USD (optional)
maxLiquidityDropPctNoEnforce: max pool drop before the trade is refused, % (optional, default 20)

Output Schema

NameRequiredDescriptionDefault
dataNoThe result payload. Shape is service-specific; every field is documented in the tool description.
serviceNoThe service id that answered.
checkedAtNoISO-8601 timestamp of when the underlying reads were taken.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / maxLiquidityDropPct
      Added value: +{
      +  "description": "Enforce: max pool drop before the trade is refused, % (optional, default 20)",
      +  "type": "string"
      +}
    • addedInput schema / properties / wallet
      Added value: +{
      +  "description": "Buyer wallet — for tokenized stocks, checks it may receive (optional)",
      +  "type": "string"
      +}
  2. Changed1 schema field changed
    • changedOutput schema / properties / data / description
      Previous value: -"The result payload. Shape is service-specific; every field is documented in the service description above."New value: +"The result payload. Shape is service-specific; every field is documented in the tool description."
  3. Changed1 schema field changed
    • removedOutput schema / required
      Removed value: -[
      -  "data"
      -]
  4. Added

TDQS

A4.6/5.0
Behavior5/5

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

Annotations cover safety (readOnly, idempotent, non-destructive, openWorld), and the description adds substantive context beyond them: GO only when every check ran clean, an outage degrades to HOLD, GO/HOLD return an `enforce` Cobalt condition, pricing at $0.10/call over x402, prepaid x-credit-token for unlimited calls, no free tier, and no API key required. These are operational facts an agent cannot derive from annotations.

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-loads the core verdict semantics (GO/HOLD/STOP, when to call) before pricing/auth details. It is dense and long, but nearly every clause carries distinct information (outage handling, stock case, enforce, payment). Minor redundancy between the first and later sentences keeps it from a 5.

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 high-complexity, paid, multi-check gate with an output schema, the description covers calling conditions, verdict logic, degradation behavior, the tokenized-stock branch, the enforce return, and payment/auth requirements. An agent has everything needed to decide and invoke correctly.

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: it flags `address` as the required input and ties `amountUsd` to the price-impact/'for your size' check and the enforce behavior around max pool drop. The added semantic framing slightly exceeds the schema text.

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+resource ('one call before you trade') and enumerates exactly what the verdict aggregates: token-risk, sellability (honeypot, tax), swap route, price impact for size, and deployer reputation. This clearly differentiates it from single-purpose siblings like token_risk, sellability, swap_route, and deployer_rep, which it bundles into one GO/HOLD/STOP receipt.

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?

Gives explicit context ('Use before an agent buys or swaps into a Base token') and a directive ('Bind this tool first'), plus the special case for Coinbase tokenized stocks. It does not name alternatives (e.g., pre_trade_bundle, near_pre_trade_gate) or state when NOT to use it, so it stops short of full alternative routing.

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