Skip to main content
Glama

pretrade

Read-onlyIdempotent

Call this before your agent buys a Solana token. One call runs five isolated checks: token risk (sell-side skim and fee/hook controls), top-holder concentration (the factor behind our bundle score), stablecoin lookalike detection, xStock status (issuer mint list, lookalikes and issuer objections), and optionally an x402 payee check (verdict ok, caution, do_not_pay or unknown). Unknown mints return HTTP 404 before payment. Returns verdict avoid, caution, ok or unknown, each factor's status and confidence, and plain limits. A slow or failed factor returns unknown; unknown is never ok. Capped at 3 seconds. If every factor fails the call returns HTTP 502 and you are not charged. Part of the agent spend firewall bundle (payee_check + seller_report + pretrade); see /.well-known/x402 bundles. Costs $0.014 USDC (14000 base units) via x402. The same price is charged for HTTP GET /pretrade. An unpaid HTTP call returns 402 even when the query is missing or invalid. A signed call with invalid arguments is rejected before settlement and is not charged. A successful result can set cached, stale, and cacheAgeMs. stale true means a previous result was served while a refresh runs or the upstream failed. You are charged only when the tool result is not an error.

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": {
      "mint": "<mint>"
    },
    "name": "pretrade"
  }
}

Input Schema

NameRequiredDescriptionDefault
mintYes
payToNo
symbolNo
networkNo
endpointNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior5/5

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

Goes far beyond the annotations: 3-second cap, HTTP 404 on unknown mints, 502 when every factor fails, unknown-never-equals-ok semantics, $0.014 USDC x402 pricing, charge/no-charge rules for unpaid and invalid-argument calls, and cached/stale/cacheAgeMs flags. That is exactly the behavioral context the readOnly/idempotent hints cannot convey.

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?

Roughly 200 words but front-loaded with purpose and factor list, then payment and failure semantics. Slightly redundant at the tail ('You are charged only when the tool result is not an error' restates earlier charge rules), but nearly every sentence carries operational information.

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 high-complexity paid tool with no output schema, the description covers verdict values, per-factor status/confidence, limits, error codes, and billing well enough to call it correctly. The remaining gap is parameter documentation rather than return-value or failure-mode coverage.

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

Parameters2/5

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

Schema description coverage is 0% across five parameters, so the description must carry the burden. It implicitly identifies mint as the token and hints at a payee/endpoint/network for the optional x402 check, but symbol, network, and endpoint are never explained and none of the five fields is defined or given format guidance.

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 chain: runs five named checks (token risk, holder concentration, stablecoin lookalike, xStock, optional x402 payee) on a Solana token before a buy. The named factor list plus the bundle membership ('payee_check + seller_report + pretrade') makes it clearly distinguishable from siblings like payee_check or token_check_demo.

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?

'Call this before your agent buys a Solana token' gives explicit trigger timing, and the optional-payee framing tells the agent when the payTo path matters. It does not, however, state when to prefer pretrade over the sibling payee_check or token_check_demo, so the exclusion side is left to inference.

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