mirror of
https://github.com/jwilsson/spotify-web-api-php.git
synced 2026-04-26 23:45:49 +03:00
[GH-ISSUE #254] Return All Genres? #181
Labels
No labels
bug
docs
enhancement
enhancement
enhancement
feedback wanted
good first issue
help wanted
help wanted
help wanted
invalid
pull-request
question
question
upstream
upstream
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/spotify-web-api-php#181
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ghost on GitHub (Sep 24, 2022).
Original GitHub issue: https://github.com/jwilsson/spotify-web-api-php/issues/254
Hi Jonathan - I hope you're well.
I wondered if your Spotify Web API code has any provision to return all Genres?
I have used this:
$api->getGenreSeeds();
But the full list of Genres returned by e.g. https://discoverquickly.com/ (which I think also uses the Spotify API) is much larger - screenshot extract here:
https://snipboard.io/KekrMI.jpg
Full extract list also attached in text file.
full-genre-list.txt
Thanks!
Jim
@jwilsson commented on GitHub (Sep 24, 2022):
Hey Jim!
I don't think there's an Spotify API endpoint to fetch the genres. But your question got me intrigued so I did some digging on https://discoverquickly.com/ and it looks like they're getting their data from https://everynoise.com/ (a request to https://discoverquickly.com/static/media/everynoise-genres.3d03bd3b.csv is made everytime you view the Genres page)
Hope this is of some help!
Cheers,
Jonathan
@ghost commented on GitHub (Sep 24, 2022):
Hi Jonathan - thanks for your quick reply!
That's very interesting about the CSV file that contains the list of genres.
Out of interest - how were you able to confirm that discoverquickly's "Genres" link extracts the data from that CSV file?
I tried a View Source, and an Inspect Element, and also checked on the browser Console for the XHR request when the Genres link is clicked but couldn't see the CSV bit.
Was curious what method(s) you used to find that?
Thanks again
Jim
@jwilsson commented on GitHub (Sep 24, 2022):
I tried the same methods you did, without any luck. Then I saw the small "reload" icon on the genres page, clicking that I found a request for the CSV file in the browser's network tab 😄
@ghost commented on GitHub (Sep 25, 2022):
Thanks Jonathan - that's very useful to know!
Thanks again for your help
Jim