Type in your question below and we'll check to see what answers we can find...
Loading article...
Submitting...
If you couldn't find any answers in the previous step then we need to post your question in the community and wait for someone to respond. You'll be notified when that happens.
Simply add some detail to your question and refine the title if needed, choose the relevant category, then post.
Before we can post your question we need you to quickly make an account (or sign in if you already have one).
Don't worry - it's quick and painless! Just click below, and once you're logged in we'll bring you right back here and post your question. We'll remember what you've already typed in so you won't have to do it again.
Please see below the most popular frequently asked questions.
Loading article...
Loading faqs...
Please see below the current ongoing issues which are under investigation.
Loading issue...
Loading ongoing issues...
Hello, Spotify developer community!
I'm reaching out to seek guidance on a specific aspect of my application's integration with the Spotify API. I have successfully implemented user authorization using Spotify, allowing users to connect their Spotify accounts to my app. Now, I'm looking to enhance the user experience by identifying whether a user is an artist on Spotify and accessing their personal details and songs. Here's what I'm trying to achieve:
1. Detecting Artist Status:
2. Retrieving Personal Details:
3. Accessing Songs:
Here are some details about my current implementation:
I would greatly appreciate any guidance or examples that could help me achieve these goals. Your assistance will make a significant difference in improving my application's functionality.
Thank you in advance for your help!
Howldy good sir!
Certainly, I can help you with these aspects of integrating with the Spotify API without redirecting you to support or suggesting a generic troubleshooting approach.
Here’s a brief example in Node.js to get an artist’s top tracks:
const fetch = require('node-fetch');
const artistId = 'YOUR_ARTIST_SPOTIFY_ID';
const accessToken = 'YOUR_ACCESS_TOKEN';
const url = `https://api.spotify.com/v1/artists/${artistId}/top-tracks?country=US`;
fetch(url, {
headers: {
'Authorization': `Bearer ${accessToken}`,
},
})
.then(response => response.json())
.then(data => {
// Process the list of top tracks here.
console.log(data);
})
.catch(error => {
console.error('Error:', error);
});
Replace ‘YOUR_ARTIST_SPOTIFY_ID’ and ‘YOUR_ACCESS_TOKEN’ with your specific values. This example will give you the top tracks of the artist identified by their Spotify ID.
I hope this helps you enhance your application’s integration with the Spotify API. If you have any further questions feel free to bark more orders at me,
-Prague the Dog
Thanks Prague, but i think some points are missing. Like in the Detecting Artist Status for every artist the "product" field will be “artist_premium” , or any other value can also be possible? And in the Accessing Songs how can i get the artist’s Spotify ID? So what i am implementing is if my user is an artist on spotfiy then only he can login otherwise he cant login and then i am showing him all his songs with his profile picture and name and also *very important* his monthly listners
.
Hii Prague the dog, Thanks for your prev response, but i think some points are missing. Like in the Detecting Artist Status for every artist the "product" field will be “artist_premium” , or any other value can also be possible? And in the Accessing Songs how can i get the artist’s Spotify ID? So what i am implementing is if my user is an artist on spotfiy then only he can login otherwise he cant login and then i am showing him all his songs with his profile picture and name and also *very important* his monthly listners
Hi User,
It's not possible to get the monthly listeners of an artist using the Spotify Web API.
Have the list of possible strings in the "product" field changed since this post? I've tested this with an account that has Spotify for Artists access and it does not show "artist_premium" or "artist_free". Has it been recently deprecated?
Hey there you, Yeah, you! 😁 Welcome - we're glad you joined the Spotify Community! While you here, let's have a fun game and get…