use rspotify::{prelude::*, scopes, AuthCodeSpotify, Credentials, OAuth};
fn main() {
env_logger::init();
let creds = Credentials::from_env().unwrap();
let oauth = OAuth::from_env(scopes!("user-read-playback-state")).unwrap();
let spotify = AuthCodeSpotify::new(creds, oauth);
let url = spotify.get_authorize_url(false).unwrap();
spotify.prompt_for_token(&url).unwrap();
let devices = spotify.device();
println!("Request: {devices:?}");
}