Skip to main content
Glama

FarmDash Agent OS

execute_perp_order

Destructive

USER_SIGNED requires fresh human approval. BOUNDED_AUTONOMOUS requires a valid owner-signed futures policy, authenticated session, and a local API-wallet signature on every action (operational with zero custody). Compatibility: submit a pre-signed EIP-712 Hyperliquid order after a 60-second parameter-bound research gate. market_ioc is a signed, price-protected IOC limit order with a live 100 bps adverse-price cap, never an unbounded market order; its outcome distinguishes full, partial, and zero fill, and an IOC resting response is unknown/inconsistent. For delegated API wallets, set accountAddress to the venue-verified equity owner used during analysis. FarmDash recovers the exact L1 signer, rejects an agentAddress mismatch, and preflights the owner maxBuilderFee. The signed action must disclose builder f=1 (0.1 bp/0.001% of filled notional), and expiresAt is venue-signed as expiresAfter. Venue nonce authority is network + signer + nonce across account/vault contexts; durable replay control fails closed before submission.

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": {
      "agentAddress": "<agentAddress>",
      "coin": "<coin>",
      "isBuy": "<isBuy>",
      "size": "<size>",
      "price": "<price>",
      "orderType": "<orderType>",
      "signature": "<signature>",
      "nonce": "<nonce>",
      "expiresAt": "<expiresAt>",
      "intentHash": "<intentHash>"
    },
    "name": "execute_perp_order"
  }
}

Input Schema

NameRequiredDescriptionDefault
coinYes
sizeYes
isBuyYes
nonceYes
priceYes
grantIdNo
leverageNo
expiresAtYes
orderTypeYes
sessionIdNo
signatureYes
intentHashYes
reduceOnlyNo
agentAddressYes
sessionTokenNo
signedActionNoIf supplied, must include the signed FarmDash builder term { b: treasury, f: 1 }; f is tenths of a basis point.
executionModeNoUSER_SIGNED
accountAddressNo
executionTrialIdNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.1/5.0
Behavior4/5

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

The description goes well past the annotations (destructiveHint=true, idempotentHint=false) by disclosing the 60-second research gate, the builder fee (f=1, 0.1 bp), the 100 bps adverse-price cap, fill-state outcomes, and fail-closed nonce replay control. This is substantive operational context that the annotations alone would not convey.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single dense block of run-on sentences loaded with undefined jargon (L1 signer, venue-signed, equity owner), and the core purpose is not front-loaded. Information is present but poorly ordered for scanning.

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?

For a destructive, open-world, 19-parameter tool with no output schema, the description covers safety-critical behavior but omits much of what an agent needs: most parameter semantics, error/failure responses, and any description of the returned result beyond fill classification. Adequate for the mode and signing story, incomplete overall.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With only 5% schema description coverage across 19 parameters, the description must carry weight; it clarifies accountAddress (venue-verified equity owner), signedAction (mandatory builder term), expiresAt/expiresAfter mapping, and nonce authority. Many parameters (grantId, sessionId, sessionToken, executionTrialId, intentHash, leverage, reduceOnly) remain unexplained beyond their names, so the compensation is partial.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The actual purpose (submit a pre-signed EIP-712 Hyperliquid perp order through FarmDash) is buried mid-paragraph after two sentences about execution modes, and no sibling such as prepare_perp_order or execute_approved_intent is named as the alternative. An agent can eventually infer the verb and resource, but only by parsing dense jargon.

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 two execution modes are separated with their prerequisites (USER_SIGNED needs fresh human approval; BOUNDED_AUTONOMOUS needs a signed policy, session, and API-wallet signature), which is real conditional guidance. However, there is no explicit statement of when to call this versus prepare_perp_order or execute_approved_intent, and no when-not guidance.

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