hello ! I'm trying to make it run but i'm kinda noob with node and i dont know how to troubleshoot the error.
I'm gettign the following error when im running it. I have installed node, git all seems good i run the npm install without errors and when i run node .js im getting the following error :
-> REQUEST 0 com.roonlabs.registry:1/info
events.js:377
throw er; // Unhandled 'error' event
^
Error: Unexpected server response: 400
at ClientRequest. (c:\Users\sesho\Desktop\roon-discord-rp-master\node_modules\ws\lib\websocket.js:542:5)
at ClientRequest.emit (events.js:400:28)
at HTTPParser.parserOnIncomingClient [as onIncoming] (_http_client.js:647:27)
at HTTPParser.parserOnHeadersComplete (_http_common.js:126:17)
at Socket.socketOnData (_http_client.js:515:22)
at Socket.emit (events.js:400:28)
at addChunk (internal/streams/readable.js:290:12)
at readableAddChunk (internal/streams/readable.js:265:9)
at Socket.Readable.push (internal/streams/readable.js:204:10)
at TCP.onStreamRead (internal/stream_base_commons.js:188:23)
Emitted 'error' event on WebSocket instance at:
at abortHandshake (c:\Users\sesho\Desktop\roon-discord-rp-master\node_modules\ws\lib\websocket.js:649:15)
at ClientRequest. (c:\Users\sesho\Desktop\roon-discord-rp-master\node_modules\ws\lib\websocket.js:542:5)
[... lines matching original stack trace ...]
at Socket.Readable.push (internal/streams/readable.js:204:10)
i allowed the firewall entry as well.
the second time i run it im not getting any error but it doesnt seem to work either :
-> REQUEST 0 com.roonlabs.registry:1/info
<- COMPLETE 0 Success {"core_id":"f762cbb2-740f-4a34-a436-ee1384c6b44f","display_name":"roon","display_version":"1.8 (build 814) stable"}
-> REQUEST 1 com.roonlabs.registry:1/register {"extension_id":"com.georlegacy.general.roon-discord-rp","display_name":"Discord Rich Presence","display_version":"1.0","publisher":"615283 (James Conway)","email":"[email protected]","required_services":["com.roonlabs.transport:2"],"optional_services":[],"provided_services":["com.roonlabs.settings:1","com.roonlabs.pairing:1","com.roonlabs.ping:1"],"website":"https://www.615283.net"}
-> REQUEST 0 com.roonlabs.registry:1/info
<- COMPLETE 0 Success {"core_id":"09c6880e-7eed-4596-9cf6-e50c922c6e08","display_name":"HADES","display_version":"1.8 (build 814) stable"}
-> REQUEST 1 com.roonlabs.registry:1/register {"extension_id":"com.georlegacy.general.roon-discord-rp","display_name":"Discord Rich Presence","display_version":"1.0","publisher":"615283 (James Conway)","email":"[email protected]","required_services":["com.roonlabs.transport:2"],"optional_services":[],"provided_services":["com.roonlabs.settings:1","com.roonlabs.pairing:1","com.roonlabs.ping:1"],"website":"https://www.615283.net"}
In the settings object i changed only the ip of the roon core and i need to change also the clientid of discord that i just found it also through the dev portal. The zone id where can i find it ? hmm is it the one inside var/roon/RAATServer/Settings adding a 1601 or do i need to search on the client i want to display music from ? im running a roon server instance in docker.
const settings = {
discord: {
clientId: '464873958232162353',
// const scopes = ['rpc', 'activities.write'];
},
zone: {
zone_id: '1601563aef66097db5cf42339fd8d2051a33'
},
core: {
ip: "192.168.5.20"
},
app: {
auto_shutdown: false,
use_discovery: false
}
thanx in advance for the help !