Need a brief explaination on access tokens and how to get them?

Hello! I am currently coding a bot for twitch in C# using TwitchLib and in order to use some features I need an access token.

My questions are,

  • How do I get an access token? I have tried the steps that is shown on twitch docs which were to go to this link.
    https://api.twitch.tv/kraken/oauth2/authorize
    ?response_type=token
    &client_id=[your client ID]
    &redirect_uri=[your registered redirect URI]
    &scope=[space separated list of scopes]

I did enter my client id, localhost, user_follows_edit into correct slots and twitch gives me this error {“error”:“Bad Request”,“status”:400,“message”:“No client id specified”}

Why is that?

  • How does access token work?

If my bot is X and the user of my bot is Y. If i told my bot to follow someone would account X follow or Y follow that person?

You get an access token just as you specified. Can you post the entire URL that you’re trying to access? You can redact the Client-ID if you want.

it appears to be working now for some reason.

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