Twitch bot - 401

You did generate an oAuth token and are not trying to use your client secret as a token? And you also have created a user access token and not a client credentials token?

The usual flow is this one

And that token’s user ID is the channel you are trying to read the moderators of?

The Get Moderators API will require a user token with moderation:read or channel:manage:moderators (usually the former scope)

And if I want to read fred moderators I need a token from fred