Skip to main content
Glama

$AI on HyperEVM

Build Buy Transaction

ai_build_buy_tx
Read-onlyIdempotent

Build an unsigned buy transaction against the AiCurve contract. Returns calldata only; the caller signs and sends it. Includes an estimated gas limit when from is given.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fromNo0x sender address; when given the tx includes a gas estimate
hypeYesHYPE amount to spend, decimal string, max 10000
slippage_bpsNoSlippage tolerance in basis points, 0-5000, default 200

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
txYes
quoteYes
disclosureYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "properties": {
      +    "disclosure": {
      +      "type": "string"
      +    },
      +    "quote": {
      +      "properties": {
      +        "minTokensOut": {
      +          "type": "string"
      +        },
      +        "slippageBps": {
      +          "type": "integer"
      +        },
      +        "tokensOut": {
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "tokensOut",
      +        "minTokensOut",
      +        "slippageBps"
      +      ],
      +      "type": "object"
      +    },
      +    "tx": {
      +      "properties": {
      +        "chainId": {
      +          "type": "string"
      +        },
      +        "data": {
      +          "type": "string"
      +        },
      +        "from": {
      +          "type": "string"
      +        },
      +        "gas": {
      +          "type": "string"
      +        },
      +        "to": {
      +          "type": "string"
      +        },
      +        "value": {
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "chainId",
      +        "to",
      +        "value",
      +        "data"
      +      ],
      +      "type": "object"
      +    }
      +  },
      +  "required": [
      +    "tx",
      +    "quote",
      +    "disclosure"
      +  ],
      +  "type": "object"
      +}
  2. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, and destructiveHint false. The description adds valuable behavioral context: it returns calldata only, the caller must sign and send it, and a gas estimate is included when `from` is provided. This goes beyond what the annotations convey and clarifies the non-executing nature of the operation.

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?

The description is two sentences with no filler. It front-loads the core purpose in the first sentence and follows with the key output behavior and a conditional detail. Every word 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?

The tool has an output schema, so return values are covered there. The description explains what the tool does, what it returns, and the special case of gas estimation. It is complete for an agent to call it correctly, though it could optionally mention when to prefer a sell or quote sibling, but that falls under usage guidance rather than completeness.

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

Parameters3/5

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

Schema description coverage is 100%, so all parameters are already documented in the schema. The tool description adds no new meaning beyond the schema's own descriptions—it merely restates the `from` behavior already present. Per guidelines, baseline 3 is appropriate when schema does the heavy lifting.

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 clearly states the verb ('Build'), the resource ('an unsigned buy transaction against the AiCurve contract'), and the scope ('returns calldata only'). It distinguishes itself from siblings like ai_build_sell_tx by specifying 'buy' and from quote tools by specifying 'build'.

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?

The description implies when to use this tool (when you need a buy transaction to be built) but provides no explicit guidance on when not to use it or when to choose alternatives like ai_build_sell_tx or ai_quote_buy. The context is clear but lacks explicit exclusions or 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