deriv_api_schema/ticks_batch_response.rs
1
2// Generated automatically by schema_generator.rs - DO NOT EDIT.
3// Source: ./deriv-api-docs/config/v3/ticks_batch/receive.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::subscription::Subscription;
13use crate::ticks_batch_item::TicksBatchItem;
14
15/// Latest spot price for a group symbols. Continuous responses with a frequency of up to one second.
16#[derive(Debug, Clone, Serialize, Deserialize)]
17#[serde(rename_all = "snake_case")]
18pub struct TicksBatchResponse {
19 /// Echo of the request made.\n
20 // Correct serde attribute construction - Use helper
21
22 pub echo_req: Value,
23 /// Action name of the request made.\n
24 // Correct serde attribute construction - Use helper
25
26 pub msg_type: String,
27 /// Optional field sent in request to map to response, present only when request contains `req_id`.\n
28 // Correct serde attribute construction - Use helper
29 #[serde(skip_serializing_if = "Option::is_none")]
30 pub req_id: Option<i64>,
31 /// For subscription requests only.\n
32 // Correct serde attribute construction - Use helper
33 #[serde(skip_serializing_if = "Option::is_none")]
34 pub subscription: Option<Subscription>,
35 /// Tick by tick list of streamed data for a group of symbols\n
36 // Correct serde attribute construction - Use helper
37 #[serde(skip_serializing_if = "Option::is_none")]
38 pub ticks_batch: Option<Vec<TicksBatchItem>>,
39}
40