open_perp_position
Open a perpetual futures position on HyperLiquid with leverage and optional take-profit or stop-loss. Place market or limit orders, long or short, with reduce-only support.
Instructions
Open a perpetual futures position on HyperLiquid with leverage, TP/SL. Supports market and limit orders.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| coin | Yes | Asset symbol, e.g. 'BTC', 'ETH', 'SOL' | |
| size | Yes | Position size in contracts | |
| price | Yes | Price in USD | |
| apiKey | Yes | GDEX API key for AES encryption | |
| isLong | Yes | True for long, false for short | |
| slPrice | No | Stop-loss price in USD, '' to skip | |
| tpPrice | No | Take-profit price in USD, '' to skip | |
| isMarket | No | True for market order, false for limit | |
| leverage | No | Leverage 1-50 (sent top-level; HL defaults to 20x if omitted) | |
| reduceOnly | No | Reduce-only order | |
| walletAddress | Yes | Control wallet address | |
| sessionPrivateKey | Yes | Session private key from sign-in |