All files / src/models market-data.model.ts

100% Statements 86/86
100% Branches 0/0
100% Functions 0/0
100% Lines 84/84

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 3758x           8x     8x       8x       8x       8x       8x       8x       8x       8x       8x               8x       8x       8x       8x       8x       8x       8x       8x           8x       8x       8x               8x       8x       8x       8x       8x       8x           8x           8x             8x       8x           8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x           8x       8x           8x       8x             8x             8x             8x             8x               8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x       8x    
import {model, property} from "@waytrade/microservice-core";
 
/**
 * Market ata values.
 */
@model("Market data values.")
export class MarketData {
  /** Number of contracts or lots offered at the bid price. */
  @property("Number of contracts or lots offered at the bid price.")
  BID_SIZE?: number;
 
  /** Highest priced bid for the contract. */
  @property("Highest priced bid for the contract.")
  BID?: number;
 
  /** Lowest price offer on the contract. */
  @property("Lowest price offer on the contract.")
  ASK?: number;
 
  /** Number of contracts or lots offered at the ask price. */
  @property("Number of contracts or lots offered at the ask price.")
  ASK_SIZE?: number;
 
  /** Last price at which the contract traded. */
  @property("Last price at which the contract traded.")
  LAST?: number;
 
  /** Number of contracts or lots traded at the last price. */
  @property("Number of contracts or lots traded at the last price.")
  LAST_SIZE?: number;
 
  /** High price for the day. */
  @property("High price for the day.")
  HIGH?: number;
 
  /** Low price for the day. */
  @property("Low price for the day.")
  LOW?: number;
 
  /** Trading volume for the day for the selected contract (US Stocks: multiplier 100). */
  @property("Trading volume for the day for the selected contract.")
  VOLUME?: number;
 
  /**
   * The last available closing price for the previous day.
   * For US Equities, we use corporate action processing to get the closing price,
   * so the close price is adjusted to reflect forward and reverse splits and cash and stock dividends.
   */
  @property("The last available closing price for the previous day.")
  CLOSE?: number;
 
  /** Today's opening price. */
  @property("Today's opening price.")
  OPEN?: number;
 
  /** Lowest price for the last 13 weeks. */
  @property("Lowest price for the last 13 weeks.")
  LOW_13_WEEK?: number;
 
  /** Highest price for the last 13 weeks. */
  @property("Highest price for the last 13 weeks.")
  HIGH_13_WEEK?: number;
 
  /** Lowest price for the last 26 weeks. */
  @property("Lowest price for the last 26 weeks.")
  LOW_26_WEEK?: number;
 
  /** Highest price for the last 26 weeks. */
  @property("Highest price for the last 26 weeks.")
  HIGH_26_WEEK?: number;
 
  /** Lowest price for the last 52 weeks. */
  @property("Lowest price for the last 52 weeks.")
  LOW_52_WEEK?: number;
 
  /** Highest price for the last 52 weeks. */
  @property("Highest price for the last 52 weeks.")
  HIGH_52_WEEK?: number;
 
  /** The average daily trading volume over 90 days (multiply this value times 100). */
  @property(
    "The average daily trading volume over 90 days (multiply this value times 100).",
  )
  AVG_VOLUME?: number;
 
  /** Total number of options that were not closed. */
  @property("Total number of options that were not closed).")
  OPEN_INTEREST?: number;
 
  /** The 30-day historical volatility (currently for stocks). */
  @property("The 30-day historical volatility (currently for stocks).")
  OPTION_HISTORICAL_VOL?: number;
 
  /**
   * A prediction of how volatile an underlying will be in the future.
   * The IB 30-day volatility is the at-market volatility estimated for a maturity thirty calendar days forward of the current trading day,
   * and is based on option prices from two consecutive expiration months.
   */
  @property("A prediction of how volatile an underlying will be in the future.")
  OPTION_IMPLIED_VOL?: number;
 
  /**	Call option open interest. */
  @property("Call option open interest.")
  OPTION_CALL_OPEN_INTEREST?: number;
 
  /** Put option open interest. */
  @property("Put option open interest.")
  OPTION_PUT_OPEN_INTEREST?: number;
 
  /** Call option volume for the trading day. */
  @property("Call option volume for the trading day.")
  OPTION_CALL_VOLUME?: number;
 
  /** Put option volume for the trading day. */
  @property("Put option volume for the trading day.")
  OPTION_PUT_VOLUME?: number;
 
  /** The number of points that the index is over the cash index. */
  @property("The number of points that the index is over the cash index.")
  INDEX_FUTURE_PREMIUM?: number;
 
  /** Identifies the options exchange(s) posting the best bid price on the options contract. */
  @property(
    "Identifies the options exchange(s) posting the best bid price on the options contract.",
  )
  BID_EXCH?: number;
 
  /** Identifies the options exchange(s) posting the best ask price on the options contract. */
  @property(
    "Identifies the options exchange(s) posting the best ask price on the options contract.",
  )
  ASK_EXCH?: number;
 
  /**
   * The mark price is equal to the Last Price unless: Ask < Last - the mark price is equal to the Ask Price.
   * Bid > Last - the mark price is equal to the Bid Price.
   */
  @property("The mark price.")
  MARK_PRICE?: number;
 
  /** Time of the last trade (in UNIX time). */
  @property("Time of the last trade (in UNIX time).")
  LAST_TIMESTAMP?: number;
 
  /** Describes the level of difficulty with which the contract can be sold short. */
  @property(
    "Describes the level of difficulty with which the contract can be sold short.",
  )
  SHORTABLE?: number;
 
  /** Provides the available Reuter's Fundamental Ratios. */
  @property("Provides the available Reuter's Fundamental Ratios.")
  FUNDAMENTAL_RATIOS?: number;
 
  /** Last trade details. */
  @property("Last trade details.")
  RT_VOLUME?: number;
 
  /** Indicates if a contract is halted */
  @property("Indicates if a contract is halted.")
  HALTED?: number;
 
  /** Trade count for the day. */
  @property("Trade count for the day.")
  TRADE_COUNT?: number;
 
  /** Trade count per minute. */
  @property("Trade count per minute.")
  TRADE_RATE?: number;
 
  /** Volume per minute. */
  @property("Volume per minute.")
  VOLUME_RATE?: number;
 
  /** Last Regular Trading Hours traded price. */
  @property("Last Regular Trading Hours traded price.")
  LAST_RTH_TRADE?: number;
 
  /** 30-day real time historical volatility. */
  @property("30-day real time historical volatility.")
  RT_HISTORICAL_VOL?: number;
 
  /** Contract's dividends. */
  @property("Contract's dividends.")
  IB_DIVIDENDS?: number;
 
  /** Contract's news feed. */
  @property("Contract's news feed.")
  NEWS_TICK?: number;
 
  /** The past three minutes volume. Interpolation may be applied. */
  @property("The past three minutes volume. Interpolation may be applied")
  SHORT_TERM_VOLUME_3_MIN?: number;
 
  /** The past five minutes volume. Interpolation may be applied. */
  @property("The past five minutes volume. Interpolation may be applied.")
  SHORT_TERM_VOLUME_5_MIN?: number;
 
  /** The past ten minutes volume. Interpolation may be applied. */
  @property("The past ten minutes volume. Interpolation may be applied.")
  SHORT_TERM_VOLUME_10_MIN?: number;
 
  /** Exchange of last traded price. */
  @property("Exchange of last traded price.")
  LAST_EXCH?: number;
 
  /** Timestamp (in Unix ms time) of last trade returned with regulatory snapshot. */
  @property(
    "Timestamp (in Unix ms time) of last trade returned with regulatory snapshot",
  )
  LAST_REG_TIME?: number;
 
  /** Total number of outstanding futures contracts (TWS v965+). *HSI open interest requested with generic tick 101. */
  @property("Total number of outstanding futures contracts.")
  FUTURES_OPEN_INTEREST?: number;
 
  /** Average volume of the corresponding option contracts(TWS Build 970+ is required). */
  @property(
    "Average volume of the corresponding option contracts(TWS Build 970+ is required).",
  )
  AVG_OPT_VOLUME?: number;
 
  /** Number of shares available to short (TWS Build 974+ is required) */
  @property("Number of shares available to short.")
  SHORTABLE_SHARES?: number;
 
  /**
   * Today's closing price of ETF's Net Asset Value (NAV).
   * Calculation is based on prices of ETF's underlying securities.
   */
  @property("Today's closing price of ETF's Net Asset Value (NAV).")
  ETF_NAV_CLOSE?: number;
 
  /**
   * Yesterday's closing price of ETF's Net Asset Value (NAV).
   * Calculation is based on prices of ETF's underlying securities.
   */
  @property("Yesterday's closing price of ETF's Net Asset Value (NAV).")
  ETF_NAV_PRIOR_CLOSE?: number;
 
  /**
   * The bid price of ETF's Net Asset Value (NAV).
   * Calculation is based on prices of ETF's underlying securities.
   */
  @property("The bid price of ETF's Net Asset Value (NAV).")
  ETF_NAV_BID?: number;
 
  /**
   * The ask price of ETF's Net Asset Value (NAV).
   * Calculation is based on prices of ETF's underlying securities.
   */
  @property("The ask price of ETF's Net Asset Value (NAV).")
  ETF_NAV_ASK?: number;
 
  /**
   * The last price of Net Asset Value (NAV).
   * For ETFs: Calculation is based on prices of ETF's underlying securities.
   * For NextShares: Value is provided by NASDAQ.
   */
  @property("The ask price of ETF's Net Asset Value (NAV).")
  ETF_NAV_LAST?: number;
 
  /** ETF Nav Last for Frozen data. */
  @property("ETF Nav Last for Frozen data.")
  ETF_NAV_FROZEN_LAST?: number;
 
  /** The high price of ETF's Net Asset Value (NAV). */
  @property("The high price of ETF's Net Asset Value (NAV).")
  ETF_NAV_HIGH?: number;
 
  /** The low price of ETF's Net Asset Value (NAV). */
  @property("The low price of ETF's Net Asset Value (NAV).")
  ETF_NAV_LOW?: number;
 
  /** The underlying asset price of an option. */
  @property("The underlying asset price of an option.")
  OPTION_UNDERLYING?: number;
 
  /** The underlying asset price of an option. */
  @property("The IV on the bid price of an option.")
  BID_OPTION_IV?: number;
 
  /** The bid price of an option. */
  @property("The bid price of an option.")
  BID_OPTION_PRICE?: number;
 
  /** The delta on the bid price of an option. */
  @property("The delta on the bid price of an option.")
  BID_OPTION_DELTA?: number;
 
  /** The gamma on the bid price of an option. */
  @property("The gamma on the bid price of an option.")
  BID_OPTION_GAMMA?: number;
 
  /** The vega on the bid price of an option. */
  @property("The vega on the bid price of an option.")
  BID_OPTION_VEGA?: number;
 
  /** The theta on the bid price of an option. */
  @property("The theta on the bid price of an option.")
  BID_OPTION_THETA?: number;
 
  /** The IV on the ask price of an option. */
  @property("The IV on the ask price of an option.")
  ASK_OPTION_IV?: number;
 
  /** The ask price of an option. */
  @property("The ask price of an option.")
  ASK_OPTION_PRICE?: number;
 
  /** The delta on the ask price of an option. */
  @property("The delta on the ask price of an option.")
  ASK_OPTION_DELTA?: number;
 
  /** The gamma on the ask price of an option. */
  @property("The gamma on the ask price of an option.")
  ASK_OPTION_GAMMA?: number;
 
  /** The vega on the ask price of an option. */
  @property("The vega on the ask price of an option.")
  ASK_OPTION_VEGA?: number;
 
  /** The theta on the ask price of an option. */
  @property("The theta on the ask price of an option.")
  ASK_OPTION_THETA?: number;
 
  /** The IV on the last price of an option. */
  @property("The IV on the last price of an option.")
  LAST_OPTION_IV?: number;
 
  /** The last price of an option. */
  @property("The last price of an option.")
  LAST_OPTION_PRICE?: number;
 
  /**The delta on the last price of an option. */
  @property("The delta on the last price of an option.")
  LAST_OPTION_DELTA?: number;
 
  /** The gamma on the last price of an option. */
  @property("The gamma on the last price of an option.")
  LAST_OPTION_GAMMA?: number;
 
  /** The vega on the last price of an option. */
  @property("The vega on the last price of an option.")
  LAST_OPTION_VEGA?: number;
 
  /** The theta on the last price of an option. */
  @property("The theta on the last price of an option.")
  LAST_OPTION_THETA?: number;
 
  /** The IV on the pricing-model of an option. */
  @property("The IV on the pricing-model of an option.")
  MODEL_OPTION_IV?: number;
 
  /** The price on the pricing-model of an option. */
  @property("The price on the pricing-model of an option.")
  MODEL_OPTION_PRICE?: number;
 
  /** The delta on the pricing-model of an option. */
  @property("The delta on the pricing-model of an option.")
  MODEL_OPTION_DELTA?: number;
 
  /** The gamma on the pricing-model of an option. */
  @property("The gamma on the pricing-model of an option.")
  MODEL_OPTION_GAMMA?: number;
 
  /** The vega on the pricing-model of an option. */
  @property("The vega on the pricing-model of an option.")
  MODEL_OPTION_VEGA?: number;
 
  /** The theta on the pricing-model of an option. */
  @property("The theta on the pricing-model of an option.")
  MODEL_OPTION_THETA?: number;
}