Recieving an “errorCode: ERROR_RESOURCE_GONE” when trying to send play command

  • 31 May 2021
  • 3 replies
  • 143 views

Badge

I have been trying to figure out the sonos api over the past few days, but unfortuanetly have hit a road block. I have already gotten my tokens and room names and and favorites Id, but when I send the curl request to play a song I get the error described above.

Curl Code : curl -X POST -H "Content-Type: application/json" -H "Authorization: Bearer {TOKEN}" "https://api.ws.sonos.com/control/api/v1/groups/RINCON_48A6B88A5B14014XX:XXXXXXXXXX/favorites" --data @play.json

I keep the body in a .json file called play which contains the code:

{ "favoriteId":2, "playOnCompletion":true }

I have not been able to find any documentation on this issue online, so any and all help is very appreciated.


This topic has been closed for further comments. You can use the search bar to find a similar topic, or create a new one by clicking Create Topic at the top of the page.

3 replies

Userlevel 7
Badge +23

stackoverflow is the place for these and this Q has already been posted there, with some speculative replies. I have given up with the cloud API, the UPnP API is better in almost every aspect.

Userlevel 7
Badge +20

I believe that discussion of the Sonos Cloud API takes place over on StackOverflow.

(Note that the local network UPnP API is generally more powerful, but is not officially supported.)

I haven’t fussed with the API, but you could have an issue with the play.json file path or permissions. Maybe you could attract the attention of @controlav.