vlr_scraper/model/
team.rs1use chrono::NaiveDate;
2use serde::Serialize;
3
4use super::common::{EventPlacement, Social};
5
6#[derive(Debug, Clone, Serialize)]
8pub struct Team {
9 pub info: TeamInfo,
10 pub roster: Vec<TeamRosterMember>,
11 pub event_placements: Vec<EventPlacement>,
12 pub total_winnings: Option<String>,
13}
14
15#[derive(Debug, Clone, Serialize)]
17pub struct TeamInfo {
18 pub id: u32,
19 pub name: String,
20 pub tag: Option<String>,
21 pub logo_url: Option<String>,
22 pub country: Option<String>,
23 pub country_code: Option<String>,
24 pub socials: Vec<Social>,
25}
26
27#[derive(Debug, Clone, Serialize)]
29pub struct TeamRosterMember {
30 pub id: u32,
31 pub slug: String,
32 pub href: String,
33 pub alias: String,
34 pub real_name: Option<String>,
35 pub country_code: Option<String>,
36 pub avatar_url: Option<String>,
37 pub role: String,
38 pub is_captain: bool,
39}
40
41#[derive(Debug, Clone, Serialize)]
43pub struct TeamTransaction {
44 pub date: Option<NaiveDate>,
45 pub action: String,
46 pub player_id: u32,
47 pub player_slug: String,
48 pub player_alias: String,
49 pub player_real_name: Option<String>,
50 pub player_country_code: Option<String>,
51 pub position: String,
52 pub reference_url: Option<String>,
53}
54
55pub type TeamTransactions = Vec<TeamTransaction>;