set_risk_parameters
Set or update stop-loss and take-profit thresholds on an existing position. Supports price or percentage values with optional trailing settings.
Instructions
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.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| positionId | Yes | ||
| stopLoss | No | ||
| takeProfit | No |