Skip to main content
Glama

xswap.to

Create a swap

create_swap

Create a swap order and get a one-time deposit address. Nothing moves until the user sends the deposit from their own wallet. Before calling, confirm with the user both currencies and their networks, the amount and the payout address. Afterwards tell the user to send exactly amount of the from currency, on its network, to depositAddress, to add depositExtraId as the memo or tag when it is set, and to keep trackUrl. Show any warnings to the user.

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": {
      "from": "<from>",
      "to": "<to>",
      "amount": "<amount>",
      "address": "<address>"
    },
    "name": "create_swap"
  }
}

Input Schema

NameRequiredDescriptionDefault
toYesCurrency to receive. Currency id from search_currencies, for example btc, eth or usdttrc20.
fromYesCurrency to send. Currency id from search_currencies, for example btc, eth or usdttrc20.
amountYesAmount of the from currency the user will send, as a decimal like "0.05".
addressYesThe user's wallet address that receives the to currency. It must be on the to currency's network.
extraIdNoMemo or tag for the payout address. Only when the receiving wallet needs one, such as an exchange account with a deposit tag.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

The annotations declare a non-read-only, open-world, non-idempotent, non-destructive operation; the description adds substantive behavior beyond that — no funds move until the user sends the deposit themselves, the address is one-time, and warnings must be surfaced. It does not state whether the deposit address or implied rate expires, or how long the user has to fund it, which are the main remaining behavioral unknowns for this tool.

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?

It is front-loaded with purpose, then a pre-call section, then a post-call section — a logical order with little waste. The final sentence is long and packs several distinct instructions, but each clause carries actionable 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?

With no output schema, the description usefully describes what comes back and what the agent must tell the user, and it covers the confirmation step that a mutation tool needs. It leaves open the relationship to get_quote (rate locking/expiry) and any minimum-amount constraints, which are the gaps an agent would most plausibly hit.

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 100%, so the baseline is 3; the description still adds value by tying the parameters to the required user-confirmation checklist (both currencies and networks, amount, payout address). It also names the response artifacts (depositAddress, depositExtraId, trackUrl, warnings), which is meaningful because there is no output schema — though it uses 'depositExtraId' where the schema says 'extraId'.

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?

The description names a specific verb and resource ('Create a swap order') and clarifies the immediate result ('get a one-time deposit address'), plus the non-custodial nature of the operation. It never contrasts itself with siblings like get_quote or get_swap_status, so an agent must infer that this is the order-placement step rather than the quoting or status step.

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?

It gives unusually concrete pre-call guidance: confirm both currencies and their networks, the amount, and the payout address with the user before calling. It also prescribes follow-up behavior (tell the user exactly what to send, where, with what memo, and to keep trackUrl). What's missing is when NOT to use it — e.g. whether a quote should be obtained first via get_quote, and whether the swap is bound to that quote.

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