1use std::collections::HashMap;
2use serde::Deserialize;
3use crate::utils::Market;
4use crate::schemas::data_api::CCInstrumentStatus;
5
6
7pub enum CCSpotMarket {
9 AAX,
10 ABCC,
11 ACX,
12 AIDOSMARKET,
13 ALPHAEX,
14 ARCHAX,
15 ASCENDEX,
16 ATAIX,
17 BACKPACK,
18 BEQUANT,
19 BGOGO,
20 BIBOX365,
21 BIGONE,
22 BILAXY,
23 BINANCE,
24 BINANCEAGGREGATE,
25 BINANCETR,
26 BINANCEUSA,
27 BINGX,
28 BISQ,
29 BIT,
30 BIT2C,
31 BITBANK,
32 BITBAY,
33 BITBNS,
34 BITBUY,
35 BITCI,
36 BITEXBOOK,
37 BITFEX,
38 BITFINEX,
39 BITFLYER,
40 BITFLYEREU,
41 BITFLYERFX,
42 BITFLYERUS,
43 BITFOREX,
44 BITGET,
45 BITHUMBGLOBAL,
46 BITHUMBKOREA,
47 BITINKA,
48 BITKUB,
49 BITMART,
50 BITMEX,
51 BITPANDA,
52 BITRUE,
53 BITSO,
54 BITSTAMP,
55 BITTREX,
56 BITVAVO,
57 BKEX,
58 BLACKTURTLE,
59 BLEUTRADE,
60 BLOCKCHAINCOM,
61 BTCALPHA,
62 BTCBOX,
63 BTCEX,
64 BTCMARKETS,
65 BTCTURK,
66 BTSE,
67 BUDA,
68 BULLISH,
69 BUYUCOIN,
70 BWEXCHANGE,
71 BYBIT,
72 BYDFI,
73 CATEX,
74 CEXIO,
75 COINBASE,
76 COINBASEINTERNATIONAL,
77 COINCHECK,
78 COINCORNER,
79 COINDCX,
80 COINDEAL,
81 COINEX,
82 COINFALCON,
83 COINFIELD,
84 COINJAR,
85 COINMATE,
86 COINONE,
87 COINSBIT,
88 COINSPRO,
89 COINTIGER,
90 COINW,
91 COSS,
92 CREX24,
93 CROSSTOWER,
94 CRYPTOCARBON,
95 CRYPTODOTCOM,
96 CRYPTOPIA,
97 CRYPTSY,
98 CUBE,
99 CURRENCY,
100 DCOIN,
101 DDEX,
102 DECOIN,
103 DERIBIT,
104 DIGIFINEX,
105 ERISX,
106 ETORO,
107 EXMO,
108 FCOIN,
109 FOXBIT,
110 FTX,
111 FTXUS,
112 GARANTEX,
113 GATEIO,
114 GEMINI,
115 GLOBITEX,
116 GOPAX,
117 GRAVIEX,
118 HASHKEY,
119 HITBTC,
120 HUOBIJAPAN,
121 HUOBIPRO,
122 INDEPENDENTRESERVE,
123 INDODAX,
124 INDOEX,
125 INX,
126 ITBIT,
127 KORBIT,
128 KRAKEN,
129 KUCOIN,
130 KUNA,
131 LATOKEN,
132 LBANK,
133 LIQNET,
134 LIQUID,
135 LITEBIT,
136 LMAX,
137 LUNO,
138 LYKKE,
139 MERCADOBTC,
140 MERCATOX,
141 MEXC,
142 MOCK,
143 MTGOX,
144 NDAX,
145 NOMINEX,
146 OKCOIN,
147 OKEX,
148 ONETRADING,
149 OSL,
150 OSLHONGKONG,
151 P2PB2B,
152 PANCAKESWAP,
153 PARAMOUNTDAX,
154 PARIBU,
155 PHEMEX,
156 POLONIEX,
157 PROBIT,
158 SAFETRADE,
159 SIGENPRO,
160 SIMEX,
161 SWITCHEO,
162 THEROCKTRADING,
163 TIDEFI,
164 TIMEX,
165 TOKENOMY,
166 TRADEOGRE,
167 UNISWAP,
168 UNOCOIN,
169 UPBIT,
170 VALR,
171 VITEX,
172 WAZIRX,
173 WHITEBIT,
174 WOO,
175 XCOEX,
176 XTPUB,
177 YELLOW,
178 YOBIT,
179 ZAIF,
180 ZBDOTCOM,
181 ZBG,
182 ZEBITEX,
183 ZONDA,
184}
185
186impl Market for CCSpotMarket {
187 fn to_string(&self) -> String {
189 match self {
190 CCSpotMarket::AAX => String::from("aax"),
191 CCSpotMarket::ABCC => String::from("abcc"),
192 CCSpotMarket::ACX => String::from("acx"),
193 CCSpotMarket::AIDOSMARKET => String::from("aidosmarket"),
194 CCSpotMarket::ALPHAEX => String::from("alphaex"),
195 CCSpotMarket::ARCHAX => String::from("archax"),
196 CCSpotMarket::ASCENDEX => String::from("ascendex"),
197 CCSpotMarket::ATAIX => String::from("ataix"),
198 CCSpotMarket::BACKPACK => String::from("backpack"),
199 CCSpotMarket::BEQUANT => String::from("bequant"),
200 CCSpotMarket::BGOGO => String::from("bgogo"),
201 CCSpotMarket::BIBOX365 => String::from("bibox365"),
202 CCSpotMarket::BIGONE => String::from("bigone"),
203 CCSpotMarket::BILAXY => String::from("bilaxy"),
204 CCSpotMarket::BINANCE => String::from("binance"),
205 CCSpotMarket::BINANCEAGGREGATE => String::from("binanceaggreagate"),
206 CCSpotMarket::BINANCETR => String::from("binancetr"),
207 CCSpotMarket::BINANCEUSA => String::from("binanceusa"),
208 CCSpotMarket::BINGX => String::from("bingx"),
209 CCSpotMarket::BISQ => String::from("bisq"),
210 CCSpotMarket::BIT => String::from("bit"),
211 CCSpotMarket::BIT2C => String::from("bit2c"),
212 CCSpotMarket::BITBANK => String::from("bitbank"),
213 CCSpotMarket::BITBAY => String::from("bitbay"),
214 CCSpotMarket::BITBNS => String::from("bitbns"),
215 CCSpotMarket::BITBUY => String::from("bitbuy"),
216 CCSpotMarket::BITCI => String::from("bitci"),
217 CCSpotMarket::BITEXBOOK => String::from("bitexbook"),
218 CCSpotMarket::BITFEX => String::from("bitfex"),
219 CCSpotMarket::BITFINEX => String::from("bitfinex"),
220 CCSpotMarket::BITFLYER => String::from("bitflyer"),
221 CCSpotMarket::BITFLYEREU => String::from("bitflyereu"),
222 CCSpotMarket::BITFLYERFX => String::from("bitflyerfx"),
223 CCSpotMarket::BITFLYERUS => String::from("bitflyerus"),
224 CCSpotMarket::BITFOREX => String::from("bitforex"),
225 CCSpotMarket::BITGET => String::from("bitget"),
226 CCSpotMarket::BITHUMBGLOBAL => String::from("bithumbglobal"),
227 CCSpotMarket::BITHUMBKOREA => String::from("bithumbkorea"),
228 CCSpotMarket::BITINKA => String::from("bitinka"),
229 CCSpotMarket::BITKUB => String::from("bitkub"),
230 CCSpotMarket::BITMART => String::from("bitmart"),
231 CCSpotMarket::BITMEX => String::from("bitmex"),
232 CCSpotMarket::BITPANDA => String::from("bitpanda"),
233 CCSpotMarket::BITRUE => String::from("bitrue"),
234 CCSpotMarket::BITSO => String::from("bitso"),
235 CCSpotMarket::BITSTAMP => String::from("bitstamp"),
236 CCSpotMarket::BITTREX => String::from("bittrex"),
237 CCSpotMarket::BITVAVO => String::from("bitvavo"),
238 CCSpotMarket::BKEX => String::from("bkex"),
239 CCSpotMarket::BLACKTURTLE => String::from("blackturtle"),
240 CCSpotMarket::BLEUTRADE => String::from("bleutrade"),
241 CCSpotMarket::BLOCKCHAINCOM => String::from("blockchaindotcom"),
242 CCSpotMarket::BTCALPHA => String::from("btcalpha"),
243 CCSpotMarket::BTCBOX => String::from("btcbox"),
244 CCSpotMarket::BTCEX => String::from("btcex"),
245 CCSpotMarket::BTCMARKETS => String::from("btcmarkets"),
246 CCSpotMarket::BTCTURK => String::from("btcturk"),
247 CCSpotMarket::BTSE => String::from("btse"),
248 CCSpotMarket::BUDA => String::from("buda"),
249 CCSpotMarket::BULLISH => String::from("bullish"),
250 CCSpotMarket::BUYUCOIN => String::from("buyucoin"),
251 CCSpotMarket::BWEXCHANGE => String::from("bwexchange"),
252 CCSpotMarket::BYBIT => String::from("bybit"),
253 CCSpotMarket::BYDFI => String::from("bydfi"),
254 CCSpotMarket::CATEX => String::from("catex"),
255 CCSpotMarket::CEXIO => String::from("cexio"),
256 CCSpotMarket::COINBASE => String::from("coinbase"),
257 CCSpotMarket::COINBASEINTERNATIONAL => String::from("coinbaseinternational"),
258 CCSpotMarket::COINCHECK => String::from("coincheck"),
259 CCSpotMarket::COINCORNER => String::from("coincorner"),
260 CCSpotMarket::COINDCX => String::from("coindcx"),
261 CCSpotMarket::COINDEAL => String::from("coindeal"),
262 CCSpotMarket::COINEX => String::from("coinex"),
263 CCSpotMarket::COINFALCON => String::from("coinfalcon"),
264 CCSpotMarket::COINFIELD => String::from("coinfield"),
265 CCSpotMarket::COINJAR => String::from("coinjar"),
266 CCSpotMarket::COINMATE => String::from("coinmate"),
267 CCSpotMarket::COINONE => String::from("coinone"),
268 CCSpotMarket::COINSBIT => String::from("coinsbit"),
269 CCSpotMarket::COINSPRO => String::from("coinspro"),
270 CCSpotMarket::COINTIGER => String::from("cointiger"),
271 CCSpotMarket::COINW => String::from("coinw"),
272 CCSpotMarket::COSS => String::from("coss"),
273 CCSpotMarket::CREX24 => String::from("crex24"),
274 CCSpotMarket::CROSSTOWER => String::from("crosstower"),
275 CCSpotMarket::CRYPTOCARBON => String::from("cryptocarbon"),
276 CCSpotMarket::CRYPTODOTCOM => String::from("cryptodotcom"),
277 CCSpotMarket::CRYPTOPIA => String::from("cryptopia"),
278 CCSpotMarket::CRYPTSY => String::from("cryptsy"),
279 CCSpotMarket::CUBE => String::from("cube"),
280 CCSpotMarket::CURRENCY => String::from("currency"),
281 CCSpotMarket::DCOIN => String::from("dcoin"),
282 CCSpotMarket::DDEX => String::from("ddex"),
283 CCSpotMarket::DECOIN => String::from("decoin"),
284 CCSpotMarket::DERIBIT => String::from("deribit"),
285 CCSpotMarket::DIGIFINEX => String::from("digifinex"),
286 CCSpotMarket::ERISX => String::from("erisx"),
287 CCSpotMarket::ETORO => String::from("etoro"),
288 CCSpotMarket::EXMO => String::from("exmo"),
289 CCSpotMarket::FCOIN => String::from("fcoin"),
290 CCSpotMarket::FOXBIT => String::from("foxbit"),
291 CCSpotMarket::FTX => String::from("ftx"),
292 CCSpotMarket::FTXUS => String::from("ftxus"),
293 CCSpotMarket::GARANTEX => String::from("garantex"),
294 CCSpotMarket::GATEIO => String::from("gateio"),
295 CCSpotMarket::GEMINI => String::from("gemini"),
296 CCSpotMarket::GLOBITEX => String::from("globitex"),
297 CCSpotMarket::GOPAX => String::from("gopax"),
298 CCSpotMarket::GRAVIEX => String::from("graviex"),
299 CCSpotMarket::HASHKEY => String::from("hashkey"),
300 CCSpotMarket::HITBTC => String::from("hitbtc"),
301 CCSpotMarket::HUOBIJAPAN => String::from("huobijapan"),
302 CCSpotMarket::HUOBIPRO => String::from("huobipro"),
303 CCSpotMarket::INDEPENDENTRESERVE => String::from("independentreserve"),
304 CCSpotMarket::INDODAX => String::from("indodax"),
305 CCSpotMarket::INDOEX => String::from("indoex"),
306 CCSpotMarket::INX => String::from("inx"),
307 CCSpotMarket::ITBIT => String::from("itbit"),
308 CCSpotMarket::KORBIT => String::from("korbit"),
309 CCSpotMarket::KRAKEN => String::from("kraken"),
310 CCSpotMarket::KUCOIN => String::from("kucoin"),
311 CCSpotMarket::KUNA => String::from("kuna"),
312 CCSpotMarket::LATOKEN => String::from("latoken"),
313 CCSpotMarket::LBANK => String::from("lbank"),
314 CCSpotMarket::LIQNET => String::from("liqnet"),
315 CCSpotMarket::LIQUID => String::from("liquid"),
316 CCSpotMarket::LITEBIT => String::from("litebit"),
317 CCSpotMarket::LMAX => String::from("lmax"),
318 CCSpotMarket::LUNO => String::from("luno"),
319 CCSpotMarket::LYKKE => String::from("lykke"),
320 CCSpotMarket::MERCADOBTC => String::from("mercadobtc"),
321 CCSpotMarket::MERCATOX => String::from("mercatox"),
322 CCSpotMarket::MEXC => String::from("mexc"),
323 CCSpotMarket::MOCK => String::from("mock"),
324 CCSpotMarket::MTGOX => String::from("mtgox"),
325 CCSpotMarket::NDAX => String::from("ndax"),
326 CCSpotMarket::NOMINEX => String::from("nominex"),
327 CCSpotMarket::OKCOIN => String::from("okcoin"),
328 CCSpotMarket::OKEX => String::from("okex"),
329 CCSpotMarket::ONETRADING => String::from("onetrading"),
330 CCSpotMarket::OSL => String::from("osl"),
331 CCSpotMarket::OSLHONGKONG => String::from("oslhongkong"),
332 CCSpotMarket::P2PB2B => String::from("p2pb2b"),
333 CCSpotMarket::PANCAKESWAP => String::from("pancakeswap"),
334 CCSpotMarket::PARAMOUNTDAX => String::from("paramountdax"),
335 CCSpotMarket::PARIBU => String::from("paribu"),
336 CCSpotMarket::PHEMEX => String::from("phemex"),
337 CCSpotMarket::POLONIEX => String::from("poloniex"),
338 CCSpotMarket::PROBIT => String::from("probit"),
339 CCSpotMarket::SAFETRADE => String::from("safetrade"),
340 CCSpotMarket::SIGENPRO => String::from("sigenpro"),
341 CCSpotMarket::SIMEX => String::from("simex"),
342 CCSpotMarket::SWITCHEO => String::from("switcheo"),
343 CCSpotMarket::THEROCKTRADING => String::from("therocktrading"),
344 CCSpotMarket::TIDEFI => String::from("tidefi"),
345 CCSpotMarket::TIMEX => String::from("timex"),
346 CCSpotMarket::TOKENOMY => String::from("tokenomy"),
347 CCSpotMarket::TRADEOGRE => String::from("tradeogre"),
348 CCSpotMarket::UNISWAP => String::from("uniswap"),
349 CCSpotMarket::UNOCOIN => String::from("unocoin"),
350 CCSpotMarket::UPBIT => String::from("upbit"),
351 CCSpotMarket::VALR => String::from("valr"),
352 CCSpotMarket::VITEX => String::from("vitex"),
353 CCSpotMarket::WAZIRX => String::from("waxirx"),
354 CCSpotMarket::WHITEBIT => String::from("whitebit"),
355 CCSpotMarket::WOO => String::from("woo"),
356 CCSpotMarket::XCOEX => String::from("xcoex"),
357 CCSpotMarket::XTPUB => String::from("xtpub"),
358 CCSpotMarket::YELLOW => String::from("yellow"),
359 CCSpotMarket::YOBIT => String::from("yobit"),
360 CCSpotMarket::ZAIF => String::from("zaif"),
361 CCSpotMarket::ZBDOTCOM => String::from("zbdotcom"),
362 CCSpotMarket::ZBG => String::from("zbg"),
363 CCSpotMarket::ZEBITEX => String::from("zebitex"),
364 CCSpotMarket::ZONDA => String::from("zonda"),
365 }
366 }
367}
368
369
370pub enum CCSpotInstrumentStatus {
372 ACTIVE,
373 IGNORED,
374 RETIRED,
375 EXPIRED,
376 READYFORDECOMMISSIONING,
377}
378
379impl CCSpotInstrumentStatus {
380 pub fn to_string(&self) -> String {
382 match self {
383 CCSpotInstrumentStatus::ACTIVE => String::from("ACTIVE"),
384 CCSpotInstrumentStatus::IGNORED => String::from("IGNORED"),
385 CCSpotInstrumentStatus::RETIRED => String::from("RETIRED"),
386 CCSpotInstrumentStatus::EXPIRED => String::from("EXPIRED"),
387 CCSpotInstrumentStatus::READYFORDECOMMISSIONING => String::from("READY_FOR_DECOMMISSIONING"),
388 }
389 }
390}
391
392
393#[derive(Deserialize, Debug)]
394pub struct CCInstrumentMapping {
395 #[serde(rename = "MAPPED_INSTRUMENT")]
396 pub mapped_instrument: String,
398 #[serde(rename = "BASE")]
399 pub base: String,
401 #[serde(rename = "BASE_ID")]
402 pub base_id: i32,
405 #[serde(rename = "QUOTE")]
406 pub quote: String,
408 #[serde(rename = "QUOTE_ID")]
409 pub quote_id: i32,
412 #[serde(rename = "TRANSFORM_FUNCTION")]
413 pub transform_function: String,
415 #[serde(rename = "CREATED_ON")]
416 pub created_on: i64,
418}
419
420
421#[derive(Deserialize, Debug)]
426pub struct CCSpotOHLCV {
427 #[serde(rename = "UNIT")]
428 pub unit: String,
430 #[serde(rename = "TIMESTAMP")]
431 pub timestamp: i64,
434 #[serde(rename = "TYPE")]
435 pub type_: String,
437 #[serde(rename = "MARKET")]
438 pub market: String,
440 #[serde(rename = "INSTRUMENT")]
441 pub instrument: String,
443 #[serde(rename = "MAPPED_INSTRUMENT")]
444 pub mapped_instrument: String,
446 #[serde(rename = "BASE")]
447 pub base: String,
450 #[serde(rename = "QUOTE")]
451 pub quote: String,
454 #[serde(rename = "BASE_ID")]
455 pub base_id: i32,
458 #[serde(rename = "QUOTE_ID")]
459 pub quote_id: i32,
462 #[serde(rename = "TRANSFORM_FUNCTION")]
463 pub transform_function: String,
466 #[serde(rename = "OPEN")]
467 pub open: f64,
469 #[serde(rename = "HIGH")]
470 pub high: f64,
472 #[serde(rename = "LOW")]
473 pub low: f64,
475 #[serde(rename = "CLOSE")]
476 pub close: f64,
478 #[serde(rename = "FIRST_TRADE_TIMESTAMP")]
479 pub first_trade_timestamp: Option<i64>,
481 #[serde(rename = "LAST_TRADE_TIMESTAMP")]
482 pub last_trade_timestamp: Option<i64>,
484 #[serde(rename = "FIRST_TRADE_PRICE")]
485 pub first_trade_price: Option<f64>,
487 #[serde(rename = "HIGH_TRADE_PRICE")]
488 pub high_trade_price: Option<f64>,
490 #[serde(rename = "HIGH_TRADE_TIMESTAMP")]
491 pub high_trade_timestamp: Option<i64>,
493 #[serde(rename = "LOW_TRADE_PRICE")]
494 pub low_trade_price: Option<f64>,
496 #[serde(rename = "LOW_TRADE_TIMESTAMP")]
497 pub low_trade_timestamp: Option<i64>,
499 #[serde(rename = "LAST_TRADE_PRICE")]
500 pub last_trade_price: Option<f64>,
502 #[serde(rename = "TOTAL_TRADES")]
503 pub total_trades: i64,
505 #[serde(rename = "TOTAL_TRADES_BUY")]
506 pub total_trades_buy: i64,
508 #[serde(rename = "TOTAL_TRADES_SELL")]
509 pub total_trades_sell: i64,
511 #[serde(rename = "TOTAL_TRADES_UNKNOWN")]
512 pub total_trades_unknown: i64,
514 #[serde(rename = "VOLUME")]
515 pub volume: f64,
518 #[serde(rename = "QUOTE_VOLUME")]
519 pub quote_volume: f64,
522 #[serde(rename = "VOLUME_BUY")]
523 pub volume_buy: f64,
525 #[serde(rename = "QUOTE_VOLUME_BUY")]
526 pub quote_volume_buy: f64,
528 #[serde(rename = "VOLUME_SELL")]
529 pub volume_sell: f64,
531 #[serde(rename = "QUOTE_VOLUME_SELL")]
532 pub quote_volume_sell: f64,
534 #[serde(rename = "VOLUME_UNKNOWN")]
535 pub volume_unknown: f64,
537 #[serde(rename = "QUOTE_VOLUME_UNKNOWN")]
538 pub quote_volume_unknown: f64,
540}
541
542
543#[derive(Deserialize, Debug)]
548pub struct CCSpotInstrumentMetdata {
549 #[serde(rename = "METADATA_VERSION")]
550 pub metadata_version: usize,
552 #[serde(rename = "INSTRUMENT_STATUS")]
553 pub instrument_status: String,
556 #[serde(rename = "FIRST_SEEN_ON_POLLING_TS")]
557 pub first_seen_on_pollings_ts: i64,
559 #[serde(rename = "LAST_SEEN_ON_POLLING_TS")]
560 pub last_seen_pollings_ts: i64,
562 #[serde(rename = "INSTRUMENT")]
563 pub instrument: String,
565 #[serde(rename = "INSTRUMENT_MAPPING")]
566 pub instrument_mapping: CCInstrumentMapping,
568 #[serde(rename = "INSTRUMENT_EXTERNAL_DATA")]
569 pub instrument_external_data: String,
571 #[serde(rename = "FIRST_OB_L2_MINUTE_SNAPSHOT_TS")]
572 pub first_ob_l2_minute_snapshot_ts: Option<i64>,
574}
575
576
577#[derive(Deserialize, Debug)]
582pub struct CCSpotMarkets {
583 #[serde(rename = "TYPE")]
584 pub type_: String,
586 #[serde(rename = "EXCHANGE_STATUS")]
587 pub exchange_status: String,
589 #[serde(rename = "MAPPED_INSTRUMENTS_TOTAL")]
590 pub mapped_instrument_total: i64,
594 #[serde(rename = "UNMAPPED_INSTRUMENTS_TOTAL")]
595 pub unmapped_instruments_total: i64,
597 #[serde(rename = "INSTRUMENT_STATUS")]
598 pub instrument_status: CCInstrumentStatus,
600 #[serde(rename = "TOTAL_TRADES_SPOT")]
601 pub total_trades_spot: i64,
603 #[serde(rename = "HAS_ORDERBOOK_L2_MINUTE_SNAPSHOTS_ENABLED")]
604 pub has_orderbook_l2_minute_snapshots_enabled: bool,
606}
607
608
609#[derive(Deserialize, Debug)]
613pub struct CCInstrument {
614 #[serde(rename = "TYPE")]
615 pub type_: String,
617 #[serde(rename = "INSTRUMENT_STATUS")]
618 pub instrument_status: String,
620 #[serde(rename = "INSTRUMENT")]
621 pub instrument: String,
623 #[serde(rename = "HISTO_SHARD")]
624 pub histo_shard: String,
627 #[serde(rename = "MAPPED_INSTRUMENT")]
628 pub mapped_instrument: String,
630 #[serde(rename = "INSTRUMENT_MAPPING")]
631 pub instrument_mapping: CCInstrumentMapping,
633 #[serde(rename = "HAS_TRADES_SPOT")]
634 pub has_trades_spot: bool,
636 #[serde(rename = "FIRST_TRADE_SPOT_TIMESTAMP")]
637 pub first_trade_spot_timestamp: i64,
639 #[serde(rename = "LAST_TRADE_SPOT_TIMESTAMP")]
640 pub last_trade_spot_timestamp: i64,
642 #[serde(rename = "TOTAL_TRADES_SPOT")]
643 pub total_trades_spot: i64,
645}
646
647
648#[derive(Deserialize, Debug)]
650pub struct CCSpotMarketsInstruments {
651 #[serde(rename = "TYPE")]
652 pub type_: String,
654 #[serde(rename = "EXCHANGE_STATUS")]
655 pub exchange_status: String,
657 #[serde(rename = "MAPPED_INSTRUMENTS_TOTAL")]
658 pub mapped_instrument_total: i64,
662 #[serde(rename = "UNMAPPED_INSTRUMENTS_TOTAL")]
663 pub unmapped_instruments_total: i64,
665 #[serde(rename = "INSTRUMENT_STATUS")]
666 pub instrument_status: CCInstrumentStatus,
668 #[serde(rename = "TOTAL_TRADES_SPOT")]
669 pub total_trades_spot: i64,
671 #[serde(rename = "HAS_ORDERBOOK_L2_MINUTE_SNAPSHOTS_ENABLED")]
672 pub has_orderbook_l2_minute_snapshots_enabled: bool,
674 #[serde(rename = "instruments")]
675 pub instruments: HashMap<String, CCInstrument>,
677}