Orders (table)
Brief
This section describes the Orders table that contains information about orders. The data is kept in this table until all the orders are executed.
Details
Name |
Type |
Description |
||||||||||||||||||||||||||||
OrderID |
String |
The unique identification number of the order. The number is unique within the same database that stores
the account the order is placed on. For example, |
||||||||||||||||||||||||||||
RequestID |
String |
The identifier of the request to create an order. One request can create several orders. For example, if an entry order
is created with stop and limit orders attached, the table contains several orders with the same |
||||||||||||||||||||||||||||
Rate |
Double |
The price the order is placed at. In the case of FX instruments, it is expressed in the instrument counter currency per one unit of base currency. In the case of CFD instruments, it is expressed in the instrument native currency per one contract. In the case of open/close market orders and pegged stop/limit orders, the value of this field is |
||||||||||||||||||||||||||||
ExecutionRate |
Double |
The price the order is executed at. In the case of FX instruments, it is expressed in the instrument counter currency per one unit of base currency. In the case of CFD instruments,
it is expressed in the instrument native currency per one contract. Applicable only when the order is filled completely or partially.
In other words, this field has a meaningful value if the order status is either Pending Calculated, Executing or Executed.
For details, please refer to Orders State Machines section. If the order is in any other state, the value of this field is |
||||||||||||||||||||||||||||
RateMin |
Double |
The minimum price at which the order can be filled. In the case of FX instruments, it is expressed in the instrument counter currency per one unit of base currency. In the case of CFD instruments,
it is expressed in the instrument native currency per one contract.
It is applicable only for open/close range orders. For all other order types, the value of this field is |
||||||||||||||||||||||||||||
RateMax |
Double |
The maximum price at which the order can be filled. In the case of FX instruments, it is expressed in the instrument counter currency per one unit of base currency. In the case of CFD instruments,
it is expressed in the instrument native currency per one contract.
It is applicable only for open/close range orders. For all other order types, the value of this field is |
||||||||||||||||||||||||||||
TradeID |
String |
The unique identification number of the position to be opened/closed by the order. The number is unique within the same database
that stores the account the position can be opened or closed on. For example, In some cases, this number does not reference any particular position. Such cases are:
|
||||||||||||||||||||||||||||
AccountID |
String |
The unique identification number of the account the order is placed on. The number is unique within the
database where the account is stored. For example, |
||||||||||||||||||||||||||||
AccountName |
String |
The unique name of the account the order is placed on. The name is unique within the database where the
account is stored. For example, |
||||||||||||||||||||||||||||
OfferID |
String |
The unique identification number of the instrument the order is placed for. |
||||||||||||||||||||||||||||
NetQuantity |
Boolean |
The Net Amount order flag. It defines whether the order is a Net Amount order or not. The possible values are:
The Net Amount order closes all positions of the specified instrument and account that are in the direction (buy or sell) opposite to the direction of the Net Amount order. The following types of order can be Net Amount orders:
|
||||||||||||||||||||||||||||
BuySell |
String |
The direction of the trade. The possible values are:
|
||||||||||||||||||||||||||||
Stage |
String |
The order action. It defines whether the order is placed to open or close a position. The possible values are:
|
||||||||||||||||||||||||||||
Type |
String |
The order type. The possible values are:
|
||||||||||||||||||||||||||||
Status |
String |
The state of the order. The possible values are:
|
||||||||||||||||||||||||||||
Amount |
Integer |
The amount of the order. In the case of FX instruments, the amount is expressed in the base currency of an instrument. In the case of CFD instruments, the amount is expressed in contracts. If the order is filled completely at the first attempt or rejected in the whole amount, it is the initial amount
of the order. Regardles of the order direction (buy or sell), the value of this field is positive. |
||||||||||||||||||||||||||||
StatusTime |
Date |
The date and time of the last update of the order state. |
||||||||||||||||||||||||||||
Lifetime |
Integer |
The time, during which the trader must accept or reject the order requoted by the dealer. The time is expressed in seconds. This field is not currently in use. |
||||||||||||||||||||||||||||
AtMarket |
Double |
The distance from the |
||||||||||||||||||||||||||||
TrailStep |
Integer |
The number of pips the market should move before the order moves the same number of pips after it. |
||||||||||||||||||||||||||||
TrailRate |
Double |
The market price at the time the order automatically moves following the market fluctuations. In the case of FX instruments, it is expressed in the instrument counter currency per one unit of base currency. In the case of CFD instruments, it is expressed in the instrument native currency per one contract. If the order has not followed the market yet, the value of this field provides the initial market price
at the time when the order is placed. It is applicable only for trailing orders (trailing stop, entry
trailing stop/limit). Otherwise, the value of this field is |
||||||||||||||||||||||||||||
TimeInForce |
String |
The time-in-force option of the order. The possible values are:
|
||||||||||||||||||||||||||||
AccountKind |
String |
The type of the account the order is placed on. The possible values are:
|
||||||||||||||||||||||||||||
RequestTXT |
String |
The custom identifier of the order. For example, |
||||||||||||||||||||||||||||
ContingentOrderID |
String |
The unique identification number of the contingent order to which the order is linked.
The number is unique within the same database that stores the account the contingent order is placed on.
For example, |
||||||||||||||||||||||||||||
ContingencyType |
Integer |
The type of the contingent order to which the order is linked. It is applicable only for orders included in an OCO order or secondary orders of ELS and OTO orders. The possible values are:
For all other orders, the value of this field is |
||||||||||||||||||||||||||||
PrimaryID |
String |
The unique identification number of the primary order of ELS or OTO contingent orders to which the order
is linked. The number is unique within the same database that stores the account the primary order is placed on.
For example, |
||||||||||||||||||||||||||||
OriginAmount |
Integer |
The original amount of the order when it is placed. In the case of FX instruments, the amount is expressed in the base currency of an instrument. In the case of CFD instruments, the amount is expressed in contracts. This field has the same value for the lifetime of the order. |
||||||||||||||||||||||||||||
FilledAmount |
Integer |
The amount of the last order portion filled. In the case of FX instruments, the amount is expressed in the
base currency of an instrument. In the case of CFD instruments, the amount is expressed in contracts. If the order is rejected or canceled,
the value of this field is |
||||||||||||||||||||||||||||
WorkingIndicator |
Boolean |
The working indicator flag. It defines whether the order is active on the market or not. The possible values are:
It is applicable only for secondary orders of ELS and OTO orders. For all other orders, the value of this field is |
||||||||||||||||||||||||||||
PegType |
String |
The price used to calculate the pegged order price. Pegged means that the price is specified as an offset to one of the following prices:
This field is applicable only for stop/limit orders and secondary orders of ELS orders. For all other order types, the value of this field is blank. |
||||||||||||||||||||||||||||
PegOffset |
Double |
The offset to the price specified in the |
||||||||||||||||||||||||||||
ExpireDate |
Date |
The expiration date and time of the order. It is applicable only for the orders with the |
||||||||||||||||||||||||||||
ValueDate |
String |
The simulated delivery date. The date when the position could be automatically closed.
The position is closed only if the order is executed and opens a position. This field is provided in the |
||||||||||||||||||||||||||||
Parties |
String |
The unique identifier of the environment that is used to place the order. The identifier is generated by ForexConnect. |
||||||||||||||||||||||||||||
Limit |
Double |
The price of the associated limit order (the profit limit level). In the case of FX instruments, it is expressed in the instrument counter currency per one unit of base currency. In the case of CFD instruments, it is expressed in the instrument native currency per one contract. It is applicable only for opening orders (Entry or Market). Note: It is a calculated field and is available only through the Table Manager.
It is not applicable for the U.S. accounts. In the case of the accounts subject to the FIFO rule, the
value of this field is |
||||||||||||||||||||||||||||
Stop |
Double |
The price of the associated stop order (the loss limit level). In the case of FX instruments, it is expressed in the instrument counter currency per one unit of base currency. In the case of CFD instruments, it is expressed in the instrument native currency per one contract. It is applicable only for opening orders (Entry or Market). Note: It is a calculated field and is available only through the Table Manager. It is not
applicable for the U.S. accounts. In the case of the accounts subject to the FIFO rule, the value of this field is
|
||||||||||||||||||||||||||||
StopTrailStep |
Integer |
The trailing step of the associated trailing stop order or secondary entry stop order of an ELS order. It is expressed in pips.
For details, see Note: It is a calculated field and is available only through the Table Manager. |
||||||||||||||||||||||||||||
StopTrailRate |
Double |
The trailing rate of the associated trailing stop order or secondary entry stop order of an ELS order.
In the case of FX instruments, it is expressed in the instrument counter currency per one unit of base currency.
In the case of CFD instruments, it is expressed in the instrument native currency per one contract.
For details, see Note: It is a calculated field and is available only through the Table Manager. |