use serde::{Deserialize, Serialize};
use std::collections::HashMap;
use crate::{ArtistId, CursorBasedPage, Followers, Image};
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq, Default)]
pub struct SimplifiedArtist {
pub external_urls: HashMap<String, String>,
pub href: Option<String>,
pub id: Option<ArtistId<'static>>,
pub name: String,
}
#[derive(Clone, Debug, Serialize, Deserialize, PartialEq, Eq)]
pub struct FullArtist {
pub external_urls: HashMap<String, String>,
pub followers: Followers,
pub genres: Vec<String>,
pub href: String,
pub id: ArtistId<'static>,
pub images: Vec<Image>,
pub name: String,
pub popularity: u32,
}
#[derive(Deserialize)]
pub struct FullArtists {
pub artists: Vec<FullArtist>,
}
#[derive(Deserialize)]
pub struct CursorPageFullArtists {
pub artists: CursorBasedPage<FullArtist>,
}