• If you need help or want to discuss things, you now can also join us on our Discord Server!
  • A first preview of the unlimited version of SinusBot can be found in the Upcoming Changes thread. A version for Windows will follow, but we don't have a release date, yet.

DE Spotify Einbindung

cr1ms0n

Member
Have you set the spotify client id and secret in the settings?
ofc i did:


PKIwf5n.png
 

Apina-32

Member
ofc i did:
The error you're receiving indicates that it's failing to call the Spotify API. All I can think of is either your Client ID or Secret is wrong. Do other songs work? Do you get any errors in the sinusbot logs on the admin page?
 

cr1ms0n

Member
The error you're receiving indicates that it's failing to call the Spotify API. All I can think of is either your Client ID or Secret is wrong. Do other songs work? Do you get any errors in the sinusbot logs on the admin page?
I have double-checked everything again; the keys and IDs are set correctly. The log says the following:
Code:
2024-01-25T14:58:58+01:00 [ :253:28] Error while getting track: undefined, id: 6rqhFgbbKwnb9MLmUQDhG6
2024-01-25T14:58:58+01:00 Unhandled rejected promise: TypeError: Cannot destructure property 'name' of '(intermediate value)' as it is undefined.

No song is working, regardless of which one - the same error persists both in the chat response and in the log.
 

Apina-32

Member
I have double-checked everything again; the keys and IDs are set correctly. The log says the following:
Code:
2024-01-25T14:58:58+01:00 [ :253:28] Error while getting track: undefined, id: 6rqhFgbbKwnb9MLmUQDhG6
2024-01-25T14:58:58+01:00 Unhandled rejected promise: TypeError: Cannot destructure property 'name' of '(intermediate value)' as it is undefined.

No song is working, regardless of which one - the same error persists both in the chat response and in the log.
Apparently spotify has changed how the access token flow works...
It should work now.

Edit: There are still some issues...
 
Last edited:

Apina-32

Member
I have double-checked everything again; the keys and IDs are set correctly. The log says the following:
Code:
2024-01-25T14:58:58+01:00 [ :253:28] Error while getting track: undefined, id: 6rqhFgbbKwnb9MLmUQDhG6
2024-01-25T14:58:58+01:00 Unhandled rejected promise: TypeError: Cannot destructure property 'name' of '(intermediate value)' as it is undefined.

No song is working, regardless of which one - the same error persists both in the chat response and in the log.
It's working now. Well, at least for me...
 

cr1ms0n

Member
It's working now. Well, at least for me...
Receiving following error:
Code:
<17:31:48> "stack overflow": Error while getting track: Received invalid status from spotify auth: 403 undefined, id: 1U4jpScCcuS2fsHYIo0ui7

Admin Log:

Code:
2024-01-25T17:31:51+01:00 [ :263:28] Error while getting track: Received invalid status from spotify auth: 403 undefined, id: 1U4jpScCcuS2fsHYIo0ui7
2024-01-25T17:31:51+01:00 Unhandled rejected promise: TypeError: Cannot destructure property 'name' of '(intermediate value)' as it is undefined.
2024-01-25T17:31:51+01:00 [ :146:28] Received invalid status from spotify auth: 403
 

Apina-32

Member
Receiving following error:
Code:
<17:31:48> "stack overflow": Error while getting track: Received invalid status from spotify auth: 403 undefined, id: 1U4jpScCcuS2fsHYIo0ui7

Admin Log:

Code:
2024-01-25T17:31:51+01:00 [ :263:28] Error while getting track: Received invalid status from spotify auth: 403 undefined, id: 1U4jpScCcuS2fsHYIo0ui7
2024-01-25T17:31:51+01:00 Unhandled rejected promise: TypeError: Cannot destructure property 'name' of '(intermediate value)' as it is undefined.
2024-01-25T17:31:51+01:00 [ :146:28] Received invalid status from spotify auth: 403
I assume you updated the script?
That's a 403 forbidden error, meaning that if everything else works, your client id or secret is invalid. I just tested the script again and it still works for me.
 

cr1ms0n

Member
I assume you updated the script?
That's a 403 forbidden error, meaning that if everything else works, your client id or secret is invalid. I just tested the script again and it still works for me.
ofc i did. again, checked everythin twice - cant find the problem..
 

cr1ms0n

Member
I assume you updated the script?
That's a 403 forbidden error, meaning that if everything else works, your client id or secret is invalid. I just tested the script again and it still works for me.
any update? also tried with a fresh new developer app in the spotify developer dashboard, same error
 

Apina-32

Member
any update? also tried with a fresh new developer app in the spotify developer dashboard, same error
Honestly no idea. Did you select the Web API when creating the developer app? Have you checked that you don't have any spaces in front of or after the client id/secret?

Also if you're familiar with this stuff you could test if you can get the access token manually using your client id and secret: https://developer.spotify.com/docum...rials/getting-started#request-an-access-token
 

cr1ms0n

Member
Honestly no idea. Did you select the Web API when creating the developer app? Have you checked that you don't have any spaces in front of or after the client id/secret?

Also if you're familiar with this stuff you could test if you can get the access token manually using your client id and secret: https://developer.spotify.com/docum...rials/getting-started#request-an-access-token
I have now tried it manually via a POST request but still receive the same 403 Forbidden error. Unfortunately, I'm not very familiar with the Spotify API. Could it be because I'm not using HTTPS for the Redirect URL?

I've also checked the box for Web API.


Edit I've now tried it locally from my PC and can easily request a token via a POST request without any issues. It seems like the IP of my VPS is blocked for these requests..
Any Idea how to solve this? @Apina-32

PzjqvF5.png
 
Last edited:

Apina-32

Member
I have now tried it manually via a POST request but still receive the same 403 Forbidden error. Unfortunately, I'm not very familiar with the Spotify API. Could it be because I'm not using HTTPS for the Redirect URL?

I've also checked the box for Web API.


Edit I've now tried it locally from my PC and can easily request a token via a POST request without any issues. It seems like the IP of my VPS is blocked for these requests..
Any Idea how to solve this? @Apina-32

PzjqvF5.png
Yeahh.... I kind of suspected that might be the issue. I guess you could try changing to a different IP. Or you could try to use a proxy server to forward the requests.
 
Top