GET helix/users Responds with 400 when trying to get user information based on token

According to the documentation, one should be able to fetch user information based on the OAuth token provided. However, the API keeps responding with “Must provide an ID, Login or OAuth Token.”.

Example:

curl -X GET https://api.twitch.tv/helix/users -H 'Authorization: Bearer ry...90' -H 'Client-Id: 1w...b8'
{"error":"Bad Request","status":400,"message":"Must provide an ID, Login or OAuth Token."}

This suggests taht the oAuth token is not a user token

It’s client credentials instead, and this doesn’t have a user attached to it.

Or the token has expried.

You can use the validate endpoint or this example tool Twitch | Token Checker to test the token

So you asked it to get the user for that token but the token is the wrong type

Thank you for the quick response!
That validation link will undoubtedly save me time in debugging this.

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