Announcements

Help Wizard

Step 1

NEXT STEP

Occasional 'Invalid Authorization Code'

Occasional 'Invalid Authorization Code'

Plan

Premium

Country

Brazil

Device

Macbook Pro 2017

Operating System

macOS 10.15

 

My Question or Issue

Hello,

I am running an App that requires the user to authenticate with Spotify, and I am doing this according to the Authorization Code Flow. Most of the times I get successful responses, but occasionally I get an error:

Error: Request failed with status code 400

error: invalid_grant

error_description: Invalid authorization code

 

As I am logging all the error callback information, I can check that my request is being sent correctly (grant_type, code and redirect_uri, as well as my headers).

 

It seems to me that Spotify is providing me a flawed code, although I find it very unlikely to happen.

Can anybody help me to sort it out?

Thank you.

Reply
4 Replies

also experiencing this problem.  it is happening for about 7% of authorization requests.

Trying everything to solve it but I'm not getting lucky. Tried to move the requests to my backend server and thought that I sorted it out but I'm still getting "Invalid Authorization Errors". Hoping that someone can help us out!!

I think I am experiencing the same issue. I don't know if there is a solution available at this moment 

Anyone know solution to this? I am also getting "invalid_grant" even though I've checked both my server and client redirect_URI 's are the same.

Suggested posts

Let's introduce ourselves!

Hey there you,   Yeah, you! 😁   Welcome - we're glad you joined the Spotify Community!   While you here, let's have a fun game and get…

ModeratorStaff / Moderator/ 4 years ago  in Social & Random