Get Banned Users should work for all channels authenticated user is moderator of
I feel like I’ve seen this suggested before, but I’m unable to find another suggestion for this currently.
Anyway, right now Get Banned Users (https://dev.twitch.tv/docs/api/reference#get-banned-users) only works for the user that is authenticated, regardless of them being a moderator for other channels.
It would be very useful if the restriction on broadcaster_id
matching the auth token’s user_id
was softened and instead just require that user_id
is a moderator for broadcaster_id
.
-
Iuccao commented
Agreed. I have a command on my twitch bot to timeout people when triggered but I don't want it to timeout an already timed out user that has a longer time. What I mean is: user has 14 days time out; so if the command is triggered and a t.o. of 60s is issued, the user will now have its timeout reduced. I thought I could check if he is already timed out since my bot is a mod of the channel, but no; that's so messed up.
-
nerixyz commented
I want to add that it's impossible to only timeout users that aren't timed out already solely through the API with a moderator token.
Right now I have to track the timeouts with PubSub and put them in redis. It would me much easier if I could check the user's status first and then issue a timeout.I suppose in my specific case it would be sufficient if the "Ban User" endpoint included a parameter that would specify the behaviour if the user is already timed out or banned (like `no_modify` to not modify any existing timeout).