[API Request] GetAlbumList2 endpoint: sorting and filtering should not be mutually exclusive #7
dweymouth
started this conversation in
API requests
Replies: 1 comment 4 replies
-
Agee, but I think I'd expect this is how it should work in the first place, given http://www.subsonic.org/pages/api.jsp#getAlbumList2 . "can" is used, rather than "must" or "shall" which makes it almost sound optional, and no reference is made to |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Type of change
API tweak
Proposal description
Currently, with the
GetAlbumList2
endpoint, you can retrieve a list of all albums, paginated and sorted (by recently added, name a-z, etc.), OR you can retrieve a filtered list of albums (e.g. byGenre, by year range), but you can't specify a sort order on the result. Tweaking/extending the API to allow a sort and filter specified together would enable scenarios like "show recently added Rock albums"Backward compatibility impact
If the API is called the way it is called today, i.e. specifying
type=byGenre
orbyYear
then the behavior is the same as the status quoBackward compatibility
API details
I propose tweaking the
GetAlbumList2
endpoint to accept thefromYear
,toYear
, andgenre
options without mandating that you also settype=byYear or byGenre
. E.g. a request withgenre=Classical
,fromYear=1990
, toYear=2023
,type=recent
should get all classical albums from 1990-2003, and return the result in recently added sort orderSecurity impacts
No response
Potential issues
No response
Alternative solutions
No response
Beta Was this translation helpful? Give feedback.
All reactions