GraphQL API: Listener
Get a listener’s top artists
Get a list of up to 20 of the most popular recent artists for a listener based on their listening over the past 200 days. You can use pagination to iterate through results.
Request
{
topArtists(pagination: { limit: 3 }) {
items {
id
... on Artist {
name
}
}
}
}
* Add your OAuth bearer token to the Authorization
header
curl 'https://ce.pandora.com/api/v1/graphql/graphql' \
-H 'Authorization: Bearer ' \
-H 'Content-Type: application/json' \
-d '{"operationName":null,"variables":{},"query":"{ topArtists(pagination: {limit: 3}) { items { id ... on Artist { name } } }}"}'
Response
{
"data": {
"topArtists": {
"items": [
{
"id": "AR:365850",
"name": "Of Monsters and Men"
},
{
"id": "AR:316074",
"name": "Mumford & Sons"
},
{
"id": "AR:479784",
"name": "Smith & Thell"
}
]
}
}
}