Order Entry Events
Note
It is important to note that these are updates, being asynchronous, these updates will be processed by the asyncCallback function passed as a second parameter in the registerOrderEntry function.
Accounts List Changed
This event comes whenever a new connection has been established or an existing connection has been closed.
{
"UPD":"Accounts" // Update Type
}
Account Loaded
This event comes when the list of orders or positions in the specified account has been loaded.
{
"UPD":"Account", // Update Type
"PV":"QOR", // Provider Id
"AC":"acc12345" // Account Id
}
Order
This event comes whenever a new order is placed or an existing order changes its status. For a comprehensive list of order statuses please see the Order Status section.
{
"UPD":"Order", // Update Type
"PV":"QOR", // Provider Id
"AC":"acc12345", // Account Id
"OD":"354", // Order Id
"ST":"N", // Order Status
"SD":"B", // Side: B / S
"QT":"5", // Quantity
"INS":"ESZ17", // Instrument
"TP":"STWL", // Order Type
"PR":"1300", // Price
"LM":"1300", // Limit
}
Fill
This event comes whenever an order has been filled.
{
"UPD":"Fill", // Update Type
"PV":"QOR", // Provider Id
"AC":"acc12345", // Account id
"FD":"43", // Fill Id
"OD":"423" // Order Id
"SD":"L", // Side: L(long) / S (short)
"QT":"5", // Quantity
"INS":"ESZ17", // Instrument
"PR":"1300", // Price
}
Position
This event comes whenever a fill is processed and changed into an open position.
{
"UPD":"Position", // Update Type
"PV":"QOR", // Provider Id
"AC":"acc12345", // Account Id
"PD":"435626", // Position Id
"SD":"L", // Side: L (Long) / S (short)
"QT":"5", // Quantity
"INS":"ESZ17", // Instrument
"PR":"1300", // Price
}