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>,
#[deprecated(
since = "0.16.0",
note = "Spotify has removed this field. See https://github.com/ramsayleung/rspotify/issues/550"
)]
#[serde(default)]
pub followers: Followers,
pub genres: Vec<String>,
pub href: String,
pub id: ArtistId<'static>,
pub images: Vec<Image>,
pub name: String,
#[deprecated(
since = "0.16.0",
note = "Spotify has removed this field. See https://github.com/ramsayleung/rspotify/issues/550"
)]
#[serde(default)]
pub popularity: u32,
}
#[derive(Deserialize)]
pub struct FullArtists {
pub artists: Vec<FullArtist>,
}
#[derive(Deserialize)]
pub struct CursorPageFullArtists {
pub artists: CursorBasedPage<FullArtist>,
}