I would like to get someones profile picture and background image for a website but it would be hard to just manually do that if I could just get maybe the player id with the api and get the background image and profile pic
joe = requests.get("https://osu.ppy.sh/api/v2/me/osu") print("test log:\n") print(joe.text) print("=----------=\n end of log\n")
If you don't wanna use the API, you can grab those things much easier.-aster wrote:
What I usually do is if I like someone's pfp and header is that I right click > "inspect element" > and then go to "sources" to find the page where osu stores its code and images.
I then toggle through the folders until I find the folder where user icons are stored and then "open the image in a new tab" to save for potential future use ^^
yes I was originally doing that, but now I am realize that manually doing that for every person that authorizes on the website would be kinda hard... So I will use death's idea.Dntm8kmeeatu wrote:
If you don't wanna use the API, you can grab those things much easier.-aster wrote:
What I usually do is if I like someone's pfp and header is that I right click > "inspect element" > and then go to "sources" to find the page where osu stores its code and images.
I then toggle through the folders until I find the folder where user icons are stored and then "open the image in a new tab" to save for potential future use ^^
For avatars, you can just go to a.ppy.sh/uid?.jpg
As for covers, right clicking the element and inspecting it directly should take you right to a url in the html source. No need to go through source image folders and using trial and error.
joe = requests.get("https://osu.ppy.sh/api/v2/GDcheerios/osu", headers={"Authorization" : "Bearer {{token}}"})