Page 1 of 1

Getting order ID, the action and affected order ID

Posted: Mon Oct 19, 2020 1:14 pm
by DanyloL
Hi.
I'm making an indicator for my customer. For it, I need to get the info, provided in the table below (it is the table 2 from a public research paper ( https://arxiv.org/pdf/1909.09495.pdf ) ). I found a way to get relevant information using MarketByOrderDepthDataListener. But I'm not sure if I can get the Action and the Affected order ID (see the table below).
Here's what MarketByOrderDepthDataListener provides:

Code: Select all

 
@Override
public void send(String orderId, boolean isBid, int price, int size) {
}

@Override
public void replace(String orderId, int price, int size) {
}
@Override
public void cancel(String orderId) {
}

Is there a way to get the missing information (provided my market does indeed support MarketByOrderDepthDataListener)?
Thank you

Re: Getting order ID, the action and affected order ID

Posted: Tue Oct 20, 2020 10:36 am
by Andry API support
Hi DanyloL!
Action:
Limit(new) - MarketByOrderDepthDataAdapter send(String orderId, boolean isBid, int price, int size)
Modify(update) - MarketByOrderDepthDataAdapter replace(String orderId, int price, int size)
Trade - TradeListener onTrade(double price, int size, TradeInfo tradeInfo) -> tradeInfo.passiveOrderId (Affected)
Delete - MarketByOrderDepthDataAdapter cancel(String orderId)

You can find Simplified API javadoc (as well as other javadocs) at C:\Program Files\Bookmap\lib (or similar location for non-Microsoft OS):
bm-simplified-api-wrapper-javadoc.jar
 

Re: Getting order ID, the action and affected order ID

Posted: Tue Oct 20, 2020 5:56 pm
by DanyloL
AndreyR wrote:
Tue Oct 20, 2020 10:36 am
Hi DanyloL!
Action:
Limit(new) - MarketByOrderDepthDataAdapter send(String orderId, boolean isBid, int price, int size)
Modify(update) - MarketByOrderDepthDataAdapter replace(String orderId, int price, int size)
Trade - TradeListener onTrade(double price, int size, TradeInfo tradeInfo) -> tradeInfo.passiveOrderId (Affected)
Delete - MarketByOrderDepthDataAdapter cancel(String orderId)

You can find Simplified API javadoc (as well as other javadocs) at C:\Program Files\Bookmap\lib (or similar location for non-Microsoft OS):
bm-simplified-api-wrapper-javadoc.jar
Thank you!
 

Re: Getting order ID, the action and affected order ID

Posted: Wed Oct 21, 2020 1:58 pm
by DanyloL
AndreyR wrote:
Tue Oct 20, 2020 10:36 am
Hi DanyloL!
Action:
Limit(new) - MarketByOrderDepthDataAdapter send(String orderId, boolean isBid, int price, int size)
Modify(update) - MarketByOrderDepthDataAdapter replace(String orderId, int price, int size)
Trade - TradeListener onTrade(double price, int size, TradeInfo tradeInfo) -> tradeInfo.passiveOrderId (Affected)
Delete - MarketByOrderDepthDataAdapter cancel(String orderId)

You can find Simplified API javadoc (as well as other javadocs) at C:\Program Files\Bookmap\lib (or similar location for non-Microsoft OS):
bm-simplified-api-wrapper-javadoc.jar
One more question: do MarketByOrderDepthDataAdapter's send(...) and replace(...) methods also provide the trades? Or trades are only shown separately in TradeListener onTrade(...)? Sorry, if it's already described in the documentation, but I couldn't find such an info there.