swgoh-gg 1.0.0

API Bindings for swgoh.gg
Documentation
//! Types related to Guilds

use serde::{Deserialize, Serialize};

#[derive(Debug, Deserialize, Serialize)]
pub struct Profile {
    pub data: Data,

    // TODO just a guess on this type
    pub message: Option<String>,

    // TODO just a guess on this type
    pub total_count: Option<i64>,

    // TODO just a guess on this type
    pub error_key: Option<String>,
}

#[derive(Debug, Deserialize, Serialize)]
pub struct Data {
    pub guild_id: String,
    pub name: String,
    pub external_message: String,
    pub banner_color_id: String,
    pub banner_logo_id: String,
    pub enrollment_status: u64,
    pub galactic_power: u64,
    /// as far as I can tell this one is no longer in use
    /// just ignore no
    pub guild_type: Option<String>,
    pub level_requirement: u64,
    pub member_count: u64,
    pub members: Vec<Member>,
    pub avg_galactic_power: u64,
    pub avg_arena_rank: f32,
    pub avg_fleet_arena_rank: f32,
    pub avg_skill_rating: u64,
    pub last_sync: String,
}

#[derive(Debug, Deserialize, Serialize)]
pub struct Member {
    pub player_id: String,
    pub galactic_power: u64,
    pub guild_join_time: String,
    pub lifetime_season_score: u64,
    pub member_level: u64,
    pub ally_code: u64,
    pub player_level: u64,
    pub player_name: String,
    pub league_id: String,
    pub league_name: String,
    pub league_frame_image: String,
    pub portrait_image: String,
    pub title: String,
    pub squad_power: u64,
}