Announcements

Help Wizard

Step 1

NEXT STEP

FAQs

Please see below the most popular frequently asked questions.

Loading article...

Loading faqs...

VIEW ALL

Ongoing Issues

Please see below the current ongoing issues which are under investigation.

Loading issue...

Loading ongoing issues...

VIEW ALL

Authorize endpoint blocked due to MIME mismatch

Authorize endpoint blocked due to MIME mismatch

Device

Macbook Pro

 

My Question or Issue

I am trying to get login to work following the Authorization Code Flow. I thought I followed most of the guide, but keep running into a "Resource was blocked due to MIME type mismatch" error (Image Below).

 

Sometimes I am able to see the authorize page, other times I immediately end up with this Error page. I've attached the code I'm using for the /login route below.

ElkeTea_0-1662698004113.png

 

app.get("/login", (req, res) => {
const state = generateRandomString(16);
res.cookie(STATE_KEY, state);

res.redirect(
"https://accounts.spotify.com/authorize?" +
querystring.stringify({
response_type: "code",
client_id: CLIENT_ID,
scope: SCOPE,
redirect_uri: REDIRECT_URI,
state: state,
}),
);
});
Reply
1 Reply

Your screenshot shows two more errors at the top: a 400 error and a 404 error, so I think those need to be fixed first.

Can you please drag the left side of the right window more to the left, so we can see the full URLs?

Also, I've decoded the URL of the MIME error and that's https://accounts.spotify.com/{2}. So I think you are trying to combine variables with URLs in a wrong way.

XimzendSpotify Star
Help others find this answer and click "Accept as Solution".
If you appreciate my answer, maybe give me a Like.
Note: I'm not a Spotify employee.

Suggested posts