drift_closePerpPosition
Close an open perpetual position on Drift using your wallet address and market index. Optionally specify a sub-account.
Instructions
Close a perpetual position on Drift.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| wallet | Yes | Solana public key (base58) | |
| marketIndex | Yes | ||
| subAccountId | No |