close_position
Closes all positions for a specified trading pair on Hyperliquid and returns order details.
Instructions
Close all positions for the specified trading pair on Hyperliquid.
Args: symbol: Trading pair, e.g., "BTC/USDC:USDC"
Returns: Dict with close order details or error
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"symbol": "<symbol>"
},
"name": "close_position"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| symbol | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |