GetOrders
GetOrders - request a list of currently opened positions and pending/limit orders.
Example:
{"id": 11, "type":"GetOrders", "body": {}}
Request Body Fields: n/a.
Responce Type - Orders.
Responce Body Fields:
balance
string
current balance of the trading account
equity
float
current equity of the trading account
credit
float
current credit of the trading account
margin
double
margin of the trading account
margin_level
float
margin level of the trading account
currency
string
currency of the trading account
orders
an array of currently active positions with the following (see the table Orders)
pendings
an array (see the table Pendings)
Orders
ticket
the ticket of a deal
position
the position ID (ticket) specified in the deal
price
the price at which the deal was executed
current_price
the current price of symbol
volume
the volume of a deal in lots
type
the order type, can 0 - for buy and 1 for sell
symbol
the symbol, for which the deal was executed
comment
a comment to a deal
sl
the Stop Loss level of a trade
tp
the Take Profit level of a trade
commission
the commision
swap
the swap value of a trade in the trading account currency
profit
current profit/loss of a trade in the trading account currency
maring_rate
the exchange rate of the margin currency of a trade to the trading account currency
state
the current state of a trade (always 0)
time_created
creation time in milliseconds in UTC
time_updated
update time in milliseconds in UTC
Pendings
ticket
the ticket of an order
position
the position ID (ticket) specified in the order
price
the price at which the order was executed
price_trigger
the price, at which a Limit order is placed when the Stop Limit order triggers
price_current
the current price of symbol
volume
the volume of the order in lots
type
the order type, can be:
0 - BUY
1 - SELL
2 - BUY LIMIT
3 - SELL LIMIT
4 - BUY STOP
5 - SELL STOP
6 - BUY STOP LIMIT
7 - SELL STOP LIMIT
symbol
the symbol, for which the order was executed
comment
a comment to an order
sl
the Stop Loss level of an order
tp
the Take Profit level of am order
commission
the commision
swap
the swap value of a trade in the trading account currency
profit
current profit/loss of an order in the trading account currency
maring_rate
the exchange rate of the margin currency of a trade to the trading account currency
state
the current state of an order, can be:
1 - placed
3 - partially filled
time_created
creation time in milliseconds in UTC
time_updated
update time in milliseconds in UTC
Example:
Last updated