deriv_api_schema/active_symbols_request.rs
1
2// Generated automatically by schema_generator.rs - DO NOT EDIT.
3// Source: ./deriv-api-docs/config/v3/active_symbols/send.json
4
5// Use direct crate names for imports
6use serde::{Deserialize, Serialize};
7use serde_json::Value;
8
9
10
11// Import required types from the *same* crate
12use crate::contract_type_item::ContractTypeItem;
13use crate::landing_company_short::LandingCompanyShort;
14use crate::barrier_category_item::BarrierCategoryItem;
15use crate::landing_company::LandingCompany;
16
17/// Retrieve a list of all currently active symbols (underlying markets upon which contracts are available for trading).
18#[derive(Debug, Clone, Serialize, Deserialize)]
19#[serde(rename_all = "snake_case")]
20pub struct ActiveSymbolsRequest {
21 /// Field 'active_symbols' mapped to Value due to complexity/potential issues.\n
22 // Correct serde attribute construction - Use helper
23
24 pub active_symbols: Value,
25 /// [Optional] Category of barrier.\n
26 // Correct serde attribute construction - Use helper
27 #[serde(skip_serializing_if = "Option::is_none")]
28 pub barrier_category: Option<Vec<BarrierCategoryItem>>,
29 /// [Optional] The proposed contract type\n
30 // Correct serde attribute construction - Use helper
31 #[serde(skip_serializing_if = "Option::is_none")]
32 pub contract_type: Option<Vec<ContractTypeItem>>,
33 /// Deprecated - replaced by landing_company_short.\n
34 // Correct serde attribute construction - Use helper
35 #[serde(skip_serializing_if = "Option::is_none")]
36 pub landing_company: Option<LandingCompany>,
37 /// [Optional] If you specify this field, only symbols available for trading by that landing company will be returned. If you are logged in, only symbols available for trading by your landing company will be returned regardless of what you specify in this field.\n
38 // Correct serde attribute construction - Use helper
39 #[serde(skip_serializing_if = "Option::is_none")]
40 pub landing_company_short: Option<LandingCompanyShort>,
41 /// [Optional] The login id of the user. Mandatory when multiple tokens were provided during authorize.\n
42 // Correct serde attribute construction - Use helper
43 #[serde(skip_serializing_if = "Option::is_none")]
44 pub loginid: Option<String>,
45 /// [Optional] Used to pass data through the websocket, which may be retrieved via the `echo_req` output field.\n
46 // Correct serde attribute construction - Use helper
47 #[serde(skip_serializing_if = "Option::is_none")]
48 pub passthrough: Option<Value>,
49 /// [Optional] If you specify this field, only symbols that can be traded through that product type will be returned.\n
50 // Correct serde attribute construction - Use helper
51 #[serde(skip_serializing_if = "Option::is_none")]
52 pub product_type: Option<String>,
53 /// [Optional] Used to map request to response.\n
54 // Correct serde attribute construction - Use helper
55 #[serde(skip_serializing_if = "Option::is_none")]
56 pub req_id: Option<i64>,
57}
58