riot_api/models/league/
current_game_info.rs

1use serde::Deserialize;
2
3#[derive(Debug, Deserialize)]
4#[serde(rename_all = "camelCase")]
5pub struct CurrentGameInfoDto {
6    pub game_id: i64,
7    pub game_type: String,
8    pub game_start_time: i64,
9    pub map_id: i64,
10    pub game_length: i64,
11    pub platform_id: String,
12    pub game_mode: String,
13    pub banned_champions: Vec<BannedChampion>,
14    pub game_queue_config_id: Option<i64>,
15    pub observers: Observer,
16}
17
18#[derive(Debug, Deserialize)]
19#[serde(rename_all = "camelCase")]
20pub struct BannedChampion {
21    pub pick_turn: i32,
22    pub champion_id: i64,
23    pub team_id: i64,
24}
25
26#[derive(Debug, Deserialize)]
27#[serde(rename_all = "camelCase")]
28pub struct Observer {
29    pub encryption_key: String,
30}
31
32#[derive(Debug, Deserialize)]
33#[serde(rename_all = "camelCase")]
34pub struct CurrentGameParticipant {
35    pub champion_id: i64,
36    pub perks: Perks,
37    pub profile_icon_id: i64,
38    pub bot: bool,
39    pub team_id: i64,
40    pub summoner_name: String,
41    pub summoner_id: String,
42    pub spell1_id: i64,
43    pub spell2_id: i64,
44    pub game_customization_objects: Vec<GameCustomizationObject>,
45    pub puuid: Option<String>,
46}
47
48#[derive(Debug, Deserialize)]
49#[serde(rename_all = "camelCase")]
50pub struct Perks {
51    pub perk_ids: Vec<i64>,
52    pub perks_type: i64,
53    pub perk_sub_style: i64,
54}
55
56#[derive(Debug, Deserialize)]
57#[serde(rename_all = "camelCase")]
58pub struct GameCustomizationObject {
59    pub category: String,
60    pub content: String,
61}