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
use pretty_simple_display::{DebugPretty, DisplaySimple};
use serde::{Deserialize, Serialize};
/// Types of financial instruments available in the IG Markets API
#[repr(u8)]
#[derive(
DebugPretty, Clone, Copy, PartialEq, Eq, Hash, Default, DisplaySimple, Deserialize, Serialize,
)]
#[serde(rename_all = "UPPERCASE")]
pub enum InstrumentType {
/// Binary options
Binary,
/// Bungee capped instruments
#[serde(rename = "BUNGEE_CAPPED")]
BungeeCapped,
/// Bungee commodities instruments
#[serde(rename = "BUNGEE_COMMODITIES")]
BungeeCommodities,
/// Bungee currencies instruments
#[serde(rename = "BUNGEE_CURRENCIES")]
BungeeCurrencies,
/// Bungee indices instruments
#[serde(rename = "BUNGEE_INDICES")]
BungeeIndices,
/// Commodities instruments
Commodities,
/// Currency pairs
Currencies,
/// Market indices
Indices,
/// Knockouts commodities instruments
#[serde(rename = "KNOCKOUTS_COMMODITIES")]
KnockoutsCommodities,
/// Knockouts currencies instruments
#[serde(rename = "KNOCKOUTS_CURRENCIES")]
KnockoutsCurrencies,
/// Knockouts indices instruments
#[serde(rename = "KNOCKOUTS_INDICES")]
KnockoutsIndices,
/// Knockouts shares instruments
#[serde(rename = "KNOCKOUTS_SHARES")]
KnockoutsShares,
/// Options on commodities
#[serde(rename = "OPT_COMMODITIES")]
OptCommodities,
/// Options on currencies
#[serde(rename = "OPT_CURRENCIES")]
OptCurrencies,
/// Options on indices
#[serde(rename = "OPT_INDICES")]
OptIndices,
/// Options on rates
#[serde(rename = "OPT_RATES")]
OptRates,
/// Options on shares
#[serde(rename = "OPT_SHARES")]
OptShares,
/// Interest rates
Rates,
/// Market sectors
Sectors,
/// Stocks and shares
Shares,
/// Sprint market instruments
#[serde(rename = "SPRINT_MARKET")]
SprintMarket,
/// Test market instruments
#[serde(rename = "TEST_MARKET")]
TestMarket,
/// Unknown instrument type
Unknown,
/// Options
#[default]
Options,
}