Twitch API request help

Hi all,
I am new to using the Twitch API and I am trying to get the game analytics data for our games. Currently trying to implement this in R. I keep getting access denied when trying the request for game analytics and I am not sure what I am doing wrong.

First thing I did was making an registering an app as an analytical tool and got an app token via the following request (I am mostly using httr R package and RStudio’s terminal):

token <- POST(“”)

I got this response:

Date: 2018-09-20 11:00
Status: 200
Content-Type: application/json
Size: 93 B

Then i sent the request with:

curl -H “Authorization: Bearer somecharacterstring”-X GET
I tried also with
curl -H “Authorization: OAuth somecharacterstring”-X GET

In both cases I keep getting error:

curl: (6) Could not resolve host: GET
{“error”:“Unauthorized”,“status”:401,“message”:“Must provide a valid Client-ID or OAuth token”}

I am sorry if the formatting looks off, but I have not found any options for code snippets.

Thanks in advance for your input!

You have requested a “App Access Token”

App Access Token’s have no “user information” attached nor can they request scopes.

Requires a scope of analytics:read:games so you need a User access token otherwise I’d be able to use my App Access Token to steal your game analytics

I see! Thanks.

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