Skip to main content
Glama
GuessMarket MCP Server

GuessMarket MCP Server

by hifriendbot

build_buy_shares_tx

Build an unsigned transaction to buy YES or NO shares on a prediction market using CPMM pricing, given a market address, outcome, stablecoin amount, and chain ID. Requires prior stablecoin approval.

Instructions

Build an unsigned transaction to buy YES or NO shares on a prediction market. Requires prior stablecoin approval. Returns shares based on CPMM pricing.

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": {
      "market_address": "<market_address>",
      "outcome": "<outcome>",
      "amount": "<amount>",
      "chain_id": "<chain_id>"
    },
    "name": "build_buy_shares_tx"
  }
}

Input Schema

NameRequiredDescriptionDefault
amountYesStablecoin amount to spend (e.g. "10.5")
outcomeYesMarket outcome: YES or NO
chain_idYesEVM chain ID (e.g. 8453 for Base, 369 for PulseChain)
min_sharesNoMinimum shares to accept (slippage protection). Default "0" for no minimum.0
market_addressYesPredictionMarket contract address

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.3.0

TDQS

A3.7/5.0
Behavior3/5

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

With no annotations, the description carries the full burden and does disclose meaningful traits: the transaction is unsigned (no signing or broadcast), approval must already exist, and share quantity derives from CPMM pricing. It omits what happens if approval is missing, whether anything expires, and what the caller must do with the unsigned payload, which are material for a write-path builder.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three short sentences, zero filler, and the core action is front-loaded. The prerequisite and the return semantics each get exactly one clause, so every sentence earns its place.

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 5-parameter builder with no output schema, the description covers action, precondition, pricing model, and the shape of the result (shares). It could say more about the unsigned-transaction handoff and failure when approval is absent, but nothing essential to selecting or invoking the tool 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 description coverage is 100%, so baseline is 3; the description adds real meaning on top by explaining that amount is converted to shares via CPMM pricing and that approval state is a precondition tied to amount/chain. It still does not explain how min_shares interacts with CPMM pricing beyond the schema's own slippage note.

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?

States a specific verb and resource: builds an unsigned buy transaction for YES/NO shares on a prediction market. The clause 'Requires prior stablecoin approval' implicitly separates it from the sibling build_buy_with_approval_tx, but it never names that sibling or build_approve_tx, so differentiation is inferential rather than explicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives one real precondition ('Requires prior stablecoin approval'), which tells the agent this is the second step in a two-call flow. It does not say which sibling to call to obtain that approval, nor when to prefer the with-approval variant over this one, leaving the routing decision to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.