Allow Steam Hours Endpoint to be multilingual
Saturate opened this issue · 1 comments
This formatting makes it so that hours are always the unit. I want this to be "timer" to support a danish nightbot. Seeing it's not backward compatible to just remove it, I suggest a parameter that simply disables it, or changes the text. If it's disabled it would be implemented like this
!editcom !timer Wonderbai har spillet CSGO i $(urlfetch https://beta.decapi.me/steam/hours?id=76561198058746905&appid=730) timer
if it's a parameter it would be:
!editcom !timer Wonderbai har spillet CSGO i $(urlfetch https://beta.decapi.me/steam/hours?id=76561198058746905&appid=730&unittext=timer)
This formatting makes it so that hours are always the unit. I want this to be "timer" to support a danish nightbot. Seeing it's not backward compatible to just remove it, I suggest a parameter that simply disables it, or changes the text. If it's disabled it would be implemented like this
%s hours
in the line you referred to is just the default. You can customize it yourself, where %s
is just the number of hours and hours
is just what's added at the end by default:
- Here's an example with just the number
123.45
: https://decapi.me/steam/hours?id=76561198058746905&appid=730&format=%s - Here's an example with the format
123.45 timer
: https://decapi.me/steam/hours?id=76561198058746905&appid=730&format=%s%20timer
I do agree that the /steam/hours
endpoint should have translations for everything else, but since that's mostly error messages it's a low priority issue.