[Python] Function to get Twitch Channel ID

Your OAuth scopes will depend on which API endpoints or capabilities you’re using. For example, Get User uses user_read scope, Get Channel uses channel_read, chat uses chat_login scope. Each endpoint documents whether it requires a specific OAuth scope or not.

When you’re generating an OAuth token for a user, you should request only the smallest amount of scopes that you need to operate. A single token can have multiple scopes to it, but it’s up to you to request them when the user logs in.