I’ve received an OAuth token from twitchapps.com/tmi for my chat bot. I want to retrieve just this bot’s channel ID and display name. However, when I execute:
I get a 401 unauthorized, with the message “missing required oauth scope”.
The docs for that endpoint mention that the required scope is channel_read, but as far as I can recall, I couldn’t specify the scopes using the token generator site.
How do I accomplish this? Do I need to get an access token using the client_credentials flow myself and specify the necessary scopes?
If you are testing on your own user then you can create your own OAuth link simply to authenticate with yourself (then by extension any other user who is using your system can later on).
{"error":"Bad Request","status":400,"message":"Must provide an ID, Login or OAuth Token."}
Huh? The docs explicitly say that if neither ID not Login is specified, it will look up the user by the bearer token. Is this incorrect?
All I want to do is to look up the chat bot’s display name and channel ID, given a bearer token (or OAuth token from twitchapps.com/tmi). I do not need to look up any other user’s information. How do I accomplish this?
However, is it at all possible, in any way, to retrieve the bot’s channel ID and display name given the token generated from twitchapps.com/tmi? This is information that the chat bot will already have, and will greatly simplify what I’m trying to do.