Skip to main content
Glama

Ekubo Protocol

Prepare a TWAMM or DCA order

prepare_twamm_order
Read-only

Prepare one or more TWAMM order splits with approvals and native value as one atomic batch. details.token_id is the order's id before anything is sent: keep it, because prepare_twamm_order_collection and prepare_twamm_order_stop are keyed by it and orders are not enumerable by owner. Start and end times must be multiples of 256 seconds near the present, widening in powers of 16 further out.

Input Schema

NameRequiredDescriptionDefault
saltNoFixes the order's token id; omit to derive it from the request. Supply one only when identical orders need distinct ids (bytes32 hex)
ordersYes
senderYesaddress
chain_idYesEVM chain ID
buy_tokenYesToken; zero address = native
sell_tokenYesToken; zero address = native
deadline_secondsNo
pending_timestampYesdecimal integer

Output Schema

NameRequiredDescriptionDefault
execution_plan_referenceNoartifact_reference; pass unchanged

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 description adds substantial context beyond readOnlyHint=true: it discloses that approvals and native value are bundled atomically, that token_id is minted at prepare time and is the only handle because orders aren't enumerable by owner, and that times are quantized (multiples of 256s near present, powers of 16 further out). It does not clarify what happens after preparation (whether it broadcasts, what the caller must do to submit) — the one point where readOnlyHint could be misread by an agent as "this places the order".

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?

Three sentences, each carrying distinct information: what is built, the token_id lifecycle constraint, and the timestamp quantization rule. The front-loaded first sentence establishes scope immediately; the timestamp rule is dense but not padded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so return-shape explanation is not required, but for a complex prepare tool (8 params, nested orders array, atomic approval batching) the description omits chain applicability, what the agent should do with the result next (sign/submit flow), and any limits on order count. The critical id-retention constraint is covered, so the core risk is addressed but peripheral context 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?

At 75% schema coverage the schema already documents most fields, but the description adds meaning the schema lacks: it constrains start_time/end_time to multiples of 256 seconds near the present and powers of 16 further out, which the schema only calls "decimal integer". It also explains salt's purpose (deriving token_id, needed for duplicate identical orders) in a way that complements the schema text.

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?

"Prepare one or more TWAMM order splits with approvals and native value as one atomic batch" names a specific verb (prepare), a specific resource (TWAMM order splits), and the packaging semantics (approvals + native value in one batch). It also implicitly differentiates from the collection/stop siblings by naming them as separate steps keyed to this output.

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 tells the agent what to do after this call (persist details.token_id for prepare_twamm_order_collection and prepare_twamm_order_stop), which implies this is the entry point of an ordering workflow. But it gives no explicit selection guidance against other order-related siblings such as prepare_twamm_virtual_orders, and no prerequisites (e.g., token approvals already needed, chain support) are stated.

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.