Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alternative add totalCount extension #107

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion content/en/docs/Endpoints/getalbumlist.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "getAlbumList"
linkTitle: "getAlbumList"
linkTitle: "getAlbumList [OS]"
categories:
- Lists
description: >
Expand Down Expand Up @@ -42,6 +42,7 @@ A [`subsonic-response`](../../responses/subsonic-response) element with a nested
"serverVersion": "0.1.3 (tag)",
"openSubsonic": true
"albumList": {
"totalCount": 2,
"album": [
{
"id": "200000021",
Expand Down
3 changes: 2 additions & 1 deletion content/en/docs/Endpoints/getalbumlist2.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "getAlbumList2"
linkTitle: "getAlbumList2"
linkTitle: "getAlbumList2 [OS]"
categories:
- Lists
description: >
Expand Down Expand Up @@ -42,6 +42,7 @@ A [`subsonic-response`](../../responses/subsonic-response) element with a nested
"serverVersion": "0.1.3 (tag)",
"openSubsonic": true
"albumList2": {
"totalCount": 2,
"album": [
{
"id": "200000021",
Expand Down
57 changes: 54 additions & 3 deletions content/en/docs/Endpoints/getnewestpodcasts.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "getNewestPodcasts"
linkTitle: "getNewestPodcasts"
linkTitle: "getNewestPodcasts [OS]"
categories:
- Podcast
description: >
Expand Down Expand Up @@ -28,7 +28,58 @@ A [`subsonic-response`](../../responses/subsonic-response) element with a nested
{{< tabpane persistLang=false >}}
{{< tab header="**Example**:" disabled=true />}}
{{< tab header="OpenSubsonic" lang="json">}}
// TODO
{
"subsonic-response" : {
"status" : "ok",
"version" : "1.16.1",
"newestPodcasts" : {
"totalCount": 2,
"episode" : [ {
"id" : "19",
"parent" : "78",
"isDir" : false,
"title" : "Maria James inquest finding",
"album" : "Trace",
"artist" : "Podcast",
"coverArt" : "78",
"size" : 26734080,
"contentType" : "audio/mpeg",
"suffix" : "mp3",
"duration" : 1113,
"bitRate" : 192,
"playCount" : 0,
"created" : "2023-03-16T01:02:36.481Z",
"type" : "podcast",
"streamId" : "80",
"channelId" : "2",
"description" : "A Victorian Coroner has failed to name a killer in the 1980 cold case of Maria James. Her sons are devasted. But there's still hope, in leads yet to be chased by police.",
"status" : "completed",
"publishDate" : "2022-04-01T02:30:00.000Z"
}, {
"id" : "1",
"parent" : "74",
"isDir" : false,
"title" : "DEVIN TOWNSEND PODCAST #18 - NFT's! Good or bad? Devin discusses with A7X' Matt Shadows...",
"album" : "Devin Townsend Podcast",
"artist" : "Podcast",
"coverArt" : "74",
"size" : 70531702,
"contentType" : "audio/mpeg",
"suffix" : "mp3",
"duration" : 4408,
"bitRate" : 128,
"playCount" : 0,
"created" : "2023-03-16T00:56:16.783Z",
"type" : "podcast",
"streamId" : "76",
"channelId" : "1",
"description" : "People keep talking to me about NFTs...most people seem to hate them and hated that I was even mentioning them =). After I mentioned it on Twitter, Matt hit me up and offered to give me his perspective on them as his band is heavily involved. I watched videos sent to me about the downsides, and here is an example of the other side I suppose. This is just because I'm trying to wrap my head around it. I'm not planning to do NFTs, I just wanted to learn. Take with a grain of salt, and cheers to Matt for being a good sport =)",
"status" : "completed",
"publishDate" : "2022-02-01T12:00:45.000Z"
} ]
}
}
}
{{< /tab >}}
{{< tab header="Subsonic" lang="json" >}}
// TODO
Expand All @@ -37,4 +88,4 @@ A [`subsonic-response`](../../responses/subsonic-response) element with a nested

| Field | Type | Req. | OpenS. | Details |
| --- | --- | --- | --- | --- |
| `newestPodcasts` | [`newestPodcasts`](../../responses/newestpodcasts) | **Yes** | | The podacsts |
| `newestPodcasts` | [`newestPodcasts`](../../responses/newestpodcasts) | **Yes** | | The podcasts |
62 changes: 60 additions & 2 deletions content/en/docs/Endpoints/getsongsbygenre.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "getSongsByGenre"
linkTitle: "getSongsByGenre"
linkTitle: "getSongsByGenre [OS]"
categories:
- Lists
description: >
Expand Down Expand Up @@ -31,7 +31,65 @@ A [`subsonic-response`](../../responses/subsonic-response) element with a nested
{{< tabpane persistLang=false >}}
{{< tab header="**Example**:" disabled=true />}}
{{< tab header="OpenSubsonic" lang="json">}}
// TODO
{
"subsonic-response": {
"status": "ok",
"version": "1.16.1",
"type": "ampache",
"serverVersion": "6.6.0",
"songsByGenre": {
"totalCount": 2,
"song": [
{
"id": "300000054",
"parent": "200000002",
"title": "Red&GreenSmoke",
"isDir": false,
"isVideo": false,
"type": "music",
"albumId": "200000002",
"album": "Colorsmoke EP",
"artistId": "100000002",
"artist": "Synthetic",
"coverArt": "200000002",
"duration": 400,
"bitRate": 62,
"track": 5,
"year": 2007,
"genre": "Electronic",
"size": 3209468,
"discNumber": 1,
"suffix": "mp3",
"contentType": "audio/mpeg",
"path": "/media/music/Synthetic/Synthetic_-_Colorsmoke_EP-20k217-2007(1)/05-Synthetic_-_RedGreenSmokePM20k44khM_64kb.mp3"
},
{
"id": "300000055",
"parent": "200000002",
"title": "Red&GreenSmoke",
"isDir": false,
"isVideo": false,
"type": "music",
"albumId": "200000002",
"album": "Colorsmoke EP",
"artistId": "100000002",
"artist": "Synthetic",
"coverArt": "200000002",
"duration": 400,
"bitRate": 62,
"track": 5,
"year": 2007,
"genre": "Electronic",
"size": 3209886,
"discNumber": 1,
"suffix": "mp3",
"contentType": "audio/mpeg",
"path": "/media/music/Synthetic/Synthetic_-_Colorsmoke_EP-20k217-2007(1)/05-Synthetic_-_RedGreenSmokePM20k22khS_64kb.mp3"
}
]
}
}
}
{{< /tab >}}
{{< tab header="Subsonic" lang="json" >}}
// TODO
Expand Down
3 changes: 3 additions & 0 deletions content/en/docs/Endpoints/search3.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ A [`subsonic-response`](../../responses/subsonic-response) with a nested [`searc
"serverVersion": "0.1.3 (tag)",
"openSubsonic": true
"searchResult3": {
"totalArtistCount": 1,
"artist": [
{
"id": "37ec820ca7193e17040c98f7da7c4b51",
Expand All @@ -61,6 +62,7 @@ A [`subsonic-response`](../../responses/subsonic-response) with a nested [`searc
"artistImageUrl": "https://demo.org/image.jpg"
}
],
"totalAlbumCount": 1,
"album": [
{
"id": "ad0f112b6dcf83de5e9cae85d07f0d35",
Expand All @@ -78,6 +80,7 @@ A [`subsonic-response`](../../responses/subsonic-response) with a nested [`searc
"songCount": 8
}
],
"totalArtistCount": 1,
"song": [
{
"id": "082f435a363c32c57d5edb6a678a28d4",
Expand Down
6 changes: 4 additions & 2 deletions content/en/docs/Responses/albumList.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "albumList"
linkTitle: "albumList"
linkTitle: "albumList [OS]"
description: >
Album list.
---
Expand All @@ -9,6 +9,7 @@ description: >
{{< tab header="**Example**:" disabled=true />}}
{{< tab header="OpenSubsonic" lang="json">}}
{
"totalCount": 2,
"album": [
{
"id": "200000021",
Expand Down Expand Up @@ -87,4 +88,5 @@ description: >

| Field | Type | Req. | OpenS. | Details |
| --- | --- | --- | --- | --- |
| `album` | Array of [`Child`](../child) | No | | Artist albums|
| `totalCount` | Int | No | **Yes** | Total item count for the request ignoring `size` and `offset` limits. Use `-1` to denote unsupported, unknown or uncounted values. |
| `album` | Array of [`Child`](../child) | No | | Artist albums |
4 changes: 3 additions & 1 deletion content/en/docs/Responses/albumList2.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "albumList2"
linkTitle: "albumList2"
linkTitle: "albumList2 [OS]"
description: >
Album list.
---
Expand All @@ -9,6 +9,7 @@ description: >
{{< tab header="**Example**:" disabled=true />}}
{{< tab header="OpenSubsonic" lang="json">}}
{
"totalCount": 2,
"album": [
{
"id": "200000021",
Expand Down Expand Up @@ -83,4 +84,5 @@ description: >

| Field | Type | Req. | OpenS. | Details |
| --- | --- | --- | --- | --- |
| `totalCount` | Int | No | **Yes** | Total item count for the request ignoring `size` and `offset` limits. Use `-1` to denote unsupported, unknown or uncounted values. |
| `album` | Array of [`AlbumID3`](../albumid3) | No | | Artist albums|
4 changes: 3 additions & 1 deletion content/en/docs/Responses/newestPodcasts.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "newestPodcasts"
linkTitle: "newestPodcasts"
linkTitle: "newestPodcasts [OS]"
description: >
NewestPodcasts.
---
Expand All @@ -17,3 +17,5 @@ description: >

| Field | Type | Req. | OpenS. | Details |
| --- | --- | --- | --- | --- |
| `totalCount` | Int | No | **Yes** | Total item count for the request ignoring `size` and `offset` limits. Use `-1` to denote unsupported, unknown or uncounted values. |
| `episode` | Array of [`Child`](../child) | No | | Podcast Episode |
8 changes: 7 additions & 1 deletion content/en/docs/Responses/searchResult3.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: "searchResult3"
linkTitle: "searchResult3"
linkTitle: "searchResult3 [OS]"
description: >
search3 result.
---
Expand All @@ -9,6 +9,7 @@ description: >
{{< tab header="**Example**:" disabled=true />}}
{{< tab header="OpenSubsonic" lang="json">}}
{
"totalArtistCount": 1,
"artist": [
{
"id": "37ec820ca7193e17040c98f7da7c4b51",
Expand All @@ -19,6 +20,7 @@ description: >
"artistImageUrl": "https://demo.org/image.jpg"
}
],
"totalAlbumCount": 1,
"album": [
{
"id": "ad0f112b6dcf83de5e9cae85d07f0d35",
Expand All @@ -36,6 +38,7 @@ description: >
"songCount": 8,
}
],
"totalSongCount": 1,
"song": [
{
"id": "082f435a363c32c57d5edb6a678a28d4",
Expand Down Expand Up @@ -133,6 +136,9 @@ description: >

| Field | Type | Req. | OpenS. | Details |
| --- | --- | --- | --- | --- |
| `totalArtistCount` | Int | No | **Yes** | Total item count for the request ignoring `artistCount` limits. Use `-1` to denote unsupported, unknown or uncounted values. |
| `artist` | Array of [`ArtistID3`](../artistid3) | No | | Matching artists |
| `totalAlbumCount` | Int | No | **Yes** | Total item count for the request ignoring `albumCount` limits. Use `-1` to denote unsupported, unknown or uncounted values. |
| `album` | Array of [`AlbumID3`](../albumid3) | No | | Matching albums |
| `totalSongCount` | Int | No | **Yes** | Total item count for the request ignoring `songCount` limits. Use `-1` to denote unsupported, unknown or uncounted values. |
| `song` | Array of [`Child`](../child) | No | | Matching songs |
56 changes: 54 additions & 2 deletions content/en/docs/Responses/songsByGenre.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,64 @@
---
title: "songsByGenre"
linkTitle: "songsByGenre"
linkTitle: "songsByGenre [OS]"
description: >
songsByGenre.
---

{{< tabpane persistLang=false >}}
{{< tab header="**Example**:" disabled=true />}}
{{< tab header="OpenSubsonic" lang="json">}}
// TODO
{
"totalCount": 2,
"song" : [
{
"id" : "12",
"parent" : "10",
"isDir" : false,
"title" : "Red&GreenSmoke",
"album" : "Colorsmoke EP",
"artist" : "Synthetic",
"track" : 5,
"year" : 2007,
"genre" : "Electronic",
"coverArt" : "10",
"size" : 3209340,
"contentType" : "audio/mpeg",
"suffix" : "mp3",
"duration" : 400,
"bitRate" : 64,
"path" : "Synthetic/Synthetic_-_Colorsmoke_EP-20k217-2007(1)/05-Synthetic_-_RedGreenSmokePM20k44khM_64kb.mp3",
"playCount" : 0,
"created" : "2022-02-10T23:16:05.491Z",
"albumId" : "1",
"artistId" : "1",
"type" : "music"
},
{
"id" : "13",
"parent" : "10",
"isDir" : false,
"title" : "Red&GreenSmoke",
"album" : "Colorsmoke EP",
"artist" : "Synthetic",
"track" : 5,
"year" : 2007,
"genre" : "Electronic",
"coverArt" : "10",
"size" : 3209758,
"contentType" : "audio/mpeg",
"suffix" : "mp3",
"duration" : 800,
"bitRate" : 64,
"path" : "Synthetic/Synthetic_-_Colorsmoke_EP-20k217-2007(1)/05-Synthetic_-_RedGreenSmokePM20k22khS_64kb.mp3",
"playCount" : 0,
"created" : "2022-02-10T23:16:05.075Z",
"albumId" : "1",
"artistId" : "1",
"type" : "music"
}
]
}
{{< /tab >}}
{{< tab header="Subsonic" lang="json" >}}
// TODO
Expand All @@ -17,3 +67,5 @@ description: >

| Field | Type | Req. | OpenS. | Details |
| --- | --- | --- | --- | --- |
| `totalCount` | Int | No | **Yes** | Total item count for the request ignoring `size` and `offset` limits. Use `-1` to denote unsupported, unknown or uncounted values. |
| `song` | Array of [`Child`](../child) | No | | Genre songs|