mcp-pear
mcp-pear is an MCP server providing access to Pear Protocol pair markets, account data, and trade execution on Hyperliquid.
Public (no auth required):
Check API health and uptime (
get_health)Browse pair markets with filters and pagination (
list_markets)Get top gainers, losers, and highlighted pairs (
get_active_markets)Fetch current pair ratio, 24h change, and funding rate (
get_pair_ratio)
Authenticated Read (requires PEAR_API_KEY and PEAR_ADDRESS or PEAR_JWT):
Account summary — agent wallet, trade counts, pending order values (
get_account_summary)Open positions with entry/mark ratio and unrealized PnL (
get_open_positions)Open limit, TP, and SL orders (
get_open_orders)Active TWAP orders with chunk/fill details (
get_twap_orders)Closed trade history with realized PnL and date filtering (
get_trade_history)Portfolio metrics — bucketed PnL (1d/1w/1m/1y/all-time), volume, open interest (
get_portfolio)Agent wallet address used for signing trades (
get_agent_wallet)
Authenticated Write (requires PEAR_TRADE_ENABLED=true):
Create a new agent wallet (
create_agent_wallet)Open positions (MARKET, TRIGGER, TWAP, etc.) (
open_position)Close a single or all open positions (
close_position,close_all_positions)Adjust position size or leverage (
adjust_position,adjust_leverage)Set stop-loss and take-profit parameters (
set_risk_parameters)Cancel pending limit/TP/SL orders or TWAP orders (
cancel_order,cancel_twap_order)
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-pearshow me the top active markets"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
mcp-pear
The Pear Protocol MCP server for Hyperliquid pair trading — connect Claude, Cursor, or any AI agent to on-chain perps: browse pair markets, read positions and portfolio, and (opt-in) execute pair trades.
Model Context Protocol (MCP) server for Pear Protocol. Gives Claude, or any MCP-compatible agent, access to markets, pair ratios, positions, orders, trade history, portfolio, and (v0.2) full trade execution on Hyperliquid.
v0.2 adds trade execution. Ten write tools (open, close, and adjust positions; manage leverage and risk; cancel orders) are off by default behind
PEAR_TRADE_ENABLED=true. Pear signs server-side, so mcp-pear never holds private keys.
What is Pear Protocol?
Pear is a Hyperliquid-backed perps platform for pair markets: long one basket against another. Every pair has a live ratio that moves as the legs diverge. More at pearprotocol.io.
Related MCP server: CC Trading Terminal
Tools
Public (no auth):
get_health: API health and uptimelist_markets: browse pair markets with filters and paginationget_active_markets: top gainers, losers, and highlighted pairsget_pair_ratio: current ratio, 24h change, and funding for a specific pair
Authenticated read:
get_account_summary: your account headerget_open_positions: your open positions with PnLget_open_orders: your open limit, TP, and SL ordersget_twap_orders: your active TWAP ordersget_trade_history: your closed trades with realized PnLget_portfolio: bucketed PnL across 1d, 1w, 1m, 1y, and all-timeget_agent_wallet: the agent wallet Pear uses to sign your trades
Authenticated write (v0.2, gated behind PEAR_TRADE_ENABLED=true):
create_agent_wallet: create the agent walletopen_position,close_position,close_all_positions: open and close pair positionsadjust_position,adjust_leverage: change size or leverage on a live positionset_risk_parameters: set or update TP and SLcancel_order,cancel_twap_order: cancel pending orders
Full parameter reference in Tool reference. See Trade execution (v0.2) for the gate and Hyperliquid funding rules.
Install
# Run directly
npx -y @marvelcodes/mcp-pear@latest
# Or install globally
pnpm install -g @marvelcodes/mcp-pear
mcp-pearPin
@latest(or a specific version) in the npx spec. Plainnpx @marvelcodes/mcp-pearcan launch a stale cached version: npx prefers its local cache over the npm registry when the spec is unpinned, so after a new release lands you may still be running the old one.@latestre-resolves against the registry each launch; pin like@0.2.0instead if you want a frozen version. Stuck on an old version after upgrading? Clear the npx cache:rm -rf ~/.npm/_npx(macOS/Linux).
Getting an API key
For the authenticated tools, mint a key:
npx -y @marvelcodes/mcp-pear@latest setupThe CLI opens a browser, asks you to sign once with your wallet, mints a Pear API key, and (optionally) writes PEAR_API_KEY and PEAR_ADDRESS to a .env. Copy those two values into your Claude Desktop config and restart Claude.
Already have a JWT from
app.pear.garden? Skipsetupand use JWT pass-through below.
Configuration
Three auth modes. mcp-pear uses the first one whose env vars are set, decided on the first authenticated call.
Mode 1: JWT pass-through (multi-tenant orchestrators)
For Telegram bots and other orchestrators that mint JWTs externally (Privy, EIP-712, or any Pear-supported flow). The JWT is opaque; mcp-pear never calls /auth/login.
Env var | Required | Description |
| yes | Pre-minted access token. Used directly when set. |
| no | If set, mcp-pear refreshes the JWT itself when it expires mid-session (each refresh rotates the token). Without it, the orchestrator has to re-mint and respawn the subprocess. |
When PEAR_JWT expires and no refresh token is set, authenticated tools return:
JWT expired; the orchestrator must mint a new one and restart mcp-pear.
See examples/telegram-bot-usage.ts for the orchestrator pattern.
Mode 2: API key + wallet address (single-user, Claude Desktop)
Env var | Required | Description |
| for auth tools | Your Pear API key. |
| for auth tools | Wallet address bound to the API key ( |
mcp-pear mints the JWT itself by calling POST /auth/login. Both fields are required: the OpenAPI spec needs address in the request body.
Public-only mode
The four public tools work without any auth env vars. Authenticated tools return a ConfigError naming the missing env var.
Common settings (optional)
Env var | Default | Description |
|
| Pear API host. |
|
| Per-request timeout. |
|
| Client identifier sent to |
Claude Desktop
Add to claude_desktop_config.json:
{
"mcpServers": {
"pear": {
"command": "npx",
"args": ["-y", "@marvelcodes/mcp-pear@latest"],
"env": {
"PEAR_API_KEY": "your-pear-api-key-here",
"PEAR_ADDRESS": "0xYourWalletAddress"
}
}
}
}Restart Claude Desktop and ask: "Use Pear to show me the top active markets right now."
ADK-TS
import { McpToolset, StdioTransport } from "@iqai/adk";
const pearTools = new McpToolset({
transport: new StdioTransport({
command: "npx",
args: ["-y", "@marvelcodes/mcp-pear@latest"],
env: { PEAR_API_KEY: process.env.PEAR_API_KEY ?? "", PEAR_ADDRESS: process.env.PEAR_ADDRESS ?? "" },
}),
});
await pearTools.connect();
const tools = await pearTools.listTools();Full example in examples/adk-ts-usage.ts.
Tool reference
adjust_leverage
Change leverage (1-100x) on an existing Pear Protocol position. Higher leverage means greater liquidation risk for the same price move. WRITE: changes risk profile of a live position. Requires PEAR_TRADE_ENABLED=true.
Parameter | Type | Required | Description |
| string | yes | |
| integer | yes |
adjust_position
Reduce or increase an existing Pear Protocol position's size by 1-100 percent. executionType: MARKET (immediate) or LIMIT (provide limitRatio). WRITE: changes exposure on a real trade. Requires PEAR_TRADE_ENABLED=true.
Parameter | Type | Required | Description |
| string | yes | |
| string | yes | |
| integer | yes | |
| string | yes | |
| number | ||
| string |
cancel_order
Cancel a pending Pear Protocol limit, take-profit, or stop-loss order by orderId. Does not affect already-filled portions. For TWAP orders, use cancel_twap_order. WRITE: cancels a live order. Requires PEAR_TRADE_ENABLED=true.
Parameter | Type | Required | Description |
| string | yes |
cancel_twap_order
Cancel a Pear Protocol TWAP (time-weighted average price) order and all of its remaining unfilled chunks. WRITE: cancels a live order. Requires PEAR_TRADE_ENABLED=true.
Parameter | Type | Required | Description |
| string | yes |
close_all_positions
Close every open Pear Protocol position with a single executionType (MARKET or TWAP). Returns a per-position result array with success/error. WRITE: executes real trades. Requires PEAR_TRADE_ENABLED=true.
Parameter | Type | Required | Description |
| string | yes | |
| number | ||
| number | ||
| boolean | ||
| string |
close_position
Close one open Pear Protocol position by positionId. executionType: MARKET (immediate) or TWAP (spread over time; requires twapDuration in seconds). WRITE: executes a real trade. Requires PEAR_TRADE_ENABLED=true.
Parameter | Type | Required | Description |
| string | yes | |
| string | yes | |
| number | ||
| number | ||
| boolean | ||
| string |
create_agent_wallet
Create a new Pear Protocol agent wallet for the authenticated user. The agent wallet is what Pear uses to sign Hyperliquid trades. After creation, the user MUST approve this wallet on Hyperliquid (the response message contains the approval instructions). WRITE: executes a state change. Requires PEAR_TRADE_ENABLED=true.
No parameters
get_account_summary
Get the authenticated user's Pear Protocol account summary: agent wallet address, total closed trades, pending trigger-order USD value, pending TWAP-chunk USD value, and last sync timestamp. Requires PEAR_API_KEY.
No parameters
get_active_markets
Get the most active Pear Protocol pair markets right now: current active pairs plus top gainers, top losers, highlighted pairs, and the user's watchlist. Use to see what's hot or as a starting point for narrowing into a specific pair.
No parameters
get_agent_wallet
Get the authenticated user's Pear Protocol agent wallet address. The agent wallet is what Pear uses to sign Hyperliquid trades on the user's behalf. Returns an empty/missing address if no agent wallet has been created yet; call create_agent_wallet to create one.
No parameters
get_health
Check Pear Protocol API health. Returns service status, server timestamp, and uptime in seconds. Use this to verify the API is reachable before running other tools.
No parameters
get_open_orders
List the authenticated user's open limit, take-profit, and stop-loss orders on Pear Protocol. Returns each order's ID, type, status, and pair composition. Requires PEAR_API_KEY.
No parameters
get_open_positions
List the authenticated user's currently open Pear Protocol pair positions, including position ID, entry ratio, mark ratio, unrealized PnL, and long/short composition. Requires PEAR_API_KEY.
No parameters
get_pair_ratio
Get the current ratio (long/short composition price) for a specific Pear Protocol pair. Pass long and short asset arrays. Returns the ratio, 24h change, and funding rate. Useful when you know the pair you care about and want the latest number.
Parameter | Type | Required | Description |
| array | yes | Asset symbols on the long side (e.g. ['BTC']). |
| array | yes | Asset symbols on the short side. Pass an empty array for long-only baskets. |
get_portfolio
Fetch the authenticated user's full portfolio metrics on Pear Protocol: bucketed PnL across last 1 day / 1 week / 1 month / 1 year / all-time, plus overall stats (total trades, all-time volume, current open interest, unrealized PnL). Requires PEAR_API_KEY.
No parameters
get_trade_history
Fetch the authenticated user's recent closed trades on Pear Protocol with realized PnL, entry/exit ratios, and pair composition. Optional date range and limit. Requires PEAR_API_KEY.
Parameter | Type | Required | Description |
| integer | Max number of trades to return. Default 50. | |
| string | ISO 8601 timestamp or epoch ms. Only return trades on or after this time. | |
| string | ISO 8601 timestamp or epoch ms. Only return trades on or before this time. |
get_twap_orders
List the authenticated user's active TWAP (time-weighted average price) orders on Pear Protocol, including chunk execution and fill detail. Requires PEAR_API_KEY.
No parameters
list_markets
Browse Pear Protocol pair markets with optional filters and pagination. Each market is a long/short composition with current ratio, 24h change, volume, open interest, and funding. Use to discover what's tradable, or with searchText to find a specific pair.
Parameter | Type | Required | Description |
| string | Free-text search across market names (composition keys like `L:BTC | |
| string | Filter by execution engine. | |
| number | Minimum 24h volume in USD. | |
| number | Minimum 24h ratio change (e.g. 0.05 for +5%). | |
| number | Filter by net funding rate. | |
| string | Sort key (e.g. 'volume', 'change24h'). | |
| integer | Page number (1-indexed). | |
| integer | Results per page. Default 20. |
open_position
Open a new pair position on Pear Protocol. Specify executionType (MARKET / TRIGGER / TWAP / LADDER / TP / SL / SYNC), leverage (1-100), usdValue (≥1), slippage (0.001-0.1), and the long/short asset compositions (arrays of { asset, weight }). Optionally attach stopLoss/takeProfit and TWAP/TRIGGER/LADDER parameters. WRITE: executes a real trade. Requires PEAR_TRADE_ENABLED=true.
Parameter | Type | Required | Description |
| string | yes | |
| integer | yes | |
| number | yes | |
| number | yes | |
| array | yes | |
| array | yes | |
| number | ||
| string | ||
| string | ||
| number | ||
| number | ||
| boolean | ||
| object | ||
| unknown | ||
| unknown | ||
| string |
set_risk_parameters
Set or update stop-loss / take-profit on an existing Pear Protocol position. Each threshold has type ('PRICE' or 'PERCENTAGE'), value, and optional trailing fields. Pass null to clear a field; omit it to leave unchanged. WRITE: changes risk parameters on a live position. Requires PEAR_TRADE_ENABLED=true.
Parameter | Type | Required | Description |
| string | yes | |
| unknown | ||
| unknown |
Development
pnpm install
pnpm run build
pnpm test
pnpm run lint
pnpm run formatLive smoke tests:
PEAR_API_KEY=<real> pnpm test smokeTrade execution (v0.2)
Ten new tools that take mcp-pear from read-only to write. All write tools are off by default. Set PEAR_TRADE_ENABLED=true to unlock them (strict literal match on "true"; anything else, including "True", "1", or "yes", keeps writes disabled). Pear signs trades server-side via an agent wallet you create, so mcp-pear never holds private keys for trades.
Tool | Type | Description |
| read | Get the agent wallet Pear uses to sign your trades. |
| write | Create one. After creation, approve it on Hyperliquid (the response message contains the instructions). |
| write | Open a pair position. Supports MARKET, TRIGGER, TWAP, LADDER, TP, SL, SYNC. |
| write | Close one position by id (MARKET or TWAP). |
| write | Close every open position with one execution type. |
| write | Reduce or increase position size by 1 to 100 percent. MARKET or LIMIT. |
| write | Set leverage 1 to 100x on an existing position. Carries liquidation risk. |
| write | Set or update TP and SL on an existing position. |
| write | Cancel a pending limit, TP, or SL order. |
| write | Cancel a TWAP order and its remaining chunks. |
Env var | Default | Description |
| unset | Set to |
When PEAR_TRADE_ENABLED=true, mcp-pear logs [mcp-pear] PEAR_TRADE_ENABLED=true. Trade execution unlocked. to stderr on startup so operators can see writes are live.
Funding and minimums
Trades execute on Hyperliquid, which margins positions from your Perps balance. Two things bite first-time operators:
Minimum order size. Hyperliquid rejects orders below ~$10 notional.
usdValueis the position's USD notional (margin =usdValue / leverage), so a single-leg position needsusdValueat or above 10. A long plus short pair is two separate orders, each subject to the $10 floor (about $20 or more notional total).Spot vs Perps balance. USDC bridged onto Hyperliquid (for example via Circle CCTP) often lands in your Spot balance. Move it to Perps in the Hyperliquid app before trading, or
open_positionfails with insufficient margin.
What's next
v0.3. WebSocket streaming for real-time market and position updates. Spot orders. Candle synthesis from Hyperliquid candleSnapshot.
FAQ
What is the Pear Protocol MCP server?
mcp-pear is a Model Context Protocol (MCP) server that gives Claude and other AI agents access to Pear Protocol — a Hyperliquid-backed platform for pair trading (long one basket against another). It exposes tools to browse pair markets and ratios, read positions, orders, and portfolio, and optionally execute pair trades.
How do I build a Pear Protocol trading agent?
Point any MCP client at npx -y @marvelcodes/mcp-pear@latest. The agent gets read tools out of the box (markets, ratios, positions, portfolio). To let it trade, set PEAR_TRADE_ENABLED=true and add PEAR_API_KEY + PEAR_ADDRESS; it can then call open_position (MARKET / TRIGGER / TWAP / LADDER), close_position, adjust_leverage, and set_risk_parameters. See Claude Desktop and ADK-TS for wiring examples.
Does it support Hyperliquid pair trading?
Yes. Pear runs on Hyperliquid, so every pair position is a long/short perp trade executed on Hyperliquid. mcp-pear covers the full lifecycle: open, adjust, set TP/SL, and close.
Is this the official Pear Protocol MCP server?
No. mcp-pear is an independent, open-source community project that wraps Pear's public API. It is not affiliated with or endorsed by Pear Protocol.
Disclaimer
Not affiliated with Pear Protocol. Independent wrapper around Pear's public API. v0.2 trade-execution tools are off by default and require explicit operator opt-in (PEAR_TRADE_ENABLED=true). Pear signs server-side, so mcp-pear never holds private keys. Use at your own risk; no warranty.
License
MIT. See LICENSE.
Available Tools
20 toolsadjust_leverageA
Change leverage (1-100x) on an existing Pear Protocol position. Higher leverage means greater liquidation risk for the same price move. WRITE: changes risk profile of a live position. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
| positionId | Yes | ||
| leverage | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, description covers write nature and liquidation risk, but lacks disclosure on idempotency, error behavior, or permission requirements beyond the prerequisite.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences plus one line, front-loaded with purpose and range, efficient use of words, no redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple 2-param tool with no output schema, description covers purpose, risk, write nature, and prerequisite. Could mention return value or common errors, but adequate overall.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema has 0% description coverage, so description adds meaning: 'positionId' is existing position, 'leverage' is 1-100x multiplier. Range is clarified, but positionId semantics could be more explicit.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description states specific verb 'change' and resource 'leverage on an existing Pear Protocol position', with range 1-100x. Clearly distinguishes from sibling 'open_position' (new) and 'adjust_position' (general adjustments).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides risk warning and indicates it is a write operation, but does not explicitly state when not to use or compare with alternative tools like 'adjust_position' which might also modify leverage.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
adjust_positionA
Reduce or increase an existing Pear Protocol position's size by 1-100 percent. executionType: MARKET (immediate) or LIMIT (provide limitRatio). WRITE: changes exposure on a real trade. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
| positionId | Yes | ||
| adjustmentType | Yes | ||
| adjustmentSize | Yes | ||
| executionType | Yes | ||
| limitRatio | No | ||
| referralCode | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description must disclose behavior. Notes it is a WRITE operation changing real exposure and mentions execution types. Lacks details on side effects, reversibility, or error conditions, but covers basic behavioral traits.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Extremely concise: one sentence with key details front-loaded. No redundant information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given 6 parameters, no output schema, and no annotations, description could provide more: return value, error handling, rate limits. Covers core action and execution types but lacks completeness for a complex mutation tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so description must add meaning. Explains executionType and implies adjustmentSize is percentage. Does not explain positionId, adjustmentType, limitRatio (meaning of ratio), or referralCode. Adds some value but incomplete.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description explicitly states verb 'Reduce or increase' and resource 'existing Pear Protocol position's size by 1-100 percent'. Clearly distinguishes from sibling tools like close_position (full close) and adjust_leverage (change leverage).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides usage context: executionType choices (MARKET vs LIMIT) and prerequisite env var. Does not explicitly state when not to use or compare with alternatives, but context is clear.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
cancel_orderA
Cancel a pending Pear Protocol limit, take-profit, or stop-loss order by orderId. Does not affect already-filled portions. For TWAP orders, use cancel_twap_order. WRITE: cancels a live order. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
| orderId | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description fully carries the burden. Explicitly states it is a WRITE operation ('cancels a live order') and highlights the environment variable requirement. Also clarifies it does not affect filled portions.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences with no redundancy. Each sentence contributes critical information: action, effect on filled portions, alternative for TWAP, and side effect/requirement. Perfectly front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has only one parameter, no output schema, and no annotations, the description covers all essential aspects: operation, scope, limitations, alternatives, and prerequisites. No gaps for an AI agent to use it correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema has 0% description coverage. The description mentions 'by orderId', giving context that the parameter identifies the order. However, lacks additional details like format or where to obtain the orderId. Still adds meaning beyond the raw schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states it cancels pending Pear Protocol orders (limit, take-profit, stop-loss) by orderId. Distinguishes itself from sibling cancel_twap_order by explicitly saying 'For TWAP orders, use cancel_twap_order'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides explicit when-to-use (cancelling limit, TP, SL orders) and when-not-to-use (TWAP orders). Also notes that already-filled portions are not affected and requires PEAR_TRADE_ENABLED=true.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
cancel_twap_orderA
Cancel a Pear Protocol TWAP (time-weighted average price) order and all of its remaining unfilled chunks. WRITE: cancels a live order. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
| orderId | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It clearly states the tool cancels a live order and its unfilled chunks, revealing its destructive nature. However, it lacks mention of side effects, error conditions, or idempotency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two concise sentences. The first sentence clearly states the purpose, and the second adds essential context. No unnecessary words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (one parameter, no output schema), the description covers the core functionality and a key requirement. It could mention expected outputs or error scenarios, but overall it is adequate.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has one parameter (orderId) with 0% description coverage. The description does not explicitly describe the parameter or its format, leaving the agent to infer its role from context. This is insufficient for a tool with no schema descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states 'Cancel a Pear Protocol TWAP order and all of its remaining unfilled chunks,' specifying a clear verb (Cancel), resource (TWAP order), and scope (all unfilled chunks). It also distinguishes from the sibling tool 'cancel_order' by focusing on TWAP orders.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description mentions it is a WRITE operation and requires PEAR_TRADE_ENABLED=true, implying readiness. However, it does not explicitly contrast with the sibling 'cancel_order' tool or provide when-not-to-use guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
close_all_positionsA
Close every open Pear Protocol position with a single executionType (MARKET or TWAP). Returns a per-position result array with success/error. WRITE: executes real trades. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
| executionType | Yes | ||
| twapDuration | No | ||
| twapIntervalSeconds | No | ||
| randomizeExecution | No | ||
| referralCode | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The description discloses that this is a write operation that executes real trades and requires a specific environment variable. With no annotations provided, the description carries the full burden, and it adequately communicates the mutation and necessary configuration. It also mentions the return is a per-position result array with success/error, which is useful behavioral context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise at two sentences, front-loading the core action and then adding the return type and warning. It avoids unnecessary detail. However, it could benefit from slight structuring (e.g., listing parameters or conditions) without significantly increasing length.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has 5 parameters, no output schema, and no parameter descriptions in the schema, the description is incomplete. It fails to explain the TWAP-related parameters (duration, interval, randomization) and the referral code. The return structure is vaguely described but not detailed enough for an agent to confidently parse the result array.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 5 parameters with 0% description coverage. The description only addresses the executionType parameter by naming its enum values. The other parameters (twapDuration, twapIntervalSeconds, randomizeExecution, referralCode) are not explained, leaving their semantics unclear. This is a significant gap since the schema does not provide any descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: closing every open Pear Protocol position. It specifies the required executionType parameter (MARKET or TWAP), which distinguishes it from sibling 'close_position' that closes a single position. The verb+resource combination is specific and unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description indicates it closes all positions, implying it should be used when batch closing is needed. However, it does not explicitly contrast with the alternative of using 'close_position' repeatedly or provide conditions for when not to use it. The prerequisite 'PEAR_TRADE_ENABLED=true' is noted, but no exclusion criteria are given.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
close_positionA
Close one open Pear Protocol position by positionId. executionType: MARKET (immediate) or TWAP (spread over time; requires twapDuration in seconds). WRITE: executes a real trade. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
| positionId | Yes | ||
| executionType | Yes | ||
| twapDuration | No | ||
| twapIntervalSeconds | No | ||
| randomizeExecution | No | ||
| referralCode | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Discloses that this is a write operation executing a real trade and requires an environment variable. Without annotations, it carries full burden but omits side effects, auth, or rate limits.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Three sentences, each adding essential information: main action, execution options, behavioral context. No redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema provided, and description does not hint at return type. For a complex tool with 6 parameters and two execution modes, more details on optional parameters and response would be beneficial.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, and the description only explains positionId, executionType, and twapDuration. Leaves twapIntervalSeconds, randomizeExecution, referralCode undocumented.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the verb (close), resource (one open Pear Protocol position), and method (by positionId). It distinguishes from sibling tool close_all_positions.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides when to use: to close a position by ID with MARKET or TWAP execution. Mentions requirement PEAR_TRADE_ENABLED=true but does not explicitly state when not to use or compare to alternatives like adjust_position or close_all_positions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
create_agent_walletA
Create a new Pear Protocol agent wallet for the authenticated user. The agent wallet is what Pear uses to sign Hyperliquid trades. After creation, the user MUST approve this wallet on Hyperliquid (the response message contains the approval instructions). WRITE: executes a state change. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, so description carries full burden. It discloses that it is a WRITE (state change), requires a specific environment variable, and outlines the necessary follow-up step. Could mention idempotency or error handling but is adequate.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Extremely concise: two sentences plus a brief note. Every sentence adds value, no redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given zero parameters and no output schema, the description covers all necessary aspects: purpose, requirement, post-creation action, and state change. Complete for the tool's complexity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
No parameters in input schema, so baseline is 4. Description adds no parameter info, which is acceptable since there are none.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool creates a new agent wallet for the authenticated user, explains its purpose (signing Hyperliquid trades), and distinguishes it from sibling tools like get_agent_wallet.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides context on when to use (creating a wallet) and includes a critical requirement (PEAR_TRADE_ENABLED=true) and a mandatory post-creation action (approval on Hyperliquid). Lacks explicit exclusions or alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_account_summaryA
Get the authenticated user's Pear Protocol account summary: agent wallet address, total closed trades, pending trigger-order USD value, pending TWAP-chunk USD value, and last sync timestamp. Requires PEAR_API_KEY.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries full burden for behavioral disclosure. It identifies the tool as a read operation ('Get'), lists output fields, and notes the auth requirement. However, it does not discuss rate limits, potential errors, or what happens if the API key is invalid or missing. It is adequate but not detailed.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, well-organized sentence that front-loads the purpose and lists the included fields without extraneous words. Every part contributes useful information, making it concise and efficient.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite the lack of an output schema, the description enumerates all returned fields, providing sufficient context for the agent. The auth requirement is also specified. For a simple, parameterless tool, this covers all necessary information for correct invocation and interpretation.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, so the input schema provides full coverage. The description adds no further parameter detail, which is appropriate given the lack of parameters. The baseline score of 4 is justified as there is no need for additional parameter semantics.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool retrieves the authenticated user's account summary and lists specific fields (agent wallet address, closed trades, etc.). It uses a specific verb (Get) and resource (account summary), and distinguishes from siblings like get_portfolio and get_agent_wallet by indicating the summary includes multiple aggregated pieces of data.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description mentions the requirement for PEAR_API_KEY, implying authentication context, but does not explicitly state when to use this tool over similar siblings like get_portfolio or get_health. There is no guidance on alternatives or exclusions, leaving the agent to infer usage based on the listed fields.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_active_marketsA
Get the most active Pear Protocol pair markets right now: current active pairs plus top gainers, top losers, highlighted pairs, and the user's watchlist. Use to see what's hot or as a starting point for narrowing into a specific pair.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden. The verb 'Get' implies a read-only operation with no side effects, and there is no mention of modifications or destructive actions. However, it could be more explicit about safety, but the implication is strong enough.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences: first describes output, second gives usage guidance. No fluff, front-loaded with key information. Each sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no parameters and no output schema, the description fully covers what the tool returns and when to use it. It is complete for the tool's simplicity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has 0 parameters, so the baseline is 4. The description adds value by detailing what data is returned (categories of markets), which goes beyond the empty schema and compensates for any potential ambiguity.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly specifies the verb 'Get' and the resource: active Pear Protocol pair markets including specific categories (current active pairs, top gainers, top losers, highlighted pairs, user's watchlist). This distinguishes it from sibling tools like list_markets, which likely lists all markets.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description states when to use the tool: 'to see what's hot or as a starting point for narrowing into a specific pair.' It does not explicitly mention alternatives, but the usage context is clear enough for an agent to infer appropriateness.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_agent_walletA
Get the authenticated user's Pear Protocol agent wallet address. The agent wallet is what Pear uses to sign Hyperliquid trades on the user's behalf. Returns an empty/missing address if no agent wallet has been created yet; call create_agent_wallet to create one.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, description reveals that the tool returns an empty/missing address if no agent wallet exists, signaling a non-destructive read. Could mention authentication or side effects but not required.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences, front-loaded with purpose, no unnecessary words. Each sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a zero-parameter read tool without output schema, the description fully covers purpose, return edge case, and next action. No gaps remain.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
No parameters exist, so schema coverage is 100%. Description adds no parameter info as none needed. Baseline score of 4 applies due to zero parameters.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly describes the tool as retrieving the authenticated user's agent wallet address, explains what the agent wallet is, and distinguishes from create_agent_wallet by indicating when an address might be missing.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Tells the agent when to use (to get agent wallet) and what to do if address is empty (call create_agent_wallet). Does not explicitly mention when not to use, but sibling list helps.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_healthA
Check Pear Protocol API health. Returns service status, server timestamp, and uptime in seconds. Use this to verify the API is reachable before running other tools.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided, but the description discloses the return fields (status, timestamp, uptime). Since this is a read-only health check, this is sufficient transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two concise sentences, no waste. The first sentence states the purpose, the second provides usage guidance.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
No output schema, so the description correctly covers return values. For a simple health-check tool, this is complete and leaves no ambiguity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
No parameters in schema (coverage 100%). Description adds value by explaining return values, though param semantics are not applicable. Baseline is 4 for zero-parameter tools.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's function: 'Check Pear Protocol API health'. It specifies the return values (service status, server timestamp, uptime) and the context differentiates it from sibling trading tools.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicit guidance: 'Use this to verify the API is reachable before running other tools.' This tells the agent when to invoke the tool, and implies it precedes other operations.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_open_ordersA
List the authenticated user's open limit, take-profit, and stop-loss orders on Pear Protocol. Returns each order's ID, type, status, and pair composition. Requires PEAR_API_KEY.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must carry the burden. It discloses the authentication requirement but does not mention read-only nature, pagination, rate limits, or response size. Adequate but not comprehensive.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two sentences with no redundancy. The first sentence states the core action and scope; the second lists return fields. Auth requirement is efficiently included. Every sentence earns its place.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (no parameters, no output schema), the description covers essential context: what it lists, for whom, and what fields are returned. It is complete for an agent to understand and invoke correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has zero parameters, so the description adds no parameter meaning (unnecessary). Baseline for 0 parameters is 4, as no additional semantic help is needed.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool lists open orders for the authenticated user, specifying order types (limit, take-profit, stop-loss) and return fields (ID, type, status, pair composition). It effectively distinguishes from sibling tools like get_open_positions.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description includes a prerequisite (requires PEAR_API_KEY) but lacks explicit guidance on when to use this tool versus alternatives like cancel_order or adjust_leverage. Usage context is implied but not formally stated.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_open_positionsA
List the authenticated user's currently open Pear Protocol pair positions, including position ID, entry ratio, mark ratio, unrealized PnL, and long/short composition. Requires PEAR_API_KEY.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must cover behavioral traits. It states 'Requires PEAR_API_KEY' as a prerequisite, which is helpful, but does not explicitly state that the operation is read-only or safe. For a read operation, more explicit safety cues would improve transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two sentences: one for purpose and output fields, one for the requirement. No unnecessary words; front-loaded with the action and resource.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given zero parameters and no output schema, the description covers the tool's purpose, key return fields, and a hard requirement (API key). It does not cover potential errors, pagination, or limits, but for a simple list tool it is sufficiently complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 0 parameters, so the description does not need to explain parameter semantics. It adds value by listing the output fields (position ID, entry ratio, etc.), which is relevant for understanding the tool's return.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states 'List the authenticated user's currently open Pear Protocol pair positions' with a specific verb and resource. It distinguishes from siblings like get_open_orders and close_position by focusing on pair positions. Includes details on returned fields (position ID, entry ratio, etc.).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description mentions the requirement of PEAR_API_KEY but does not provide explicit guidance on when to use this tool versus alternatives like get_open_orders or get_portfolio. No when-not or exclusion criteria stated.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_pair_ratioA
Get the current ratio (long/short composition price) for a specific Pear Protocol pair. Pass long and short asset arrays. Returns the ratio, 24h change, and funding rate. Useful when you know the pair you care about and want the latest number.
| Name | Required | Description | Default |
|---|---|---|---|
| longAssets | Yes | Asset symbols on the long side (e.g. ['BTC']). | |
| shortAssets | Yes | Asset symbols on the short side. Pass an empty array for long-only baskets. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries the full burden. It clearly indicates a read operation and lists the returned data (ratio, 24h change, funding rate), providing adequate transparency about the tool's behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two sentences, front-loaded with the core purpose, and every sentence is informative without fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description provides essential context: what the tool does, what inputs are needed, and what outputs to expect. While no output schema exists, the description covers return values adequately for a simple data-retrieval tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds value beyond the schema by explaining that shortAssets can be empty for long-only baskets and that the tool returns the latest ratio. This clarifies usage beyond the parameter descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states a specific verb ('Get') and resource ('pair ratio'), and explicitly mentions the input parameters (long and short asset arrays). It distinguishes this data-retrieval tool from sibling trading tools like open_position.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description includes 'Useful when you know the pair you care about and want the latest number,' which gives context but does not explicitly state when not to use this tool or mention alternative tools for other scenarios.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_portfolioA
Fetch the authenticated user's full portfolio metrics on Pear Protocol: bucketed PnL across last 1 day / 1 week / 1 month / 1 year / all-time, plus overall stats (total trades, all-time volume, current open interest, unrealized PnL). Requires PEAR_API_KEY.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden for behavioral disclosure. It states a key requirement ('Requires PEAR_API_KEY') and implies a read operation, but does not mention idempotency, rate limits, or potential side effects. The listed return metrics add some transparency, but more detail (e.g., response format, performance) would improve clarity.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is concise, consisting of two sentences: the first clearly states the purpose and lists key metrics, the second adds an authentication requirement. No extraneous words, and the key information is front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the absence of an output schema, the description adequately explains the return data (bucketed PnL, overall stats). It covers the main metrics an agent would need, though it lacks structural details (e.g., nesting, pagination). The tool has no parameters, so complexity is low, and the description is mostly complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The tool has zero parameters, and the schema coverage is 100% (trivially). The description correctly omits parameter details, and the baseline for no parameters is 4, which is appropriate as no additional semantic value is needed.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool fetches the authenticated user's full portfolio metrics on Pear Protocol, listing specific metrics like bucketed PnL and overall stats. It uses a specific verb ('Fetch') and resource ('portfolio metrics'), but does not explicitly differentiate from sibling tools such as get_account_summary or get_trade_history.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no explicit guidance on when to use this tool versus alternatives like get_account_summary or get_open_positions. It lacks 'when-to-use' or 'when-not-to-use' context, leaving the agent to infer usage from the purpose alone.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_trade_historyA
Fetch the authenticated user's recent closed trades on Pear Protocol with realized PnL, entry/exit ratios, and pair composition. Optional date range and limit. Requires PEAR_API_KEY.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Max number of trades to return. Default 50. | |
| startDate | No | ISO 8601 timestamp or epoch ms. Only return trades on or after this time. | |
| endDate | No | ISO 8601 timestamp or epoch ms. Only return trades on or before this time. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It discloses that the tool reads closed trades and requires authentication, but does not detail behavior like pagination, ordering, or how results are returned. Adequate for basic safety, but lacks depth.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences that are front-loaded with purpose and include key details (optional parameters, auth requirement). Every sentence adds value with no redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple tool with 3 optional parameters and no output schema, the description covers the main use case and distinguishes from siblings. However, it omits default values (e.g., limit=50) and sorting behavior, which would enhance completeness.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with clear parameter descriptions. The description only summarizes optional date range and limit without adding new meaning beyond what the schema provides. Baseline score of 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool fetches the authenticated user's recent closed trades, specifying realized PnL, entry/exit ratios, and pair composition. This distinct purpose differentiates it from sibling tools like get_open_positions or get_portfolio.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description mentions optional date range and limit, and requires an API key, but does not explicitly state when to use this tool over alternatives or provide any exclusions. Usage context is clear but lacks comparative guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_twap_ordersA
List the authenticated user's active TWAP (time-weighted average price) orders on Pear Protocol, including chunk execution and fill detail. Requires PEAR_API_KEY.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden. It only adds the authentication requirement and hints at return content but does not disclose side effects, rate limits, pagination, or error behavior. Minimal behavioral context beyond the read nature implied by 'List'.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single sentence of 15 words efficiently conveys purpose, scope, and a key requirement. No extraneous information, perfectly front-loaded.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple zero-parameter list tool, the description covers purpose, result content, and auth. However, it lacks context on empty results, error cases, or response structure, leaving some gaps for the agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has zero parameters with 100% coverage, so the description does not need to add parameter details. The mention of API key authentication is relevant but not a parameter. Baseline score of 4 for 0 parameters is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description specifies the verb 'List', the resource 'active TWAP orders', the protocol 'Pear Protocol', and additional detail about chunk execution and fill detail. It clearly distinguishes from sibling tools like 'get_open_orders' which likely handle non-TWAP orders.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description mentions the prerequisite 'Requires PEAR_API_KEY' but does not provide explicit guidance on when to use this tool over siblings like 'get_open_orders' or 'cancel_twap_order'. Usage context is implied by the TWAP-specific focus.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_marketsA
Browse Pear Protocol pair markets with optional filters and pagination. Each market is a long/short composition with current ratio, 24h change, volume, open interest, and funding. Use to discover what's tradable, or with searchText to find a specific pair.
| Name | Required | Description | Default |
|---|---|---|---|
| search | No | Free-text search across market names (composition keys like `L:BTC|S:ETH`). | |
| engine | No | Filter by execution engine. | |
| minVolume | No | Minimum 24h volume in USD. | |
| change24h | No | Minimum 24h ratio change (e.g. 0.05 for +5%). | |
| netFunding | No | Filter by net funding rate. | |
| sort | No | Sort key (e.g. 'volume', 'change24h'). | |
| page | No | Page number (1-indexed). | |
| pageSize | No | Results per page. Default 20. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations, so description carries full burden. Describes it as read-only (browse, discover) and lists return fields. However, pagination behavior (default page size, maximum) and rate limits are not disclosed. Could be more explicit about response structure.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences front-load purpose and fields, second sentence gives usage advice. No wasted words, every sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given no output schema, description lists key fields returned (ratio, change, volume, etc.) and mentions pagination. Missing details like response envelope or total count, but sufficient for a list tool. Parameters are all optional, which is clear from schema.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema has 100% coverage with detailed descriptions. Description adds context for search parameter ('searchText') and general filter purpose, but does not explain constraints like page being 1-indexed or default values. Baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Clearly states verb 'browse' and resource 'markets', listing key fields. Distinguishes from siblings that are mostly actions on positions/orders, but does not explicitly mention related sibling tools like get_active_markets or get_pair_ratio.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides usage guidance: 'Use to discover what's tradable, or with searchText to find a specific pair.' However, does not mention when not to use it or suggest alternatives, such as get_active_markets for only active markets.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
open_positionA
Open a new pair position on Pear Protocol. Specify executionType (MARKET / TRIGGER / TWAP / LADDER / TP / SL / SYNC), leverage (1-100), usdValue (≥1), slippage (0.001-0.1), and the long/short asset compositions (arrays of { asset, weight }). Optionally attach stopLoss/takeProfit and TWAP/TRIGGER/LADDER parameters. WRITE: executes a real trade. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
| executionType | Yes | ||
| leverage | Yes | ||
| usdValue | Yes | ||
| slippage | Yes | ||
| longAssets | Yes | ||
| shortAssets | Yes | ||
| triggerValue | No | ||
| triggerType | No | ||
| direction | No | ||
| twapDuration | No | ||
| twapIntervalSeconds | No | ||
| randomizeExecution | No | ||
| ladderConfig | No | ||
| stopLoss | No | ||
| takeProfit | No | ||
| referralCode | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries full burden. It discloses it's a real trade (WRITE) and a prerequisite, but doesn't detail side effects or state changes beyond the obvious. Adequate but not exceptional.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two sentences pack essential information, but the dense list could benefit from structured formatting for easier parsing. Still efficient overall.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity (16 parameters, nested objects, no output schema), the description lacks depth. It doesn't explain return values or cover all parameter details, making it incomplete for confident usage.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0%, so description must compensate. It explains executionType, leverage, usdValue, slippage, and asset arrays, but many parameters (triggerValue, triggerType, direction, twapDuration, etc.) are left unexplained, leaving gaps for a 16-parameter tool.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Open a new pair position on Pear Protocol') and lists key parameters, distinguishing it from sibling tools like close_position and adjust_position.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
It mentions 'WRITE: executes a real trade' and requires 'PEAR_TRADE_ENABLED=true', providing context for when to use. However, it does not explicitly exclude other tools or describe when not to use it.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
set_risk_parametersA
Set or update stop-loss / take-profit on an existing Pear Protocol position. Each threshold has type ('PRICE' or 'PERCENTAGE'), value, and optional trailing fields. Pass null to clear a field; omit it to leave unchanged. WRITE: changes risk parameters on a live position. Requires PEAR_TRADE_ENABLED=true.
| Name | Required | Description | Default |
|---|---|---|---|
| positionId | Yes | ||
| stopLoss | No | ||
| takeProfit | No |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Without annotations, the description carries the full burden. It discloses the write nature ('WRITE: changes risk parameters on a live position') and a prerequisite condition. It does not detail side effects or rate limits, but the main behavioral traits are transparent.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is three sentences long, front-loaded with the purpose, then breaking down parameter behavior, then stating the write operation and requirement. Every sentence adds value with no redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a mutation tool with 3 parameters and no output schema, the description covers the essential aspects: what the tool does, how to use the parameters (clear vs. omit), and a prerequisite. It could mention the return format but is otherwise complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description adds meaning: it explains that thresholds have type, value, and optional trailing fields, and clarifies null vs. omit behavior. This goes beyond the schema's structural definitions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description explicitly states the tool's purpose: 'Set or update stop-loss / take-profit on an existing Pear Protocol position.' This is a specific verb+resource combination that clearly distinguishes it from sibling tools like adjust_leverage or close_position.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides usage context: 'Pass null to clear a field; omit it to leave unchanged.' and 'Requires PEAR_TRADE_ENABLED=true.' It does not explicitly mention alternatives or when not to use, but the guidelines are clear for the intended use case.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
10 tool updates
v0.2.0- Added
adjust_leverage - Added
adjust_position - Added
cancel_order - Added
cancel_twap_order - Added
close_all_positions - Added
close_position - Added
create_agent_wallet - Added
get_agent_wallet - Added
open_position - Added
set_risk_parameters
10 tool updates
v0.1.4- First observed
get_account_summary - First observed
get_active_markets - First observed
get_health - First observed
get_open_orders - First observed
get_open_positions - First observed
get_pair_ratio - First observed
get_portfolio - First observed
get_trade_history - First observed
get_twap_orders - First observed
list_markets
TDQS
Each tool has a clear, distinct purpose with no overlap. For example, adjust_leverage and adjust_position operate on different aspects of a position, and cancel_order vs. cancel_twap_order are clearly separated for different order types. The descriptions effectively disambiguate any potential confusion.
All tool names follow a consistent verb_noun snake_case pattern (e.g., get_account_summary, close_position, open_position). There are no deviations or mixed conventions, making the naming predictable and easy to understand.
With 20 tools, the server is well-scoped for a trading platform. Each tool addresses a specific operation such as market discovery, position management, order handling, and risk control, without feeling excessive or sparse.
The tool set covers the main trading lifecycle: market data, position opening/adjusting/closing, order management (limit, TP/SL, TWAP), account info, and health checks. Minor gaps exist, such as the absence of an order modification tool, but the core CRUD and risk operations are well covered.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Read-only MCP server for The Quiet Protocol's engines, benchmarks, proof, and business data.
MCP server for OpenMM — exposes market data, account, trading, and strategy tools to AI agents
Read-only Ratevert MCP for asset search, pair rates, and conversions.
Live prices, perps, prediction markets and a paper trading desk over one MCP.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceA read-only MCP server that connects Claude to your eToro account, enabling queries about your portfolio, P\&L, balances, watchlists, live prices, and price history.MIT
- AlicenseNot gradedqualityBmaintenanceAn MCP server that lets Claude Code (and other MCP clients) trade crypto, read market data, and manage wallets across EVM chains and Solana.23MIT

@gryps/agent-mcpofficial
AlicenseAqualityBmaintenanceRead-only MCP server for Gryps venue state, enabling Claude to query live markets, fee schedules, funding parameters, and open interest.6127MIT- AlicenseAqualityBmaintenanceA read-only MCP server for querying Hyperliquid perp markets, funding rates, order books, candles, and account positions/fills/funding for any address, without needing API keys or wallets.8551MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/MarvelNwachukwu/mcp-pear'
If you have feedback or need assistance with the MCP directory API, please join our Discord server