TeKrop / overfast-api

⚡ Unofficial Overwatch 2 API, built with FastAPI, provides data on heroes, game modes, maps, and player careers
https://overfast-api.tekrop.fr
MIT License
107 stars 14 forks source link

API does not support special characters #199

Closed OskarD closed 1 week ago

OskarD commented 2 weeks ago

Describe the bug Player names like these return status code 400:

To Reproduce Click on one of the links

Expected behavior Player profile

TeKrop commented 2 weeks ago

Hello !

Thank you for the report. Unfortunately, the API is using official Blizzard pages for data, and it seems the users can't be found on these. You can try yourself here : https://overwatch.blizzard.com/en_US/search/

I tried all the names you shared, and FunkMëMommy#2867 is actually the only one working for me 😅

Let me know if I can help you on anything else 👍

OskarD commented 2 weeks ago

Do the players/{player_id} endpoints do a search to find the profile, then get the information from the profile? I thought it somehow fetched it directly based on the battletag alone

TeKrop commented 2 weeks ago

Not directly, but it uses it to gather data about the last time a profile was updated, and the player namecard (which is not on the profile page).

I also noticed that if a profile can't be found in Blizzard search, it's not available if we try to use the url directly.

Are the profiles you're trying to use public ? If that's the case, I'm afraid I can't do anything to help on this issue 😕

OskarD commented 1 week ago

I don't know if they're public, I just know that I get that error back so I assume the API doesn't know yet

TeKrop commented 1 week ago

If profiles can't be found on Blizzard pages, the API won't be able to resolve them 😕 It can happen for private profiles, or sometimes for some public profiles for some reason. It's not related to special char issue, I already had this feedback a few months ago.

OskarD commented 1 week ago

Oh, weird! Thanks anyway :)