mcapi 0.3.1

Unified async Rust client for the Minecraft ecosystem (Mojang, Modrinth, CurseForge, Yggdrasil, Blessing Skin, Loaders, BMCLAPI, and Java Runtimes)
Documentation
use std::collections::HashMap;

use serde::{Deserialize, Serialize};

/// Global Modrinth instance statistics returned by `GET /v2/statistics`.
#[derive(Clone, Debug, Deserialize, Serialize, Eq, PartialEq)]
pub struct Statistics {
    pub projects: u64,
    pub versions: u64,
    pub files: u64,
    pub authors: u64,
}

/// Forge update checker JSON returned by `GET /updates/{id|slug}/forge_updates.json`.
#[derive(Clone, Debug, Deserialize, Serialize, Eq, PartialEq)]
pub struct ForgeUpdates {
    #[serde(default)]
    pub homepage: Option<String>,
    #[serde(default)]
    pub promos: ForgePromos,
}

/// Map of `"<mcVersion>-latest"` / `"<mcVersion>-recommended"` to mod version strings.
pub type ForgePromos = HashMap<String, String>;