[GH-ISSUE #167] How to use a custom Spotify ClientID? #104

Closed
opened 2026-02-28 14:25:24 +03:00 by kerem · 1 comment
Owner

Originally created by @vitorbaptista on GitHub (Jan 22, 2025).
Original GitHub issue: https://github.com/devgianlu/go-librespot/issues/167

First of all, thanks for the great piece of code!

There is a hardcoded Client ID in github.com/devgianlu/go-librespot@b67163895b/client_id.go (L5). I'd like to use my own Client ID. I can change the go code and recompile it directly, but when I do so it fails with:

FATA[0000] failed running with interactive auth error="failed obtaining client token: invalid status code from clienttoken: 400"

My Spotify app is set with all APIs and the redirect URI is configured correctly:

Image

My app is in development mode.

What am I missing?

Originally created by @vitorbaptista on GitHub (Jan 22, 2025). Original GitHub issue: https://github.com/devgianlu/go-librespot/issues/167 First of all, thanks for the great piece of code! There is a hardcoded Client ID in https://github.com/devgianlu/go-librespot/blob/b67163895baf78fa95447df8739ac2c79cc52c9e/client_id.go#L5. I'd like to use my own Client ID. I can change the go code and recompile it directly, but when I do so it fails with: `FATA[0000] failed running with interactive auth error="failed obtaining client token: invalid status code from clienttoken: 400"` My Spotify app is set with all APIs and the redirect URI is configured correctly: ![Image](https://github.com/user-attachments/assets/beeed65c-8454-4a75-90a7-4078c17a99e8) My app is in development mode. What am I missing?
kerem closed this issue 2026-02-28 14:25:24 +03:00
Author
Owner

@devgianlu commented on GitHub (Jan 22, 2025):

The client ID hardcoded there is a special one from Spotify. What you may want to do is authenticate via an access token made with your app.

<!-- gh-comment-id:2608399068 --> @devgianlu commented on GitHub (Jan 22, 2025): The client ID hardcoded there is a special one from Spotify. What you may want to do is authenticate via an access token made with your app.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/go-librespot#104
No description provided.