@@ -156,6 +156,21 @@ def from_dict(d):
156156 return LastQuoteOptionContractSnapshot (** d )
157157
158158
159+ @modelclass
160+ class LastTradeOptionContractSnapshot :
161+ "Contains data for the most recent trade for an options contract."
162+ price : Optional [float ] = None
163+ sip_timestamp : Optional [int ] = None
164+ size : Optional [int ] = None
165+ conditions : Optional [List [int ]] = None
166+ exchange : Optional [int ] = None
167+ timeframe : Optional [str ] = None
168+
169+ @staticmethod
170+ def from_dict (d ):
171+ return LastTradeOptionContractSnapshot (** d )
172+
173+
159174@modelclass
160175class Greeks :
161176 "Contains data for the greeks in an options contract."
@@ -193,6 +208,7 @@ class OptionContractSnapshot:
193208 greeks : Optional [Greeks ] = None
194209 implied_volatility : Optional [float ] = None
195210 last_quote : Optional [LastQuoteOptionContractSnapshot ] = None
211+ last_trade : Optional [LastTradeOptionContractSnapshot ] = None
196212 open_interest : Optional [float ] = None
197213 underlying_asset : Optional [UnderlyingAsset ] = None
198214
@@ -211,6 +227,9 @@ def from_dict(d):
211227 last_quote = None
212228 if "last_quote" not in d
213229 else LastQuoteOptionContractSnapshot .from_dict (d ["last_quote" ]),
230+ last_trade = None
231+ if "last_trade" not in d
232+ else LastTradeOptionContractSnapshot .from_dict (d ["last_trade" ]),
214233 open_interest = d .get ("open_interest" , None ),
215234 underlying_asset = None
216235 if "underlying_asset" not in d
0 commit comments