Skip to main content
Glama

write_account_aero_upgrade

Idempotent

Upgrade one Arcadia account to Aero (MetadexCL V1) in one flashAction: every Slipstream V1/V2/V3 position (dex_protocol slipstream*, staked or not, see read_account_info) moves to the Aero CL pool with the same pair and variant at the same range and tick spacing (when Aero has no pool at that tick spacing, the user picks another one), and every unit of old AERO (loose, in rewards, in an old-AERO pair) becomes the new AERO. Returns the plan and, when anything can go now, the unsigned transaction. Only the account owner can sign it. The backend decides what moves: report items[].status and items[].reason as given, never decide eligibility yourself. status ready: sign transaction. choices_required: some position has status choose with options[] (every Aero pool on its pair, with apy, tvl_usd, is_new, tick_spacing, range_widened, default and disabled_reason); ask the user to pick one whose disabled_reason is null, then call again with it in choices so one transaction moves everything. The transaction returned with choices_required moves only the ready items: sign it alone only when the user wants to leave the choose positions where they are. waiting: each item's reason says why (pool_not_on_aero, staking_not_open, target_price_mismatch, account_unhealthy, ...); a waiting item with an option whose disabled_reason is null can still move with that pick, so ask the user; do not retry in a loop. not_open: the AERO upgrade contract does not accept deposits at the moment. A 422 saying a pool is not selectable: drop that pick, call again without it and ask the user again. Pass accounts (up to 10) instead of account_address for one plan per account; the accounts share one AERO upgrade budget. multisends groups the accounts that got a transaction, in order: a Safe signs one MultiSend per group (each below max_gas_per_tx). After it confirms, reconnect managers_to_reconnect with write_account_automations and verify with read_account_info (next_steps). Spot and margin accounts can hold Aero positions, staked or not. Chains: 8453 (Base, default), 10 (Optimism) and 4663 (Robinhood, which has nothing to upgrade). Calldata is time-sensitive: sign promptly, rebuild on a price revert. After a transaction confirms, pass its block as min_block on the next call so the plan is not built on older state. When the transaction's simulation reverts the tool returns the plan with an error and no transaction; tenderly_sim_status unavailable means Tenderly did not answer: call once more before signing. A plan without a transaction can still show tenderly_sim_status failure: the account's health or a lending pool limit refused the move, and the items wait on account_unhealthy or exposure_limit; report those reasons and do not rebuild.

Input Schema

NameRequiredDescriptionDefault
choicesNoPool picks for positions with status choose (or waiting with a selectable option), from a previous call's options (disabled_reason null)
accountsNoUp to 10 Arcadia accounts of one owner: one plan and transaction each
chain_idNoChain ID: 8453 (Base), 10 (Optimism) or 4663 (Robinhood, nothing to upgrade)
slippageNoPrice band the mint accepts, in bps. Omit for the backend default: 150, or 500 when the owner is a contract (a Safe).
min_blockNoBlock of the transaction you just confirmed, so the plan reads state at or after it
account_addressNoArcadia account to upgrade. Pass this or accounts, not both.

Output Schema

NameRequiredDescriptionDefault
gasNo
errorNo
itemsNo
ownerNo
statusNo
resultsNo
chain_idNo
opens_atNo
multisendsNo
next_stepsYes
descriptionYes
status_noteNo
transactionNo
asset_changesNo
max_gas_per_txNo
account_addressNo
simulation_noteNo
tenderly_sim_urlNo
price_tolerance_bpsNo
tenderly_sim_statusNo
managers_to_reconnectNo
old_managers_still_neededNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.8/5.0
Behavior5/5

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

Annotations only say this is a non-read-only, open-world, non-destructive write; the description adds substantial operational context beyond that: calldata is time-sensitive and must be rebuilt on a price revert, the transaction requires the owner's signature, multisends are grouped under max_gas_per_tx, accounts share one upgrade budget, and simulation failures are surfaced as plan-with-error. It also explains what happens to existing positions and AERO balances rather than leaving state changes implicit.

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?

Purpose and scope are front-loaded in the first sentence, and nearly every subsequent sentence carries an operational rule for a genuinely complex multi-state workflow. It is a dense unbroken block of roughly 350 words with no visual separation of the status branches, which makes it harder to scan than it needs to be.

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

Completeness5/5

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

For a multi-account, multi-state, transaction-building tool, the definition covers the state machine, error branches, chain support, signature ownership, post-confirmation verification via read_account_info, and the meaning of a missing transaction. An output schema exists, yet the description still gives enough detail to act on the plan without needing to inspect it.

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, but the description adds real semantic value: choices must come from a prior call's options with disabled_reason null, accounts yields one plan per account sharing a budget, and min_block should be the block of the just-confirmed transaction. Only slippage's contract-vs-EOA default is left to the schema.

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 opening sentence states a specific verb and resource ('Upgrade one Arcadia account to Aero (MetadexCL V1) in one flashAction') and enumerates exactly what moves: Slipstream positions and old AERO balances. It distinguishes itself from the read-only sibling by pointing at read_account_info for source data, so an agent can route correctly without opening a schema.

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

Usage Guidelines5/5

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

The description gives an explicit decision tree for the backend-reported states (ready / choices_required / waiting / not_open), including what to do with items[].status and items[].reason, when to re-call with choices, when to sign a partial transaction, and the explicit exclusion 'do not retry in a loop'. It also names recovery paths for 422 pool-not-selectable and Tenderly unavailable.

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.