deriv_api_schema/
candle_item.rs

1
2// Generated automatically by schema_generator.rs - DO NOT EDIT.
3// Source: ./deriv-api-docs/config/v3/ticks_history/receive.json
4
5// Use direct crate names for imports within generated files
6use serde::{Deserialize, Serialize}; 
7
8
9use chrono::{DateTime, Utc};
10
11// Import shared types from the *same* crate
12
13// It's a struct
14#[derive(Debug, Clone, Serialize, Deserialize)]
15#[serde(rename_all = "snake_case")]
16pub struct CandleItem {
17    /// It is the close price value for the given time\n
18    // Correct serde attribute construction - Use helper
19    #[serde(skip_serializing_if = "Option::is_none")] 
20    pub close: Option<String>,
21    /// It is an epoch value\n
22    // Correct serde attribute construction - Use helper
23    #[serde(skip_serializing_if = "Option::is_none")] 
24    pub epoch: Option<DateTime<Utc>>,
25    /// It is the high price value for the given time\n
26    // Correct serde attribute construction - Use helper
27    #[serde(skip_serializing_if = "Option::is_none")] 
28    pub high: Option<String>,
29    /// It is the low price value for the given time\n
30    // Correct serde attribute construction - Use helper
31    #[serde(skip_serializing_if = "Option::is_none")] 
32    pub low: Option<String>,
33    /// It is the open price value for the given time\n
34    // Correct serde attribute construction - Use helper
35    #[serde(skip_serializing_if = "Option::is_none")] 
36    pub open: Option<String>,
37}
38