ccdata_api/schemas/
data_api.rs

1pub mod indices_and_reference_rates;
2pub mod spot;
3pub mod futures;
4pub mod options;
5pub mod derivatives_indices;
6pub mod on_chain_dex;
7pub mod on_chain_core;
8pub mod asset;
9pub mod news;
10pub mod overview;
11
12
13use serde::Deserialize;
14
15
16#[derive(Deserialize, Debug)]
17pub struct CCPreviousAssetSymbol {
18    #[serde(rename = "SYMBOL")]
19    /// A symbol this asset was previously associated with.
20    pub symbol: Option<String>,
21    #[serde(rename = "SYMBOL_USAGE_START_DATE")]
22    /// Indicates the date this past symbol started being used.
23    pub symbol_usage_start_date: Option<i64>,
24    #[serde(rename = "SYMBOL_USAGE_END_DATE")]
25    /// Indicates the date this past symbol stopped being used.
26    pub symbol_usage_end_date: Option<i64>,
27    #[serde(rename = "DESCRIPTION")]
28    /// A description for why this symbol existed or was changed.
29    pub description: Option<String>,
30}
31
32
33#[derive(Deserialize, Debug)]
34pub struct CCAssetAlternativeId {
35    #[serde(rename = "NAME")]
36    pub name: Option<String>,
37    #[serde(skip_deserializing)]
38    #[serde(rename = "ID")]
39    pub id: Option<String>,
40}
41
42
43#[derive(Deserialize, Debug)]
44pub struct CCAssetIndustry {
45    #[serde(rename = "ASSET_INDUSTRY")]
46    pub asset_industry: Option<String>,
47    #[serde(rename = "JUSTIFICATION")]
48    /// A justification for putting an asset in this industry.
49    pub justification: Option<String>,
50}
51
52
53#[derive(Deserialize, Debug)]
54pub struct CCSpecialAddress {
55    #[serde(rename = "NAME")]
56    /// The name of the address. Contract name or just the common name for this address.
57    pub name: Option<String>,
58    #[serde(rename = "BLOCKCHAIN")]
59    /// The is linked to the asset representing a specific chain.
60    pub blockchain: Option<String>,
61    #[serde(rename = "ADDRESS")]
62    /// The address of the smart contracts, external user accounts or other account.
63    pub address: Option<String>,
64    #[serde(rename = "DESCRIPTION")]
65    /// A description for the address.
66    pub description: Option<String>,
67}
68
69
70#[derive(Deserialize, Debug)]
71pub struct CCInstrumentStatus {
72    #[serde(rename = "ACTIVE")]
73    /// The total number of instruments currently available on the market, which are considered active. An active instrument is defined as an instrument
74    /// from which we retrieve data and have either already mapped or are planning to map.
75    pub active: i64,
76    #[serde(rename = "IGNORED")]
77    /// The total number of instruments available on the market that are classified as ignored, meaning that we do not plan to map them.
78    /// Ignored instruments are those from which we do retrieve data but do not have any intention to map.
79    pub ignored: i64,
80    #[serde(rename = "RETIRED")]
81    /// The total number of instruments that are classified as retired, meaning that they are no longer actively traded on the market.
82    /// These instruments have ceased trading, and as such, we do not retrieve data from them but we have mapped them already.
83    pub retired: i64,
84    #[serde(rename = "EXPIRED")]
85    /// The total number of instruments that are classified as expired, meaning that they are mapped instruments that are no longer actively traded on the market.
86    /// These expired instruments are typically futures or options instruments that have reached their expiration date and are no longer available for trading.
87    /// While we have previously mapped these instruments, we do not retrieve any data from them since they are no longer actively traded.
88    pub expired: i64,
89    #[serde(rename = "undefined")]
90    pub undefined: Option<i64>,
91}