Hey,
I’m following the docs on OICD authorization, and after successfully being redirected to my redirect-URL with the OAuth 2.0 authorization code, I’m failing at the following part:
On your server, get an access token and ID token by making this request:
json POST https://id.twitch.tv/oauth2/token?client_id=< your client ID >&client_secret=< your client secret >&code=< authorization code received above >&grant_type=authorization_code &redirect_uri=< your registered redirect URI >
my POST request URL within Postman looks like this: https://id.twitch.tv/oauth2/token?client_id=[my-client-id]&client_secret=[my-secret]&code=[the-oauth-code]&grant_type=authorization_code&redirect_uri=http:localhost:3000/users/auth/twitch/callback
(There are no unwanted spaces or anything like that, I checked numerous times already)
But I’m getting a 400 status response with the message missing client id
.
I noticed that if I add Client-ID <ID>
to the headers, I get a response of missing client secret
.
Why does the endpoint read headers when it’s specified in the docs that the details are supposed to be passed as query params, or is there something wrong with my request (URL)?
Even just this POST request gets the same error message: https://id.twitch.tv/oauth2/token?client_id=[my-id]
so apparently query params are completely being ignored.
What the right way to pass the required properties?
Thanks in advance.