9ab0c2dc67
* Add `.editorconfig` file Hints to users how to properly indent Go files (my setup was defaulting to 2 spaces). * Add Subsonic API minimal config option This will allow users to specify clients which can operate with or need the minimum required fields as per the [SubSonic API spec](https://subsonic.org/pages/api.jsp). * Return only required fields for Child Objects For a minimal client, only return the required fields for Child Objects. * Return only required fields for Playlist objects * refactor: simplify client list checks and improve playlist response handling Signed-off-by: Deluan <deluan@navidrome.org> * test: add unit tests for client list checks and playlist building logic Signed-off-by: Deluan <deluan@navidrome.org> * fix: revert Child.IsVideo and Playlist.Public fields from pointer to boolean, and add omitempty to XML tag Signed-off-by: Deluan <deluan@navidrome.org> --------- Signed-off-by: Deluan <deluan@navidrome.org> Co-authored-by: Deluan Quintão <deluan@navidrome.org>
150 lines
3.3 KiB
JSON
150 lines
3.3 KiB
JSON
{
|
|
"status": "ok",
|
|
"version": "1.16.1",
|
|
"type": "navidrome",
|
|
"serverVersion": "v0.55.0",
|
|
"openSubsonic": true,
|
|
"directory": {
|
|
"child": [
|
|
{
|
|
"id": "1",
|
|
"isDir": true,
|
|
"title": "title",
|
|
"album": "album",
|
|
"artist": "artist",
|
|
"track": 1,
|
|
"year": 1985,
|
|
"genre": "Rock",
|
|
"coverArt": "1",
|
|
"size": 8421341,
|
|
"contentType": "audio/flac",
|
|
"suffix": "flac",
|
|
"starred": "2016-03-02T20:30:00Z",
|
|
"transcodedContentType": "audio/mpeg",
|
|
"transcodedSuffix": "mp3",
|
|
"duration": 146,
|
|
"bitRate": 320,
|
|
"bpm": 127,
|
|
"comment": "a comment",
|
|
"sortName": "sorted title",
|
|
"mediaType": "song",
|
|
"musicBrainzId": "4321",
|
|
"isrc": [
|
|
"ISRC-1",
|
|
"ISRC-2"
|
|
],
|
|
"genres": [
|
|
{
|
|
"name": "rock"
|
|
},
|
|
{
|
|
"name": "progressive"
|
|
}
|
|
],
|
|
"replayGain": {
|
|
"trackGain": 1,
|
|
"albumGain": 2,
|
|
"trackPeak": 3,
|
|
"albumPeak": 4,
|
|
"baseGain": 5,
|
|
"fallbackGain": 6
|
|
},
|
|
"channelCount": 2,
|
|
"samplingRate": 44100,
|
|
"bitDepth": 16,
|
|
"moods": [
|
|
"happy",
|
|
"sad"
|
|
],
|
|
"artists": [
|
|
{
|
|
"id": "1",
|
|
"name": "artist1"
|
|
},
|
|
{
|
|
"id": "2",
|
|
"name": "artist2"
|
|
}
|
|
],
|
|
"displayArtist": "artist 1 \u0026 artist 2",
|
|
"albumArtists": [
|
|
{
|
|
"id": "1",
|
|
"name": "album artist1"
|
|
},
|
|
{
|
|
"id": "2",
|
|
"name": "album artist2"
|
|
}
|
|
],
|
|
"displayAlbumArtist": "album artist 1 \u0026 album artist 2",
|
|
"contributors": [
|
|
{
|
|
"role": "role1",
|
|
"subRole": "subrole3",
|
|
"artist": {
|
|
"id": "1",
|
|
"name": "artist1"
|
|
}
|
|
},
|
|
{
|
|
"role": "role2",
|
|
"artist": {
|
|
"id": "2",
|
|
"name": "artist2"
|
|
}
|
|
},
|
|
{
|
|
"role": "composer",
|
|
"artist": {
|
|
"id": "3",
|
|
"name": "composer1"
|
|
}
|
|
},
|
|
{
|
|
"role": "composer",
|
|
"artist": {
|
|
"id": "4",
|
|
"name": "composer2"
|
|
}
|
|
}
|
|
],
|
|
"displayComposer": "composer 1 \u0026 composer 2",
|
|
"explicitStatus": "clean"
|
|
},
|
|
{
|
|
"id": "",
|
|
"isDir": false,
|
|
"bpm": 0,
|
|
"comment": "",
|
|
"sortName": "",
|
|
"mediaType": "",
|
|
"musicBrainzId": "",
|
|
"isrc": [],
|
|
"genres": [],
|
|
"replayGain": {
|
|
"trackGain": 0,
|
|
"albumGain": 0,
|
|
"trackPeak": 0,
|
|
"albumPeak": 0,
|
|
"baseGain": 0,
|
|
"fallbackGain": 0
|
|
},
|
|
"channelCount": 0,
|
|
"samplingRate": 0,
|
|
"bitDepth": 0,
|
|
"moods": [],
|
|
"artists": [],
|
|
"displayArtist": "",
|
|
"albumArtists": [],
|
|
"displayAlbumArtist": "",
|
|
"contributors": [],
|
|
"displayComposer": "",
|
|
"explicitStatus": ""
|
|
}
|
|
],
|
|
"id": "1",
|
|
"name": "N"
|
|
}
|
|
}
|