@@ -79,6 +79,7 @@ def handle_subscribe_instrument(
7979 pips : float ,
8080 size_multiplier : float ,
8181 instrument_multiplier : float
82+ supported_features: Dict[str , object ]
8283) -> None :
8384 """
8485 This function is called each time the user enables your addon for a certain instrument.
@@ -90,9 +91,19 @@ def handle_subscribe_instrument(
9091 :param pips: The minimum price increment of the subscribed instrument.
9192 :param size_multiplier: Inverse of the minimum size increment of the subscribed instrument.
9293 :param instrument_multiplier: Contract size multiplier (useful for futures).
94+ :param supported_features: A dictionary, that represents features that are by particular instrument.
9395 """
9496 print (" Subscribing to the instrument " + alias, flush = True )
9597
98+ Example of supported_features:
99+ {' trading' : True , ' oco' : True , ' oso' : True , ' depth' : True , ' mbo' : False , ' trailingStopsAsIndependentOrders' : True ,
100+ ' trailingStopsAsBracketChildren' : True , ' brackets' : True , ' bracketTiers' : False , ' convertOrderToMkt' : False ,
101+ ' supportedLimitDurations' : [' GTC' , ' FOK' , ' IOC' , ' GTC_PO' ], ' supportedStopDurations' : [' GTC' , ' FOK' , ' IOC' ],
102+ ' supportedStopOrders' : [' LMT' , ' MKT' ], ' negativeStopLimitOffset' : True , ' marketMode' : False , ' isBalanceSupported' : True ,
103+ ' tradingStartKnown' : False , ' exchangeUsedForSubscription' : False , ' typeUsedForSubscription' : False , ' isDelayed' : False ,
104+ ' clientSideFeatures' : [' TRAILING_STOPS_AS_BRACKET_CHILDREN' , ' BRACKETS' , ' OCO' , ' OSO' , ' TRAILING_STOPS_INDEPENDENT' ],
105+ ' isTradingSubscriptionSupported' : False }
106+
96107def handle_unsubscribe_instrument (
97108 addon : Any,
98109 alias : str
0 commit comments