Hello,
I am looking here
https://developer.spotify.com/documentation/web-playback-sdk/
Is there a way to play song by #ID on our own site?
Thank you
I'm not so sure exactly what your issue is specifically, but I can tell you that the SO page you linked to allows you to get an Access Token using the Client Credentials OAuth flow. This token will not be sufficient for use for the Web Playback SDK - you should instead be using the Authorization Code Flow (https://developer.spotify.com/documentation/general/guides/authorization/code-flow/)
You only need the user to authorise access once, after that you can use the provided refresh token to refresh your access token.
There is a description here - https://developer.spotify.com/documentation/web-playback-sdk/reference/#playing-a-spotify-uri of how to use the Web API to trigger playback on your device. You can get the device ID from the "ready" event listener.