market_open_position
Open a new position at market price on HyperLiquid. Set coin, side, and token count to execute immediately with a market order.
Instructions
Open a new position at market price using HyperLiquid's market_open for optimal execution
Args: coin: Trading pair (e.g., "BTC", "ETH") side: Position side ("buy" for long, "sell" for short) size: Number of tokens/coins to trade (NOT dollar value - e.g., 0.1 for 0.1 SOL, not $20) client_order_id: Optional client order ID for tracking
IMPORTANT: The 'size' parameter is the NUMBER OF TOKENS, not dollar value. If user wants "$20 worth of SOL" at current price ~$150, calculate: $20 ÷ $150 = 0.133 SOL
Note: This uses HyperLiquid's native market_open method for the best execution.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| coin | Yes | ||
| side | Yes | ||
| size | Yes | ||
| client_order_id | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||