Skip to main content
Glama

write_account_borrow

Idempotent

Build an unsigned transaction to borrow from an Arcadia lending pool against account collateral. NOT needed for leveraged LP: write_account_add_liquidity handles borrowing internally when leverage > 0. Only works with margin accounts (created with a creditor/lending pool). Spot accounts (no creditor) cannot borrow: the tool will validate this and reject. Before borrowing, verify the account has positive free margin via read_account_info: collateral_value must exceed used_margin.

Input Schema

NameRequiredDescriptionDefault
toYesAddress to receive borrowed tokens
amountYesAmount in raw units
chain_idNoChain ID: 8453 (Base), 130 (Unichain), 10 (Optimism), or 4663 (Robinhood)
pool_addressYesLending pool: LP_WETH=0x803ea69c7e87D1d6C86adeB40CB636cC0E6B98E2, LP_USDC=0x3ec4a293Fb906DD2Cd440c20dECB250DeF141dF1, LP_CBBTC=0xa37E9b4369dc20940009030BfbC2088F09645e3B
account_addressYesArcadia account address used as collateral

Output Schema

NameRequiredDescriptionDefault
descriptionYes
transactionYes
predicted_account_addressNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 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
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  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. Changed1 schema field changed
    • changedInput schema / properties / chain_id / description
      Previous value: -"Chain ID: 8453 (Base) or 130 (Unichain)"New value: +"Chain ID: 8453 (Base), 130 (Unichain), or 10 (Optimism)"
  4. Added

TDQS

A4.7/5.0
Behavior4/5

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

Adds real behavioral context beyond the annotations: the output is an unsigned transaction rather than an executed borrow, the tool performs validation and rejects spot accounts, and only margin accounts with a creditor qualify. Annotations already cover safety/idempotency, so this is strong complementary disclosure, though it doesn't mention the subsequent signing/submission step or what happens on insufficient margin beyond rejection.

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?

Four tight sentences, front-loaded with the core action, then exclusions, then prerequisites. Every sentence carries actionable information with no filler or repetition of the schema.

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 transaction-building tool with an output schema and full annotation coverage, the description supplies everything an agent needs: what it builds, which account types qualify, what it rejects, which sibling to use instead, and the pre-call verification step.

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 adds meaning by tying account_address to collateral semantics and referencing the read_account_info fields (collateral_value, used_margin) an agent must check before choosing an amount. It does not add syntax or format detail for amount/pool_address, but the schema handles those.

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: 'Build an unsigned transaction to borrow from an Arcadia lending pool against account collateral.' It immediately differentiates itself from the closest sibling (write_account_add_liquidity) that could otherwise be confused for the same borrowing behavior.

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 NOT to use it ('NOT needed for leveraged LP: write_account_add_liquidity handles borrowing internally when leverage > 0') and names the alternative. It also gives a pre-call workflow: verify positive free margin via read_account_info, with the concrete condition (collateral_value must exceed used_margin).

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.