List pending orders on an account
list_pending_ordersRetrieve pending limit and stop orders from an MT5 account, showing symbol, type, volume, trigger price, stop loss, and take profit. Cancel orders using their ticket.
Instructions
List the pending limit and stop orders resting on one MT5 account, read live from the terminal: symbol, order type, volume, trigger price, stop loss and take profit. These are orders that have NOT been filled — for filled positions currently open, use list_positions. accountId is the id field from list_accounts, NOT login. Each order's ticket is the handle used to cancel it. An sl, tp or priceStopLimit of 0 means that level is not set.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| accountId | Yes | The `id` field from list_accounts. Not the `login` (MT5 account number). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| notes | Yes | ||
| orders | Yes |