[API Request] Shares #47
x1arch
started this conversation in
API requests
Replies: 1 comment 1 reply
-
|
I am not familiar with these endpoints: I wonder if in the original Subsonic API, a share can be only modified by the user who created it? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Type of change
API Clarification
Proposal description
Categories: Sharing
Update shares methods for make it more usable.
If we apply this updates, then we can use any front for shares (not only which knows about the backend). We can build share URL on the front, as example:
https://xonic-ui.netlify.app/s/xteYF32ru?srv=https://demo.navidrome.orghttps://xonic-ui.netlify.app- frontend domain (which do not know anything about backend, but it can play share)/s/- path to share sectionxteYF32ru- ID of the share?srv=https://demo.navidrome.org- domain of share (if frontend doesn't know anything about backend)Of course this is applicable for web versions only, for mobile applications we have URL from backend.
Backward compatibility impact
I can found only one backend (server) witch implement shares - this is navidrome For getting share they use internal methods (actually for there web client they use internal methods). I already was add share support to xonic-ui (fork of airsonic-refix). And I have a plan to add shares support in to gonic, maybe to navidrome.
Backward compatibility
API details
Existing methods modify
GET /rest/createShareCurrent Parameters
Will be add
Return value
Will add two params to response:
protected- show protected it by secret phrase or notdownload- show allow download songs or notGET /rest/updateShareCurrent Parameters
Will be add
addparameter for each entry to add to share.removeparameter for each entry to remove it from share.Add new methods
GET /rest/getShareParameters
Return value
Return one share
GET /rest/getSharePublicRequest should be available without authentication. Only by protection phrase (if setted).
Parameters
Return value
GET /rest/streamSharePublicRequest should be available without authentication. Only by protection phrase (if setted).
Parameters
and other stream params
Return value
The same as stream
GET /rest/getCoverArtSharePublicRequest should be available without authentication. Only by protection phrase (if setted).
Parameters
and other getCoverArt params
Return value
The same as getCoverArt
Security impacts
Brute-force share protection phrase, but this is can be solved by add IP to ban after a few wrong requests about to 1 hour.
Potential issues
No response
Alternative solutions
No response
Beta Was this translation helpful? Give feedback.
All reactions