Update Modrinth API objects

This commit is contained in:
mars 2022-08-13 18:01:44 -06:00
parent ea28b0c904
commit 44a81cf148
1 changed files with 9 additions and 2 deletions

View File

@ -80,7 +80,7 @@ pub struct ModInfo {
pub source_url: Option<String>,
pub wiki_url: Option<String>,
pub discord_url: Option<String>,
pub donation_urls: Vec<String>,
pub donation_urls: Vec<DonationLink>,
}
#[derive(Deserialize, Debug)]
@ -90,6 +90,13 @@ pub struct License {
pub url: String,
}
#[derive(Deserialize, Debug)]
pub struct DonationLink {
pub id: String,
pub platform: String,
pub url: String,
}
#[derive(Deserialize, Debug)]
pub struct ModVersion {
pub id: String, // version id
@ -105,7 +112,7 @@ pub struct ModVersion {
pub downloads: isize,
pub version_type: String, // TODO {alpha | beta | release}
pub files: Vec<ModVersionFile>,
pub dependencies: Vec<String>, // TODO dependency wrangling, thank you modrinth, very cool
// pub dependencies: Vec<String>, // TODO dependency wrangling, thank you modrinth, very cool
pub game_versions: Vec<String>,
pub loaders: Vec<String>,
}