Image icon and title for site award badges missing via API_GetUserAwards endpoint
Describe the bug
When getting a list of badges for a user the title and image icon for site awards are missing.
Endpoint: API_GetUserAwards.php?y={{key}}&u={{username}}
To Reproduce
Fetch badges of a user via API and check the response:
...
"VisibleUserAwards": [
{
"AwardedAt": "2025-01-25T21:08:30+00:00",
"AwardType": "Patreon Supporter",
"AwardData": 0,
"AwardDataExtra": 0,
"DisplayOrder": 0,
"Title": null,
"ConsoleID": null,
"ConsoleName": null,
"Flags": null,
"ImageIcon": null
}
]
...
Or an other example
{
"AwardedAt": "2024-12-22T21:43:11+00:00",
"AwardType": "Certified Legend",
"AwardData": 0,
"AwardDataExtra": 0,
"DisplayOrder": 786,
"Title": null,
"ConsoleID": null,
"ConsoleName": null,
"Flags": null,
"ImageIcon": null
},
Expected behavior
Title and image icon exists.
@DFelten Could you confirm if this particular data is for a non-game or event award?
Yes, these are awards for non game awards and events.
from what I can see here, non game awards and events do not come with title and icons. @wescopeland if there an intention for this to change?
I don't think we've settled on how we'll handle those awards in the long-term.
They're usually granted by things like developer actions or subscribing to our Patreon. You can directly observe a few of these on my profile at https://retroachievements.org/user/WCopeland:
4 of these 5 probably exhibit the issue. It may be reasonable in the API to detect these cases and return the correct asset URL, we just need to be sure that if the API is adjusted to do this, if we ever change the URL, we don't need to remember to update the API (try to limit hardcoding if possible).
Exactly the images and titles of these awards are missing via the api.
So in the app I'm working on it looks like this because of the missing data: