deriv_api_schema/
contracts_for_company_request.rs

1
2// Generated automatically by schema_generator.rs - DO NOT EDIT.
3// Source: ./deriv-api-docs/config/v3/contracts_for_company/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::landing_company::LandingCompany;
13
14/// Get the list of currently available contracts for a given landing company.
15#[derive(Debug, Clone, Serialize, Deserialize)]
16#[serde(rename_all = "snake_case")]
17pub struct ContractsForCompanyRequest {
18    /// Must be `1`\n
19    // Correct serde attribute construction - Use helper
20    
21    pub contracts_for_company: i64,
22    /// [Optional] Indicates which landing company to get a list of contracts for. If you are logged in, your account's landing company will override this field.\n
23    // Correct serde attribute construction - Use helper
24    #[serde(skip_serializing_if = "Option::is_none")] 
25    pub landing_company: Option<LandingCompany>,
26    /// [Optional] The login id of the user. If left unspecified, it defaults to the initial authorized token's login id.\n
27    // Correct serde attribute construction - Use helper
28    #[serde(skip_serializing_if = "Option::is_none")] 
29    pub loginid: Option<String>,
30    /// [Optional] Used to pass data through the websocket, which may be retrieved via the `echo_req` output field.\n
31    // Correct serde attribute construction - Use helper
32    #[serde(skip_serializing_if = "Option::is_none")] 
33    pub passthrough: Option<Value>,
34    /// [Optional] Used to map request to response.\n
35    // Correct serde attribute construction - Use helper
36    #[serde(skip_serializing_if = "Option::is_none")] 
37    pub req_id: Option<i64>,
38}
39