janbar / noson-app

The essential to control music from your SONOS devices on Linux platforms
GNU General Public License v3.0
343 stars 28 forks source link

Amazon Music versus My Amazon Music for search results? #183

Open billykoehler opened 2 years ago

billykoehler commented 2 years ago

Apologies if this has been asked...

Is there a way to make search results in Amazon show Amazon Music results instead of My Amazon music? In the Sonos iOS app, when I search in Amazon... it will show all available albums through my premium account. Whereas, in the noson app... it will only show albums that I have purchased through Amazon.

I'd love for the search to be wide-open. Thanks for any help or suggestions on this.

FWIW... I'm LOVING the noson app. Great work!

sparkitus commented 2 years ago

I also get this. Great app BTW :) . This occurs on the latest version of the app. Maybe the following can help fix it? So it looks like the Multiple Library search function is broken, with the context always set to the local library (unless selecting radios).

In the Sonos Controller the contexts are presented as: sonos_desk_context

which appears to follows the Sonos guidelines: search_desk_context

In Noson I get: noson_desk_context

which appears to find the all the categories, but when you select them they stay with the local context (unless selecting radios).

From the amazon api we have the following mapping: <string stringId="LibrarySearch">My Music</string> <string stringId="CatalogSearch">Amazon Music</string>

Noson sends the following search request (using the tracks categories as an example) :

<ns:id>flat_search/?type=library_track&amp;count=50#library_tracks_search_desc</ns:id>

I'd suggest changing that to: <ns:id>flat_search/?type=catalog_track&amp;count=50#catalog_tracks_search_desc</ns:id>

in the case of the global context search for it to work.

janbar commented 2 years ago

Noson uses the Sonos API to search items from services. See https://developer.sonos.com/reference/sonos-music-api/search/ . It doesn't use the Amazon API, and so I have no control of that.

sparkitus commented 2 years ago

Yes, sorry if I was not clear enough. I was referring to that documentation and in particular the "Multiple Library search" feature of the Sonos API. See https://developer.sonos.com/build/content-service-add-features/add-search/ referenced from the page you linked, under the Multiple Library heading. That should clarify it a bit more. I am happy to test/debug if you can give me some guidance on setting extra debug verbosity or testing code changes.