Skip to main content
Glama
stellar-mcp

stellar-mcp

by ijele-don

simulate_transaction

Simulates a base64 Soroban transaction envelope to preview return values, resource costs, fees, footprints, events, and error diagnoses before submitting on Stellar.

Instructions

Simulate a base64 TransactionEnvelope XDR on Soroban RPC. Returns decoded return value, CPU/memory cost, min resource fee, decoded ledger footprint, events, restore preamble, or structured error diagnosis.

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": {
      "xdr": "<xdr>"
    },
    "name": "simulate_transaction"
  }
}

Input Schema

NameRequiredDescriptionDefault
xdrYesBase64-encoded TransactionEnvelope XDR
networkNoOptional network override (defaults to configured STELLAR_NETWORK).
contract_idNoOptional contract ID (C...) to resolve custom #[contracterror] codes on failure

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4/5.0
Behavior4/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 well: it enumerates the return payload (decoded return value, CPU/memory cost, min resource fee, ledger footprint, events, restore preamble) and flags structured error diagnosis. It stops short of stating that simulation has no on-chain side effects or what network/auth requirements apply, which keeps it from a 5.

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?

Two tightly packed sentences with no filler. The core action and RPC context are front-loaded, and the return values are enumerated compactly in the second sentence without redundant restatement.

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?

There is no output schema, so the description must describe return values, and it does so thoroughly, including error diagnosis paths. What remains underspecified is behavioral context (side-effect-free nature, network prerequisites) for a tool with zero annotation coverage.

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 the schema already documents xdr, network, and contract_id, and this establishes the baseline of 3. The description adds no syntax or format detail beyond what the schema provides; the only overlap is the contract_id error-resolution hint, which the schema already states.

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: 'Simulate a base64 TransactionEnvelope XDR on Soroban RPC.' The verb 'simulate' semantically contrasts with siblings like submit_transaction and build_transaction, and the description goes on to enumerate exactly what the simulation produces, so an agent can identify the tool without opening the schema.

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?

Usage is only implied by the word 'simulate' — an agent can infer this is a dry-run/validation step, but the description never states when to prefer it over submit_transaction or diagnose_soroban_error. The only explicit conditional is 'contract_id ... to resolve custom #[contracterror] codes on failure,' which is a narrow hint rather than general guidance.

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