@3ventic is correct that you need a browser for the initial OK by the user. The response from https://api.twitch.tv/kraken/oauth2/token is a JSON-encoded token. Just FYI, @shekhjkl, I’ve sent you a private message to talk offline about these sort of pain points. 