Skip to main content
Glama

write_account_automations

Idempotent

Configure an account's automations from a list of intents and return the unsigned setAssetManagers transaction. The backend resolves which asset managers each intent needs, validates that the combination is compatible, encodes the metadata and builds the calldata, so you describe the desired outcome rather than the contracts.

With mode 'save' (the default) the intents array is the complete desired state: the backend diffs it against what is currently enabled, so any automation you leave out is DISABLED by the returned transaction. Pass a single intent with enabled: false to turn everything off.

Mode 'preview' validates and resolves the intents WITHOUT reading chain state and returns no transaction, because its calldata carries no disable entries and would only partially apply the state. Use it to check a combination is legal or to show a plan; use 'save' to get something signable. To toggle one automation without restating the rest, use write_account_automations_delta.

Intents:

  • compound_fees: reinvest earned fees/rewards back into the LP. Optional 'tokens' scopes it per yielding token. A staked reward that is not a pool token is swapped in via CowSwap automatically.

  • claim_rewards: claim yield out. config.mode as_earned pays the tokens as-is, convert_to swaps them to config.buy_token via CowSwap. config.convert_tokens converts only a subset and claims the rest as-earned. config.destination account or wallet.

  • add_to_lp: fold idle pool-token balances (deposits, rebalance leftovers) back into the LP. Opt-in per token.

  • claim_merkl: auto-claim Merkl incentive rewards. Independent of the compounder/claimer/cowswapper triad and needs no position context.

  • rebalance: reposition the LP. strategy out_of_range (default), take_profit (runs on the dedicated profit-taker contract), or protocol_owned_liquidity.

Pass position_id (from assets[] in read_account_info) and the backend fills in protocol, is_staked, token0, token1 and reward_tokens for you; anything you pass explicitly wins. claim_merkl needs no position context.

Rules the backend enforces (a violation is returned as an error, never written on-chain):

  • Every yielding token must be assigned to exactly one of compound_fees or claim_rewards. Scoping one to a subset without covering the rest is rejected, and no token may be in both.

  • A wallet or custom-recipient payout requires a pure as-earned claim: nothing converted, and every yielding token claimed. Converts settle in the account.

  • convert_tokens must be a subset of the claimed tokens, and buy_token cannot be a compounded token, a converted token, or an add_to_lp folded token.

  • Each intent kind may appear only once, and a token list must not be empty or name a token the position does not yield.

Returns { valid, errors, warnings, human_summary, plan, diff, transaction }. When a compatibility rule fires the call returns an error and no transaction: read errors[].reason, adjust the intents and retry. There is deliberately no transaction when the account already matches the request (no_changes_needed), when the Tenderly simulation predicts a revert (an error), or in preview mode (preview_only). Call read_asset_manager_intents first to see which intents this account can enable.

Input Schema

NameRequiredDescriptionDefault
modeNosave diffs against on-chain state and returns a signable transaction that also disables anything omitted. preview resolves and validates only, returning a plan and no transaction.save
ownerNoAccount owner EOA. Used to resolve wallet payout targets.
token0NoPool token0 address.
token1NoPool token1 address.
intentsYesComplete desired automation state. In save mode anything omitted is disabled, so include every automation to keep. A single intent with enabled: false disables all automations.
chain_idNoChain ID: 8453 (Base), 130 (Unichain), 10 (Optimism), or 4663 (Robinhood)
protocolNoPosition's DEX protocol. Only needed when position_id is omitted. Accepts the dex_protocol values the read tools return (slipstream, staked_slipstream_v3, uniV3, metadexcl_v1, staked_metadexcl_v1, ...), which imply is_staked, as well as the canonical slipstream_v1 / uniswap_v3 spellings. metadexcl_v1 is Aero CL; staked_metadexcl_v1 covers both the staked module and the wrapper.
is_stakedNoWhether the LP position is staked. Implied by a staked_* protocol value.
position_idNoLP position (NFT) id, as listed in assets[] by read_account_info. Supply this and the backend fetches protocol, staked flag, tokens and reward tokens for you. Strongly preferred over passing the position fields by hand.
reward_tokensNoStaking reward token addresses.
account_addressYesArcadia account address

Output Schema

NameRequiredDescriptionDefault
diffNo
planYes
validYes
errorsYes
warningsYes
descriptionYes
transactionNo
preview_onlyNo
human_summaryYes
simulation_urlNo
no_changes_neededNo
tenderly_sim_statusNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed20 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • removedInput schema / properties / intents / items / anyOf
      Removed value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "enabled": {
      -        "default": true,
      -        "description": "False disables this intent's managers instead of enabling them.",
      -        "type": "boolean"
      -      },
      -      "kind": {
      -        "const": "compound_fees",
      -        "type": "string"
      -      },
      -      "position_id": {
      -        "description": "LP position (NFT) id this intent applies to. Also used to auto-fetch position context.",
      -        "type": "integer"
      -      },
      -      "tokens": {
      -        "description": "Which tokens' yield to reinvest. Omit for all yielding tokens. 'reward' only exists on a staked position whose reward token is not a pool token. Every yielding token must be assigned to either compound_fees or claim_rewards, so if you scope this to a subset you must add a claim_rewards intent covering the rest.",
      -        "items": {
      -          "enum": [
      -            "token0",
      -            "token1",
      -            "reward"
      -          ],
      -          "type": "string"
      -        },
      -        "type": "array"
      -      }
      -    },
      -    "required": [
      -      "kind"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "config": {
      -        "additionalProperties": false,
      -        "default": {},
      -        "properties": {
      -          "buy_token": {
      -            "description": "ERC20 to swap into. Required whenever any token is being converted. It cannot be a token you also compound, one of the tokens being converted, or a token folded by add_to_lp.",
      -            "type": "string"
      -          },
      -          "convert_tokens": {
      -            "description": "Subset of this intent's claimed tokens to swap to buy_token; the rest are claimed as-earned. Must be a subset of `tokens`. Omit to defer to mode (convert_to converts all claimed tokens, as_earned converts none). Use this for a partial convert, e.g. tokens: ['token0','reward'] with convert_tokens: ['reward'] swaps only the reward and claims token0 as-is.",
      -            "items": {
      -              "$ref": "#/properties/intents/items/anyOf/0/properties/tokens/items"
      -            },
      -            "type": "array"
      -          },
      -          "destination": {
      -            "default": "account",
      -            "description": "Payout target ('wallet' is the owner EOA). A wallet payout is only allowed for a pure as-earned claim: nothing converted, and every yielding token claimed. Any convert, or a claim scoped to a subset of tokens, must use 'account' because CowSwap settles there.",
      -            "enum": [
      -              "account",
      -              "wallet"
      -            ],
      -            "type": "string"
      -          },
      -          "mode": {
      -            "default": "as_earned",
      -            "description": "as_earned pays out the claimed tokens as-is; convert_to swaps them to buy_token via CowSwap. Use convert_tokens to convert only some of them.",
      -            "enum": [
      -              "as_earned",
      -              "convert_to"
      -            ],
      -            "type": "string"
      -          },
      -          "recipient": {
      -            "description": "Explicit payout address. Overrides destination when set, and is subject to the same pure-as-earned rule as a wallet payout unless it equals the account address.",
      -            "type": "string"
      -          },
      -          "tokens": {
      -            "description": "Which tokens' yield to claim out. Omit for all yielding tokens. A token cannot be both claimed and compounded, and every yielding token must be assigned to one of the two.",
      -            "items": {
      -              "$ref": "#/properties/intents/items/anyOf/0/properties/tokens/items"
      -            },
      -            "type": "array"
      -          }
      -        },
      -        "type": "object"
      -      },
      -      "enabled": {
      -        "$ref": "#/properties/intents/items/anyOf/0/properties/enabled"
      -      },
      -      "kind": {
      -        "const": "claim_rewards",
      -        "type": "string"
      -      },
      -      "position_id": {
      -        "$ref": "#/properties/intents/items/anyOf/0/properties/position_id"
      -      }
      -    },
      -    "required": [
      -      "kind"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "enabled": {
      -        "$ref": "#/properties/intents/items/anyOf/0/properties/enabled"
      -      },
      -      "kind": {
      -        "const": "add_to_lp",
      -        "type": "string"
      -      },
      -      "position_id": {
      -        "$ref": "#/properties/intents/items/anyOf/0/properties/position_id"
      -      },
      -      "tokens": {
      -        "description": "Which pool tokens' idle account balance to fold into the LP. Omit for both. Folding is opt-in per token, and a folded token cannot be the buy_token of a claim_rewards convert.",
      -        "items": {
      -          "enum": [
      -            "token0",
      -            "token1"
      -          ],
      -          "type": "string"
      -        },
      -        "type": "array"
      -      }
      -    },
      -    "required": [
      -      "kind"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "config": {
      -        "additionalProperties": false,
      -        "default": {},
      -        "properties": {
      -          "destination": {
      -            "default": "account",
      -            "enum": [
      -              "account",
      -              "wallet"
      -            ],
      -            "type": "string"
      -          },
      -          "reward_recipient": {
      -            "description": "Explicit recipient address. Overrides destination when set.",
      -            "type": "string"
      -          }
      -        },
      -        "type": "object"
      -      },
      -      "enabled": {
      -        "$ref": "#/properties/intents/items/anyOf/0/properties/enabled"
      -      },
      -      "kind": {
      -        "const": "claim_merkl",
      -        "type": "string"
      -      },
      -      "position_id": {
      -        "$ref": "#/properties/intents/items/anyOf/0/properties/position_id"
      -      }
      -    },
      -    "required": [
      -      "kind"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "enabled": {
      -        "$ref": "#/properties/intents/items/anyOf/0/properties/enabled"
      -      },
      -      "kind": {
      -        "const": "rebalance",
      -        "type": "string"
      -      },
      -      "max_tolerance": {
      -        "description": "Max price deviation (MEV/slippage cap), 1e18-scaled: 1e18 = 100%, so 5000000000000000 = 0.5% (the default) and 50000000000000000 = 5%. Omit for the pool's default. AAA pools are floored at 5%.",
      -        "maximum": 1000000000000000000,
      -        "minimum": 0,
      -        "type": "integer"
      -      },
      -      "min_liquidity_ratio": {
      -        "description": "Min fraction of liquidity that must survive a rebalance, 1e18-scaled: 990000000000000000 = 99% (the default), i.e. at most 1% value loss. Omit for the default.",
      -        "maximum": 1000000000000000000,
      -        "minimum": 0,
      -        "type": "integer"
      -      },
      -      "position_id": {
      -        "$ref": "#/properties/intents/items/anyOf/0/properties/position_id"
      -      },
      -      "strategy": {
      -        "anyOf": [
      -          {
      -            "additionalProperties": false,
      -            "properties": {
      -              "kind": {
      -                "const": "out_of_range",
      -                "type": "string"
      -              },
      -              "max_rebalance_time": {
      -                "default": 1000000000000,
      -                "description": "Seconds before a rebalance is forced. Default is effectively disabled.",
      -                "type": "integer"
      -              },
      -              "min_rebalance_time": {
      -                "default": 3600,
      -                "description": "Cooldown in seconds between rebalances.",
      -                "type": "integer"
      -              },
      -              "optimal_token0_ratio": {
      -                "default": 500000,
      -                "description": "Target token0 composition after a rebalance, 1e6-scaled: 500000 = 50% (balanced, the default), 750000 = 75% token0, 0 = all token1.",
      -                "maximum": 1000000,
      -                "minimum": 0,
      -                "type": "integer"
      -              },
      -              "trigger_lower_tick_ratio": {
      -                "default": 0,
      -                "description": "Offset from tick_lower as a fraction of the position's tick range, 1e6-scaled. This is TICK distance, not price: 50000 shifts the trigger by 5% of (tick_upper - tick_lower) ticks, which is not 5% of price. 0 = trigger exactly at the boundary. Positive (e.g. 50000) puts the trigger outside the position so price must travel further beyond the range before rebalancing. Negative (e.g. -50000) puts it inside, firing preemptively while price is still in range.",
      -                "type": "integer"
      -              },
      -              "trigger_upper_tick_ratio": {
      -                "default": 0,
      -                "description": "Same as trigger_lower_tick_ratio, for tick_upper. The two are independent, so asymmetric configs are valid (e.g. lower -50000, upper 0 rebalances early on the downside but only at the boundary on the upside).",
      -                "type": "integer"
      -              }
      -            },
      -            "required": [
      -              "kind"
      -            ],
      -            "type": "object"
      -          },
      -          {
      -            "additionalProperties": false,
      -            "properties": {
      -              "base_range": {
      -                "default": 50000,
      -                "type": "integer"
      -              },
      -              "deadzone": {
      -                "default": 20000,
      -                "type": "integer"
      -              },
      -              "fraction_excess_to_limit_order": {
      -                "default": 500000,
      -                "type": "integer"
      -              },
      -              "initial_range": {
      -                "default": 200000,
      -                "type": "integer"
      -              },
      -              "k1": {
      -                "default": 0,
      -                "type": "integer"
      -              },
      -              "k2": {
      -                "default": 0,
      -                "type": "integer"
      -              },
      -              "kind": {
      -                "const": "protocol_owned_liquidity",
      -                "type": "string"
      -              },
      -              "limit_order_withdrawal_threshold": {
      -                "default": 50000,
      -                "type": "integer"
      -              },
      -              "rebalance_threshold": {
      -                "default": 25000,
      -                "type": "integer"
      -              },
      -              "target_token0_ratio": {
      -                "default": 500000,
      -                "type": "integer"
      -              }
      -            },
      -            "required": [
      -              "kind"
      -            ],
      -            "type": "object"
      -          },
      -          {
      -            "additionalProperties": false,
      -            "properties": {
      -              "has_reversal": {
      -                "default": false,
      -                "type": "boolean"
      -              },
      -              "kind": {
      -                "const": "take_profit",
      -                "type": "string"
      -              },
      -              "profit_token": {
      -                "default": "token0",
      -                "enum": [
      -                  "token0",
      -                  "token1"
      -                ],
      -                "type": "string"
      -              },
      -              "reversal_reposition_mode": {
      -                "default": "",
      -                "enum": [
      -                  "",
      -                  "anchor_tick",
      -                  "shift_range"
      -                ],
      -                "type": "string"
      -              },
      -              "reversal_trigger_threshold": {
      -                "default": 0,
      -                "type": "integer"
      -              },
      -              "reversal_trigger_type": {
      -                "default": "",
      -                "enum": [
      -                  "",
      -                  "fixed",
      -                  "relative"
      -                ],
      -                "type": "string"
      -              },
      -              "take_profit_reposition_mode": {
      -                "default": "anchor_tick",
      -                "enum": [
      -                  "",
      -                  "anchor_tick",
      -                  "shift_range"
      -                ],
      -                "type": "string"
      -              },
      -              "take_profit_trigger_threshold": {
      -                "default": 0,
      -                "type": "integer"
      -              },
      -              "take_profit_trigger_type": {
      -                "default": "fixed",
      -                "enum": [
      -                  "",
      -                  "fixed",
      -                  "relative"
      -                ],
      -                "type": "string"
      -              }
      -            },
      -            "required": [
      -              "kind"
      -            ],
      -            "type": "object"
      -          }
      -        ],
      -        "default": {
      -          "kind": "out_of_range"
      -        },
      -        "description": "out_of_range repositions when price leaves the range; take_profit runs on the dedicated profit-taker contract; protocol_owned_liquidity is the POL strategy."
      -      }
      -    },
      -    "required": [
      -      "kind"
      -    ],
      -    "type": "object"
      -  }
      -]
    • addedInput schema / properties / intents / items / oneOf
      Added value: +[
      +  {
      +    "properties": {
      +      "enabled": {
      +        "default": true,
      +        "description": "False disables this intent's managers instead of enabling them.",
      +        "type": "boolean"
      +      },
      +      "kind": {
      +        "const": "compound_fees",
      +        "type": "string"
      +      },
      +      "position_id": {
      +        "description": "LP position (NFT) id this intent applies to. Also used to auto-fetch position context.",
      +        "maximum": 9007199254740991,
      +        "minimum": -9007199254740991,
      +        "type": "integer"
      +      },
      +      "tokens": {
      +        "description": "Which tokens' yield to reinvest. Omit for all yielding tokens. 'reward' only exists on a staked position whose reward token is not a pool token. Every yielding token must be assigned to either compound_fees or claim_rewards, so if you scope this to a subset you must add a claim_rewards intent covering the rest.",
      +        "items": {
      +          "enum": [
      +            "token0",
      +            "token1",
      +            "reward"
      +          ],
      +          "type": "string"
      +        },
      +        "type": "array"
      +      }
      +    },
      +    "required": [
      +      "kind"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "properties": {
      +      "config": {
      +        "default": {},
      +        "properties": {
      +          "buy_token": {
      +            "description": "ERC20 to swap into. Required whenever any token is being converted. It cannot be a token you also compound, one of the tokens being converted, or a token folded by add_to_lp.",
      +            "type": "string"
      +          },
      +          "convert_tokens": {
      +            "description": "Subset of this intent's claimed tokens to swap to buy_token; the rest are claimed as-earned. Must be a subset of `tokens`. Omit to defer to mode (convert_to converts all claimed tokens, as_earned converts none). Use this for a partial convert, e.g. tokens: ['token0','reward'] with convert_tokens: ['reward'] swaps only the reward and claims token0 as-is.",
      +            "items": {
      +              "enum": [
      +                "token0",
      +                "token1",
      +                "reward"
      +              ],
      +              "type": "string"
      +            },
      +            "type": "array"
      +          },
      +          "destination": {
      +            "default": "account",
      +            "description": "Payout target ('wallet' is the owner EOA). A wallet payout is only allowed for a pure as-earned claim: nothing converted, and every yielding token claimed. Any convert, or a claim scoped to a subset of tokens, must use 'account' because CowSwap settles there.",
      +            "enum": [
      +              "account",
      +              "wallet"
      +            ],
      +            "type": "string"
      +          },
      +          "mode": {
      +            "default": "as_earned",
      +            "description": "as_earned pays out the claimed tokens as-is; convert_to swaps them to buy_token via CowSwap. Use convert_tokens to convert only some of them.",
      +            "enum": [
      +              "as_earned",
      +              "convert_to"
      +            ],
      +            "type": "string"
      +          },
      +          "recipient": {
      +            "description": "Explicit payout address. Overrides destination when set, and is subject to the same pure-as-earned rule as a wallet payout unless it equals the account address.",
      +            "type": "string"
      +          },
      +          "tokens": {
      +            "description": "Which tokens' yield to claim out. Omit for all yielding tokens. A token cannot be both claimed and compounded, and every yielding token must be assigned to one of the two.",
      +            "items": {
      +              "enum": [
      +                "token0",
      +                "token1",
      +                "reward"
      +              ],
      +              "type": "string"
      +            },
      +            "type": "array"
      +          }
      +        },
      +        "type": "object"
      +      },
      +      "enabled": {
      +        "default": true,
      +        "description": "False disables this intent's managers instead of enabling them.",
      +        "type": "boolean"
      +      },
      +      "kind": {
      +        "const": "claim_rewards",
      +        "type": "string"
      +      },
      +      "position_id": {
      +        "description": "LP position (NFT) id this intent applies to. Also used to auto-fetch position context.",
      +        "maximum": 9007199254740991,
      +        "minimum": -9007199254740991,
      +        "type": "integer"
      +      }
      +    },
      +    "required": [
      +      "kind"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "properties": {
      +      "enabled": {
      +        "default": true,
      +        "description": "False disables this intent's managers instead of enabling them.",
      +        "type": "boolean"
      +      },
      +      "kind": {
      +        "const": "add_to_lp",
      +        "type": "string"
      +      },
      +      "position_id": {
      +        "description": "LP position (NFT) id this intent applies to. Also used to auto-fetch position context.",
      +        "maximum": 9007199254740991,
      +        "minimum": -9007199254740991,
      +        "type": "integer"
      +      },
      +      "tokens": {
      +        "description": "Which pool tokens' idle account balance to fold into the LP. Omit for both. Folding is opt-in per token, and a folded token cannot be the buy_token of a claim_rewards convert.",
      +        "items": {
      +          "enum": [
      +            "token0",
      +            "token1"
      +          ],
      +          "type": "string"
      +        },
      +        "type": "array"
      +      }
      +    },
      +    "required": [
      +      "kind"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "properties": {
      +      "config": {
      +        "default": {},
      +        "properties": {
      +          "destination": {
      +            "default": "account",
      +            "enum": [
      +              "account",
      +              "wallet"
      +            ],
      +            "type": "string"
      +          },
      +          "reward_recipient": {
      +            "description": "Explicit recipient address. Overrides destination when set.",
      +            "type": "string"
      +          }
      +        },
      +        "type": "object"
      +      },
      +      "enabled": {
      +        "default": true,
      +        "description": "False disables this intent's managers instead of enabling them.",
      +        "type": "boolean"
      +      },
      +      "kind": {
      +        "const": "claim_merkl",
      +        "type": "string"
      +      },
      +      "position_id": {
      +        "description": "LP position (NFT) id this intent applies to. Also used to auto-fetch position context.",
      +        "maximum": 9007199254740991,
      +        "minimum": -9007199254740991,
      +        "type": "integer"
      +      }
      +    },
      +    "required": [
      +      "kind"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "properties": {
      +      "enabled": {
      +        "default": true,
      +        "description": "False disables this intent's managers instead of enabling them.",
      +        "type": "boolean"
      +      },
      +      "kind": {
      +        "const": "rebalance",
      +        "type": "string"
      +      },
      +      "max_tolerance": {
      +        "description": "Max price deviation (MEV/slippage cap), 1e18-scaled: 1e18 = 100%, so 5000000000000000 = 0.5% (the default) and 50000000000000000 = 5%. Omit for the pool's default. AAA pools are floored at 5%.",
      +        "maximum": 1000000000000000000,
      +        "minimum": 0,
      +        "multipleOf": 1,
      +        "type": "number"
      +      },
      +      "min_liquidity_ratio": {
      +        "description": "Min fraction of liquidity that must survive a rebalance, 1e18-scaled: 990000000000000000 = 99% (the default), i.e. at most 1% value loss. Omit for the default.",
      +        "maximum": 1000000000000000000,
      +        "minimum": 0,
      +        "multipleOf": 1,
      +        "type": "number"
      +      },
      +      "position_id": {
      +        "description": "LP position (NFT) id this intent applies to. Also used to auto-fetch position context.",
      +        "maximum": 9007199254740991,
      +        "minimum": -9007199254740991,
      +        "type": "integer"
      +      },
      +      "strategy": {
      +        "default": {
      +          "kind": "out_of_range"
      +        },
      +        "description": "out_of_range repositions when price leaves the range; take_profit runs on the dedicated profit-taker contract; protocol_owned_liquidity is the POL strategy.",
      +        "oneOf": [
      +          {
      +            "properties": {
      +              "kind": {
      +                "const": "out_of_range",
      +                "type": "string"
      +              },
      +              "max_rebalance_time": {
      +                "default": 1000000000000,
      +                "description": "Seconds before a rebalance is forced. Default is effectively disabled.",
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "min_rebalance_time": {
      +                "default": 3600,
      +                "description": "Cooldown in seconds between rebalances.",
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "optimal_token0_ratio": {
      +                "default": 500000,
      +                "description": "Target token0 composition after a rebalance, 1e6-scaled: 500000 = 50% (balanced, the default), 750000 = 75% token0, 0 = all token1.",
      +                "maximum": 1000000,
      +                "minimum": 0,
      +                "type": "integer"
      +              },
      +              "trigger_lower_tick_ratio": {
      +                "default": 0,
      +                "description": "Offset from tick_lower as a fraction of the position's tick range, 1e6-scaled. This is TICK distance, not price: 50000 shifts the trigger by 5% of (tick_upper - tick_lower) ticks, which is not 5% of price. 0 = trigger exactly at the boundary. Positive (e.g. 50000) puts the trigger outside the position so price must travel further beyond the range before rebalancing. Negative (e.g. -50000) puts it inside, firing preemptively while price is still in range.",
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "trigger_upper_tick_ratio": {
      +                "default": 0,
      +                "description": "Same as trigger_lower_tick_ratio, for tick_upper. The two are independent, so asymmetric configs are valid (e.g. lower -50000, upper 0 rebalances early on the downside but only at the boundary on the upside).",
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              }
      +            },
      +            "required": [
      +              "kind"
      +            ],
      +            "type": "object"
      +          },
      +          {
      +            "properties": {
      +              "base_range": {
      +                "default": 50000,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "deadzone": {
      +                "default": 20000,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "fraction_excess_to_limit_order": {
      +                "default": 500000,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "initial_range": {
      +                "default": 200000,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "k1": {
      +                "default": 0,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "k2": {
      +                "default": 0,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "kind": {
      +                "const": "protocol_owned_liquidity",
      +                "type": "string"
      +              },
      +              "limit_order_withdrawal_threshold": {
      +                "default": 50000,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "rebalance_threshold": {
      +                "default": 25000,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "target_token0_ratio": {
      +                "default": 500000,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              }
      +            },
      +            "required": [
      +              "kind"
      +            ],
      +            "type": "object"
      +          },
      +          {
      +            "properties": {
      +              "has_reversal": {
      +                "default": false,
      +                "type": "boolean"
      +              },
      +              "kind": {
      +                "const": "take_profit",
      +                "type": "string"
      +              },
      +              "profit_token": {
      +                "default": "token0",
      +                "enum": [
      +                  "token0",
      +                  "token1"
      +                ],
      +                "type": "string"
      +              },
      +              "reversal_reposition_mode": {
      +                "default": "",
      +                "enum": [
      +                  "",
      +                  "anchor_tick",
      +                  "shift_range"
      +                ],
      +                "type": "string"
      +              },
      +              "reversal_trigger_threshold": {
      +                "default": 0,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "reversal_trigger_type": {
      +                "default": "",
      +                "enum": [
      +                  "",
      +                  "fixed",
      +                  "relative"
      +                ],
      +                "type": "string"
      +              },
      +              "take_profit_reposition_mode": {
      +                "default": "anchor_tick",
      +                "enum": [
      +                  "",
      +                  "anchor_tick",
      +                  "shift_range"
      +                ],
      +                "type": "string"
      +              },
      +              "take_profit_trigger_threshold": {
      +                "default": 0,
      +                "maximum": 9007199254740991,
      +                "minimum": -9007199254740991,
      +                "type": "integer"
      +              },
      +              "take_profit_trigger_type": {
      +                "default": "fixed",
      +                "enum": [
      +                  "",
      +                  "fixed",
      +                  "relative"
      +                ],
      +                "type": "string"
      +              }
      +            },
      +            "required": [
      +              "kind"
      +            ],
      +            "type": "object"
      +          }
      +        ]
      +      }
      +    },
      +    "required": [
      +      "kind"
      +    ],
      +    "type": "object"
      +  }
      +]
    • changedInput schema / properties / position_id / description
      Previous value: -"LP position (NFT) id, as listed in assets[] by read.account.info. Supply this and the backend fetches protocol, staked flag, tokens and reward tokens for you. Strongly preferred over passing the position fields by hand."New value: +"LP position (NFT) id, as listed in assets[] by read_account_info. Supply this and the backend fetches protocol, staked flag, tokens and reward tokens for you. Strongly preferred over passing the position fields by hand."
    • addedInput schema / properties / position_id / maximum
      Added value: +9007199254740991
    • addedInput schema / properties / position_id / minimum
      Added value: +-9007199254740991
    • changedInput schema / properties / protocol / description
      Previous value: -"Position's DEX protocol. Only needed when position_id is omitted. Accepts the dex_protocol values the read tools return (slipstream, staked_slipstream_v3, uniV3, ...), which imply is_staked, as well as the canonical slipstream_v1 / uniswap_v3 spellings."New value: +"Position's DEX protocol. Only needed when position_id is omitted. Accepts the dex_protocol values the read tools return (slipstream, staked_slipstream_v3, uniV3, metadexcl_v1, staked_metadexcl_v1, ...), which imply is_staked, as well as the canonical slipstream_v1 / uniswap_v3 spellings. metadexcl_v1 is Aero CL; staked_metadexcl_v1 covers both the staked module and the wrapper."
    • changedInput schema / properties / protocol / enum
      Previous value: -[
      -  "slipstream_v1",
      -  "slipstream_v2",
      -  "slipstream_v3",
      -  "uniswap_v3",
      -  "uniswap_v4",
      -  "slipstream",
      -  "staked_slipstream",
      -  "staked_slipstream_v2",
      -  "staked_slipstream_v3",
      -  "uniV3",
      -  "uniV4"
      -]New value: +[
      +  "slipstream_v1",
      +  "slipstream_v2",
      +  "slipstream_v3",
      +  "uniswap_v3",
      +  "uniswap_v4",
      +  "metadexcl_v1",
      +  "slipstream",
      +  "staked_slipstream",
      +  "staked_slipstream_v2",
      +  "staked_slipstream_v3",
      +  "uniV3",
      +  "uniV4",
      +  "staked_metadexcl_v1"
      +]
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedOutput schema / properties / diff / properties / removed / items / $ref
      Removed value: -"#/properties/diff/properties/added/items"
    • addedOutput schema / properties / diff / properties / removed / items / additionalProperties
      Added value: +false
    • addedOutput schema / properties / diff / properties / removed / items / properties
      Added value: +{
      +  "address": {
      +    "type": "string"
      +  },
      +  "enabled": {
      +    "type": "boolean"
      +  },
      +  "manager": {
      +    "type": "string"
      +  }
      +}
    • addedOutput schema / properties / diff / properties / removed / items / required
      Added value: +[
      +  "manager",
      +  "address",
      +  "enabled"
      +]
    • addedOutput schema / properties / diff / properties / removed / items / type
      Added value: +"object"
    • removedOutput schema / properties / diff / properties / updated / items / $ref
      Removed value: -"#/properties/diff/properties/added/items"
    • addedOutput schema / properties / diff / properties / updated / items / additionalProperties
      Added value: +false
    • addedOutput schema / properties / diff / properties / updated / items / properties
      Added value: +{
      +  "address": {
      +    "type": "string"
      +  },
      +  "enabled": {
      +    "type": "boolean"
      +  },
      +  "manager": {
      +    "type": "string"
      +  }
      +}
    • addedOutput schema / properties / diff / properties / updated / items / required
      Added value: +[
      +  "manager",
      +  "address",
      +  "enabled"
      +]
    • addedOutput schema / properties / diff / properties / updated / items / type
      Added value: +"object"
  2. Changed1 schema field changed
    • changedInput schema / properties / chain_id / description
      Previous value: -"Chain ID: 8453 (Base), 130 (Unichain), or 10 (Optimism)"New value: +"Chain ID: 8453 (Base), 130 (Unichain), 10 (Optimism), or 4663 (Robinhood)"
  3. Added

TDQS

A4.8/5.0
Behavior5/5

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

Goes well past the annotations by disclosing the key footgun that the intents array is a full desired state and anything omitted is DISABLED, plus that a single enabled:false turns everything off. It also enumerates the backend-enforced compatibility rules, the error-first behavior (errors[].reason, adjust and retry), and the three cases that deliberately return no transaction (no_changes_needed, simulated revert, preview_only). Only note: destructiveHint=false arguably understates a call that removes automations, but the description itself surfaces that risk.

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?

Long but front-loaded: the core action and the save/preview distinction come first, then intents, then validation rules, then return behavior. Every block is substantive, but several rules (token assignment, recipient/convert restrictions) are restated from the schema, which is some avoidable length.

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 complex 11-parameter mutation with nested intent unions it covers everything an agent needs: intent semantics, mode trade-offs, autofill behavior, validation failures, and the returned { valid, errors, warnings, human_summary, plan, diff, transaction } shape, which reinforces rather than replaces the output schema.

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 earns more by explaining what each intent kind means (compound_fees, claim_rewards, add_to_lp, claim_merkl, rebalance), what position_id auto-fills (protocol, is_staked, token0/token1, reward_tokens), and the cross-intent constraints. Some of that overlaps the already-detailed schema descriptions, which caps it below 5.

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?

Opens with a specific verb and resource: "Configure an account's automations from a list of intents and return the unsigned setAssetManagers transaction." It immediately separates itself from write_account_automations_delta (delta toggling) and read_asset_manager_intents (capability discovery), so an agent can pick 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?

Explicitly states when to use 'save' (something signable) versus 'preview' (validate/show a plan, no transaction, does not read chain state), and when to switch to write_account_automations_delta for a single toggle. It also prescribes a prerequisite: call read_asset_manager_intents first to see what the account can enable.

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.