Announcements

Help Wizard

Step 1

NEXT STEP

[Web API] Bug: 403 Response with empty body instead of Error Object

[Web API] Bug: 403 Response with empty body instead of Error Object

Observed behavior:

As expected, a GET request to the endpoint at  https://api.spotify.com/v1/me/top/artists

receives an HTTP 403 response when the Token in use does not have the necessary Scope (i.e., lacking 'user-top-read' scope)

However, the body of the HTTP response does not contain the expected JSON data -- an Error Object. In fact, the body of the response is empty.

As per the documentation at
https://developer.spotify.com/documentation/web-api/reference/personalization/get-users-top-artists-...
I expected a JSON-formatted Error Object in the body of the HTTP response.

See Pastebin link for: CLI output from `curl -v` command demonstrating issue.

Note line 22: "< Content-Length: 0"

https://pastebin.com/7YmvDUJu

Reply
0 Replies

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