How can I check if a user has moderator privileges in a channel?

Assuming the user’s not currently in the channel, is there anyway to check this? I didn’t see anything in the api, but I’m really hoping somebody’s maybe thought up an elegant workaround.

AFAIK the only way I know of to find out if a user is mod without him being there is using the irc, and calling /mods in the given room. If you’re already using API only I’m not sure I’d it’s worth the effort, otherwise you might want to use your IRC connection.

If you are in the web chat you could just display the user list by clicking it’s button of course.

TMI/IRC Documentation

On the TMI (irc type) connect, you would execute:

/raw CAP REQ
Adds membership state event (NAMES, JOIN, PART, or MODE) functionality. By default we do not send this data to clients without this capability.

/raw CAP REQ

/raw CAP REQ
Adds IRC v3 message tags to PRIVMSG, USERSTATE, NOTICE and GLOBALUSERSTATE (if enabled with commands CAP)

Twitch messaging interface (TMI) has it’s own API, but it’s not supported and can change at any time. You could request the list of active moderators from:

Again, This API is not documented or supported. It is subject to change without notice.

I was kinda hoping it’d be possible to check without using the IRC. I wish they’d add something like

And @matt_thomas , as I said, they’re not in the chat room, so that won’t work.

You don’t have to be in the channel.

He means the user he wants to check whether it’s a moderator is not in the channel, so he won’t be in the list of active chatters/moderators.

Wow, I misread that. My bad for making an assumption. Guess I need some more sleep. He even italicized it. “they’re not in the chat room”

I ended up getting around this by calling for the list of editors for my channel (need token)

Keeping in mind, you will need to add all your mods to the Editor list… It can be risky

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.