Skip to main content
Glama

Attach Stop-Loss / Take-Profit

protect_position
Destructive

Attach exchange-native stop-loss and take-profit to an already open position. Set percentage distances from the mark price, and Pacifica enforces the triggers even offline.

Instructions

Attach EXCHANGE-NATIVE stop-loss / take-profit to a position that is ALREADY OPEN (opened anywhere, this bot, the website, or another tool). Percentages are distances from the current mark price (e.g. 3 = 3%); 0 disables that leg. Once set, Pacifica enforces the triggers even if this bot or the user's PC is offline. IMPORTANT: modifies live protection, call with confirm=false first to preview, confirm=true after the user approves.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
symbolYes
confirmNo
stop_loss_pctNo
take_profit_pctNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

Annotations already indicate destructive and non-idempotent behavior. The description adds valuable context beyond annotations: the triggers are enforced even offline, and the two-phase confirm workflow (preview with confirm=false, execute with confirm=true) is disclosed. It also clarifies what 'modifies live protection' entails.

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?

The description is concise, structured, and front-loaded. The first sentence states the core action and scope. Subsequent sentences efficiently clarify parameter semantics, offline enforcement, and the confirmation workflow. No filler or redundant information.

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

Completeness4/5

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

Given the tool's mutating nature, four parameters, annotations, and output schema, the description covers the essential aspects: purpose, open-position prerequisite, parameter semantics, offline enforcement, and the confirm workflow. It does not describe return values, but that is handled by the output schema.

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

Parameters4/5

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

The schema has 0% description coverage, but the description compensates by explaining the percentage parameters are distances from the current mark price and that 0 disables that leg. It also explains the confirm parameter's role in the two-phase workflow. The symbol parameter is not explicitly described but is self-evident from the context.

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

Purpose5/5

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

The description specifies a clear action ('Attach EXCHANGE-NATIVE stop-loss / take-profit') and a specific resource ('a position that is ALREADY OPEN'). It explicitly distinguishes from sibling tools like open_with_bracket by emphasizing the position must already be open, regardless of where it was opened.

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

Usage Guidelines4/5

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

Provides clear context on when to use: only for positions that are already open. It also gives an explicit workflow with confirm=false for preview and confirm=true after approval. However, it does not explicitly name alternatives or state when not to use beyond the 'already open' condition.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

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/oceanagent/ocean-agent'

If you have feedback or need assistance with the MCP directory API, please join our Discord server