mirror of
https://github.com/BinaryAlley/Nemera.git
synced 2026-12-02 20:11:10 +00:00
Adds the music library API endpoints, their OpenAPI summaries, and the endpoint tests
This commit is contained in:
1 parent
1fad9316ce
commit
9cc0852236
40 files changed
+1305
-667
No files matched your search
+133
-95
@@ -1,4 +1,4 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using FastEndpoints;
|
||||
using Lumina.Contracts.DTO.Common;
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
@@ -41,18 +41,15 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "1975 original release",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12,
|
||||
Language: new(
|
||||
LanguageCode: "en",
|
||||
LanguageName: "English",
|
||||
@@ -72,21 +69,29 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
[
|
||||
new(Name: "classic"),
|
||||
new(Name: "vinyl")
|
||||
]
|
||||
],
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Producer
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Engineer
|
||||
)
|
||||
@@ -114,6 +119,7 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -123,8 +129,8 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -147,24 +153,37 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
[
|
||||
new(Name: "classic"),
|
||||
new(Name: "epic")
|
||||
]
|
||||
],
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs:
|
||||
[
|
||||
new(Value: "GBUM71029604")
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new(Name: "dramatic"),
|
||||
new(Name: "anxious")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
@@ -184,15 +203,8 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new(Name: "dramatic"),
|
||||
new(Name: "anxious")
|
||||
],
|
||||
Isrcs:
|
||||
[
|
||||
new(Value: "GBUM71029604")
|
||||
]
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1
|
||||
),
|
||||
new(
|
||||
Path: "/music/queen/a-night-at-the-opera/02-youre-my-best-friend.flac",
|
||||
@@ -200,6 +212,7 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
Title: "You're My Best Friend",
|
||||
OriginalTitle: "You're My Best Friend",
|
||||
Description: "A song by the British rock band Queen, written by bass guitarist John Deacon. It was originally released on the album A Night at the Opera in 1975 and as a single in 1976.",
|
||||
Disambiguation: "album version",
|
||||
DurationInSeconds: 181,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -209,8 +222,8 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1976, 6, 18),
|
||||
OriginalReleaseYear: 1976,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -233,24 +246,37 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
[
|
||||
new(Name: "classic"),
|
||||
new(Name: "love")
|
||||
]
|
||||
],
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.BMajor,
|
||||
Bpm: 118,
|
||||
Work: "You're My Best Friend",
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "You're My Best Friend",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs:
|
||||
[
|
||||
new(Value: "GBUM71029605")
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new(Name: "happy"),
|
||||
new(Name: "romantic")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.BassGuitar
|
||||
)
|
||||
@@ -270,15 +296,8 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new(Name: "happy"),
|
||||
new(Name: "romantic")
|
||||
],
|
||||
Isrcs:
|
||||
[
|
||||
new(Value: "GBUM71029605")
|
||||
]
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1
|
||||
)
|
||||
]
|
||||
);
|
||||
@@ -294,7 +313,7 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
RequestParam(r => r.Metadata!.ReleaseInfo!.ReReleaseYear, "The re-release or reissue year of the album. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseInfo!.ReleaseCountry, "The country or region of the release of the album. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseInfo!.ReleaseVersion, "The version or edition of the release of the album. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseType, "The type of the release. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseTypes, "The type of the release. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseStatus, "The status of the release. Optional.");
|
||||
RequestParam(r => r.Metadata!.TotalDiscs, "The number of discs of the release. Optional.");
|
||||
RequestParam(r => r.Metadata!.TotalTracks, "The number of tracks of the release. Optional.");
|
||||
@@ -310,7 +329,7 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
RequestParam(r => r.Metadata!.Genres, "The list of genres associated with the album. Required.");
|
||||
RequestParam(r => r.MediaFormat, "The physical or digital medium of the album. Optional.");
|
||||
RequestParam(r => r.Barcode, "The barcode of the album. Optional.");
|
||||
RequestParam(r => r.CatalogNumber, "The catalog number of the album. Optional.");
|
||||
RequestParam(r => r.CatalogNumbers, "The catalog numbers of the album. Optional.");
|
||||
RequestParam(r => r.MusicBrainzReleaseId, "The MusicBrainz identifier of the release. Optional.");
|
||||
RequestParam(r => r.MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group. Optional.");
|
||||
RequestParam(r => r.MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist. Optional.");
|
||||
@@ -324,13 +343,13 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.Title, "The title of the album.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.OriginalTitle, "The original title of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.Description, "The description of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseType, "The type of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseTypes, "The type of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseStatus, "The status of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.TotalDiscs, "The number of discs of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.TotalTracks, "The number of tracks of the release.");
|
||||
ResponseParam<AlbumResponse>(r => r.MediaFormat, "The physical or digital medium of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Barcode, "The barcode of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.CatalogNumber, "The catalog number of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.CatalogNumbers, "The catalog numbers of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseId, "The MusicBrainz identifier of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist, if applicable.");
|
||||
@@ -363,11 +382,12 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "1975 original release",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
@@ -389,25 +409,27 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
new(Name: "classic"),
|
||||
new(Name: "vinyl")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: default,
|
||||
Contributors: [
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Producer
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Engineer
|
||||
)
|
||||
@@ -426,6 +448,8 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks:
|
||||
[
|
||||
new(
|
||||
@@ -437,11 +461,12 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -468,25 +493,34 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
Channels: 2,
|
||||
BitDepth: 16,
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
Bitrate: 980,
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new(Value: "GBUM71029604")
|
||||
],
|
||||
Moods: [
|
||||
new(Name: "dramatic"),
|
||||
new(Name: "anxious")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: default,
|
||||
Contributors: [
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
@@ -505,13 +539,10 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
Moods: [
|
||||
new(Name: "dramatic"),
|
||||
new(Name: "anxious")
|
||||
],
|
||||
Isrcs: [
|
||||
new(Value: "GBUM71029604")
|
||||
]
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
),
|
||||
new(
|
||||
Id: Guid.NewGuid(),
|
||||
@@ -522,11 +553,12 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
Title: "You're My Best Friend",
|
||||
OriginalTitle: "You're My Best Friend",
|
||||
Description: "A song by the British rock band Queen, written by bass guitarist John Deacon. It was originally released on the album A Night at the Opera in 1975 and as a single in 1976.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1976, 6, 18),
|
||||
OriginalReleaseYear: 1976,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -553,25 +585,34 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
Channels: 2,
|
||||
BitDepth: 16,
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 912
|
||||
Bitrate: 912,
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.BMajor,
|
||||
Bpm: 118,
|
||||
Work: "You're My Best Friend",
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "You're My Best Friend",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new(Value: "GBUM71029609")
|
||||
],
|
||||
Moods: [
|
||||
new(Name: "happy"),
|
||||
new(Name: "warm")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: default,
|
||||
Contributors: [
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
@@ -590,13 +631,10 @@ public class AddAlbumEndpointSummary : Summary<AddAlbumEndpoint, AddAlbumRequest
|
||||
VoteCount: 567
|
||||
)
|
||||
],
|
||||
Moods: [
|
||||
new(Name: "happy"),
|
||||
new(Name: "warm")
|
||||
],
|
||||
Isrcs: [
|
||||
new(Value: "GBUM71029609")
|
||||
]
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
]
|
||||
)
|
||||
|
||||
+14
-9
@@ -35,13 +35,13 @@ public class GetAlbumEndpointSummary : Summary<GetAlbumEndpoint, EmptyRequest>
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.Title, "The title of the album.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.OriginalTitle, "The original title of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.Description, "The description of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseType, "The type of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseTypes, "The type of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseStatus, "The status of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.TotalDiscs, "The number of discs of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.TotalTracks, "The number of tracks of the release.");
|
||||
ResponseParam<AlbumResponse>(r => r.MediaFormat, "The physical or digital medium of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Barcode, "The barcode of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.CatalogNumber, "The catalog number of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.CatalogNumbers, "The catalog numbers of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseId, "The MusicBrainz identifier of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist, if applicable.");
|
||||
@@ -70,15 +70,16 @@ public class GetAlbumEndpointSummary : Summary<GetAlbumEndpoint, EmptyRequest>
|
||||
Id: Guid.NewGuid(),
|
||||
ArtistId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Metadata: new AlbumMetadataDto(
|
||||
Metadata: new MusicAlbumMetadataDto(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
@@ -100,19 +101,21 @@ public class GetAlbumEndpointSummary : Summary<GetAlbumEndpoint, EmptyRequest>
|
||||
new TagDto(Name: "classic"),
|
||||
new TagDto(Name: "vinyl")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -137,6 +140,8 @@ public class GetAlbumEndpointSummary : Summary<GetAlbumEndpoint, EmptyRequest>
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks: []
|
||||
)
|
||||
);
|
||||
|
||||
+48
-34
@@ -41,10 +41,10 @@ public class GetAlbumTracksEndpointSummary : Summary<GetAlbumTracksEndpoint, Emp
|
||||
ResponseParam<TrackResponse>(r => r.Script, "The script used by the language of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Key, "The musical key of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Bpm, "The tempo of the track in beats per minute, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work!.Title, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzRecordingId, "The MusicBrainz identifier of the recording, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzTrackId, "The MusicBrainz identifier of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.CreatedOnUtc, "The date and time when the track was created.");
|
||||
ResponseParam<TrackResponse>(r => r.UpdatedOnUtc, "The date and time when the track was last updated, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Moods, "The list of moods of the track.");
|
||||
@@ -80,15 +80,16 @@ public class GetAlbumTracksEndpointSummary : Summary<GetAlbumTracksEndpoint, Emp
|
||||
AlbumId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -110,6 +111,7 @@ public class GetAlbumTracksEndpointSummary : Summary<GetAlbumTracksEndpoint, Emp
|
||||
new GenreDto(Name: "Rock"),
|
||||
new GenreDto(Name: "Progressive Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -117,17 +119,25 @@ public class GetAlbumTracksEndpointSummary : Summary<GetAlbumTracksEndpoint, Emp
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -152,28 +162,26 @@ public class GetAlbumTracksEndpointSummary : Summary<GetAlbumTracksEndpoint, Emp
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
]
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
),
|
||||
new TrackResponse(
|
||||
Id: Guid.NewGuid(),
|
||||
AlbumId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/02-youre-my-best-friend.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "You're My Best Friend",
|
||||
OriginalTitle: "You're My Best Friend",
|
||||
Description: "A song by the British rock band Queen, written by bass guitarist John Deacon. It was released as the second single from the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -195,6 +203,7 @@ public class GetAlbumTracksEndpointSummary : Summary<GetAlbumTracksEndpoint, Emp
|
||||
new GenreDto(Name: "Rock"),
|
||||
new GenreDto(Name: "Pop Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 174,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -202,17 +211,25 @@ public class GetAlbumTracksEndpointSummary : Summary<GetAlbumTracksEndpoint, Emp
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 912
|
||||
),
|
||||
TrackNumber: 2,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 110,
|
||||
Work: "You're My Best Friend",
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "You're My Best Friend",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029605")
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "happy"),
|
||||
new MoodDto(Name: "romantic")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -237,13 +254,10 @@ public class GetAlbumTracksEndpointSummary : Summary<GetAlbumTracksEndpoint, Emp
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "happy"),
|
||||
new MoodDto(Name: "romantic")
|
||||
],
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029605")
|
||||
]
|
||||
TrackNumber: 2,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
}
|
||||
);
|
||||
|
||||
+30
-20
@@ -41,7 +41,7 @@ public class UpdateAlbumEndpointSummary : Summary<UpdateAlbumEndpoint, UpdateAlb
|
||||
RequestParam(r => r.Metadata!.ReleaseInfo!.ReReleaseYear, "The re-release or reissue year of the album. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseInfo!.ReleaseCountry, "The country or region of the release of the album. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseInfo!.ReleaseVersion, "The version or edition of the release of the album. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseType, "The type of the release. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseTypes, "The type of the release. Optional.");
|
||||
RequestParam(r => r.Metadata!.ReleaseStatus, "The status of the release. Optional.");
|
||||
RequestParam(r => r.Metadata!.TotalDiscs, "The number of discs of the release. Optional.");
|
||||
RequestParam(r => r.Metadata!.TotalTracks, "The number of tracks of the release. Optional.");
|
||||
@@ -57,7 +57,7 @@ public class UpdateAlbumEndpointSummary : Summary<UpdateAlbumEndpoint, UpdateAlb
|
||||
RequestParam(r => r.Metadata!.Tags, "The list of tags that further describe or categorize the album. Required.");
|
||||
RequestParam(r => r.MediaFormat, "The physical or digital medium of the album. Optional.");
|
||||
RequestParam(r => r.Barcode, "The barcode of the album. Optional.");
|
||||
RequestParam(r => r.CatalogNumber, "The catalog number of the album. Optional.");
|
||||
RequestParam(r => r.CatalogNumbers, "The catalog numbers of the album. Optional.");
|
||||
RequestParam(r => r.MusicBrainzReleaseId, "The MusicBrainz identifier of the release. Optional.");
|
||||
RequestParam(r => r.MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group. Optional.");
|
||||
RequestParam(r => r.MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist. Optional.");
|
||||
@@ -65,22 +65,19 @@ public class UpdateAlbumEndpointSummary : Summary<UpdateAlbumEndpoint, UpdateAlb
|
||||
RequestParam(r => r.Ratings, "The list of ratings for this album. Required.");
|
||||
|
||||
ExampleRequest = new UpdateAlbumRequest(
|
||||
Metadata: new AlbumMetadataDto(
|
||||
Metadata: new MusicAlbumMetadataDto(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12,
|
||||
Language: new LanguageInfoDto(
|
||||
LanguageCode: "en",
|
||||
LanguageName: "English",
|
||||
@@ -100,11 +97,19 @@ public class UpdateAlbumEndpointSummary : Summary<UpdateAlbumEndpoint, UpdateAlb
|
||||
[
|
||||
new TagDto(Name: "classic"),
|
||||
new TagDto(Name: "vinyl")
|
||||
]
|
||||
],
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
@@ -142,13 +147,13 @@ public class UpdateAlbumEndpointSummary : Summary<UpdateAlbumEndpoint, UpdateAlb
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.Title, "The title of the album.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.OriginalTitle, "The original title of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.Description, "The description of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseType, "The type of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseTypes, "The type of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseStatus, "The status of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.TotalDiscs, "The number of discs of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.TotalTracks, "The number of tracks of the release.");
|
||||
ResponseParam<AlbumResponse>(r => r.MediaFormat, "The physical or digital medium of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Barcode, "The barcode of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.CatalogNumber, "The catalog number of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.CatalogNumbers, "The catalog numbers of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseId, "The MusicBrainz identifier of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist, if applicable.");
|
||||
@@ -177,15 +182,16 @@ public class UpdateAlbumEndpointSummary : Summary<UpdateAlbumEndpoint, UpdateAlb
|
||||
Id: Guid.NewGuid(),
|
||||
ArtistId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Metadata: new AlbumMetadataDto(
|
||||
Metadata: new MusicAlbumMetadataDto(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
@@ -207,19 +213,21 @@ public class UpdateAlbumEndpointSummary : Summary<UpdateAlbumEndpoint, UpdateAlb
|
||||
new TagDto(Name: "classic"),
|
||||
new TagDto(Name: "vinyl")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -244,6 +252,8 @@ public class UpdateAlbumEndpointSummary : Summary<UpdateAlbumEndpoint, UpdateAlb
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks: []
|
||||
)
|
||||
);
|
||||
|
||||
+183
-100
@@ -1,4 +1,4 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using FastEndpoints;
|
||||
using Lumina.Contracts.DTO.Common;
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
@@ -39,31 +39,51 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Guid libraryId = Guid.NewGuid();
|
||||
|
||||
ExampleRequest = new AddArtistRequest(
|
||||
Name: "Queen",
|
||||
Metadata: new MusicArtistMetadataDto(
|
||||
Name: "Queen",
|
||||
SortName: "Queen",
|
||||
Disambiguation: "British rock band",
|
||||
Type: MusicArtistType.Group,
|
||||
Gender: MusicArtistGender.NotApplicable,
|
||||
Country: "GB",
|
||||
Area: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
BeginArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
EndArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
LifeSpanBegin: new DateOnly(1970, 6, 27),
|
||||
LifeSpanEnd: new DateOnly(1991, 11, 24),
|
||||
IsEnded: false,
|
||||
Aliases: [new MusicArtistAliasDto(Name: "The Queen", SortName: "Queen", Type: "Artist name", Locale: "en", IsPrimary: false, BeginDate: new DateOnly(1970, 6, 27), EndDate: new DateOnly(1991, 11, 24), IsEnded: true)],
|
||||
Genres: [new GenreDto(Name: "Rock")],
|
||||
Tags: [new TagDto(Name: "classic")]
|
||||
),
|
||||
Website: "https://www.queenonline.com",
|
||||
MusicBrainzArtistId: Guid.NewGuid(),
|
||||
Ipis: ["00012345678"],
|
||||
Isnis: ["0000000123456789"],
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
],
|
||||
Ratings: [new AudioRatingDto(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
Albums: [
|
||||
new(
|
||||
Metadata: new(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
@@ -85,24 +105,28 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
new(Name: "Rock"),
|
||||
new(Name: "Progressive Rock")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Producer
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Engineer
|
||||
)
|
||||
@@ -128,11 +152,12 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -154,6 +179,7 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
new(Name: "Rock"),
|
||||
new(Name: "Progressive Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -161,29 +187,32 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new(Value: "GBUM71029604")
|
||||
],
|
||||
Moods: [
|
||||
new(Name: "dramatic"),
|
||||
new(Name: "anxious")
|
||||
],
|
||||
Isrcs: [
|
||||
new(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
@@ -201,7 +230,9 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1
|
||||
),
|
||||
new(
|
||||
Path: "/music/queen/a-night-at-the-opera/07-youre-my-best-friend.flac",
|
||||
@@ -209,11 +240,12 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Title: "You're My Best Friend",
|
||||
OriginalTitle: "You're My Best Friend",
|
||||
Description: "A song by the British rock band Queen, written by bass guitarist John Deacon. It was originally released on the album A Night at the Opera in 1975 and as a single in 1976.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1976, 6, 18),
|
||||
OriginalReleaseYear: 1976,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -235,6 +267,7 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
new(Name: "Rock"),
|
||||
new(Name: "Pop Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 181,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -242,29 +275,32 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 912
|
||||
),
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.BMajor,
|
||||
Bpm: 118,
|
||||
Work: "You're My Best Friend",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "You're My Best Friend",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new(Value: "GBUM71029609")
|
||||
],
|
||||
Moods: [
|
||||
new(Name: "happy"),
|
||||
new(Name: "warm")
|
||||
],
|
||||
Isrcs: [
|
||||
new(Value: "GBUM71029609")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.BassGuitar
|
||||
)
|
||||
@@ -282,14 +318,16 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 567
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1
|
||||
)
|
||||
]
|
||||
)
|
||||
]
|
||||
);
|
||||
|
||||
RequestParam(r => r.Name, "The name of the artist. Required.");
|
||||
RequestParam(r => r.Metadata!.Name, "The name of the artist. Required.");
|
||||
RequestParam(r => r.Website, "The website of the artist. Optional.");
|
||||
RequestParam(r => r.MusicBrainzArtistId, "The MusicBrainz identifier of the artist. Optional.");
|
||||
RequestParam(r => r.Contributors, "The list of media contributors that make up the artist. Required.");
|
||||
@@ -308,20 +346,20 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language, "The language of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language!.LanguageCode, "The ISO code of the language (e.g., \"en\" for English). Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language!.LanguageName, "The name of the language in English. Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage, "The original language of the album, if it has been translated. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage!.LanguageCode, "The ISO code of the language (e.g., \"en\" for English). Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage!.LanguageName, "The name of the language in English. Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Tags, "The list of tags that further describe or categorize the album. Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Genres, "The list of genres associated with the album. Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.ReleaseType, "The type of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.ReleaseTypes, "The type of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.ReleaseStatus, "The status of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.TotalDiscs, "The number of discs of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.TotalTracks, "The number of tracks of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].MediaFormat, "The physical or digital medium of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].Barcode, "The barcode of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].CatalogNumber, "The catalog number of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].CatalogNumbers, "The catalog numbers of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].MusicBrainzReleaseId, "The MusicBrainz identifier of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group. Optional.");
|
||||
RequestParam(r => r.Albums![0].MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist. Optional.");
|
||||
@@ -343,11 +381,11 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language, "The language of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language!.LanguageCode, "The ISO code of the language (e.g., \"en\" for English). Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language!.LanguageName, "The name of the language in English. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage, "The original language of the track, if it has been translated. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage!.LanguageCode, "The ISO code of the language (e.g., \"en\" for English). Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage!.LanguageName, "The name of the language in English. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Tags, "The list of tags that further describe or categorize the track. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Genres, "The list of genres associated with the track. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.DurationInSeconds, "The duration of the audio of the track in seconds. Required.");
|
||||
@@ -361,10 +399,10 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Script, "The script used by the language of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Key, "The musical key of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Bpm, "The tempo of the track in beats per minute. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Work, "The title of the work the track is a recording of. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Work!.Title, "The title of the work the track is a recording of. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].MusicBrainzRecordingId, "The MusicBrainz identifier of the recording. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].MusicBrainzTrackId, "The MusicBrainz identifier of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].MusicBrainzWorkId, "The MusicBrainz identifier of the work. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Moods, "The list of moods of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Isrcs, "The list of ISRC (International Standard Recording Code) of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Contributors, "The list of media contributors that performed on the track. Required.");
|
||||
@@ -372,7 +410,7 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
|
||||
ResponseParam<ArtistResponse>(r => r.Id, "The Id of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.LibraryId, "The Id of the media library this artist belongs to.");
|
||||
ResponseParam<ArtistResponse>(r => r.Name, "The name of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.Metadata!.Name, "The name of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.Website, "The website of the artist, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.MusicBrainzArtistId, "The MusicBrainz identifier of the artist, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Contributors, "The list of references to the media contributors that make up the artist, each with the role they played.");
|
||||
@@ -401,13 +439,13 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the original language of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.Tags, "The list of tags of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.Genres, "The list of genres of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.ReleaseType, "The type of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.ReleaseTypes, "The type of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.ReleaseStatus, "The status of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.TotalDiscs, "The number of discs of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.TotalTracks, "The number of tracks of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].MediaFormat, "The physical or digital medium of the album, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Barcode, "The barcode of the album, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].CatalogNumber, "The catalog number of the album, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].CatalogNumbers, "The catalog numbers of the album, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].MusicBrainzReleaseId, "The MusicBrainz identifier of the release, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist, if applicable.");
|
||||
@@ -452,10 +490,10 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Script, "The script used by the language of the track, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Key, "The musical key of the track, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Bpm, "The tempo of the track in beats per minute, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Work, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Work!.Title, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].MusicBrainzRecordingId, "The MusicBrainz identifier of the recording, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].MusicBrainzTrackId, "The MusicBrainz identifier of the track, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].CreatedOnUtc, "The date and time when the track was created.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].UpdatedOnUtc, "The date and time when the track was last updated, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Moods, "The list of moods of the track.");
|
||||
@@ -469,14 +507,39 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
example: new ArtistResponse(
|
||||
Id: artistId,
|
||||
LibraryId: libraryId,
|
||||
Name: "Queen",
|
||||
Metadata: new MusicArtistMetadataDto(
|
||||
Name: "Queen",
|
||||
SortName: "Queen",
|
||||
Disambiguation: "British rock band",
|
||||
Type: MusicArtistType.Group,
|
||||
Gender: MusicArtistGender.NotApplicable,
|
||||
Country: "GB",
|
||||
Area: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
BeginArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
EndArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
LifeSpanBegin: new DateOnly(1970, 6, 27),
|
||||
LifeSpanEnd: new DateOnly(1991, 11, 24),
|
||||
IsEnded: false,
|
||||
Aliases: [new MusicArtistAliasDto(Name: "The Queen", SortName: "Queen", Type: "Artist name", Locale: "en", IsPrimary: false, BeginDate: new DateOnly(1970, 6, 27), EndDate: new DateOnly(1991, 11, 24), IsEnded: true)],
|
||||
Genres: [new GenreDto(Name: "Rock")],
|
||||
Tags: [new TagDto(Name: "classic")]
|
||||
),
|
||||
Website: "https://www.queenonline.com",
|
||||
MusicBrainzArtistId: Guid.NewGuid(),
|
||||
Ipis: ["00012345678"],
|
||||
Isnis: ["0000000123456789"],
|
||||
Contributors:
|
||||
[
|
||||
new(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Vocals),
|
||||
new(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Guitar)
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
],
|
||||
Ratings: [new AudioRatingDto(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
Albums:
|
||||
[
|
||||
new(
|
||||
@@ -487,11 +550,12 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
@@ -515,25 +579,28 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
new(Name: "classic"),
|
||||
new(Name: "vinyl")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: default,
|
||||
Contributors: [
|
||||
new(
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Producer
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Engineer
|
||||
)
|
||||
@@ -553,6 +620,8 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks:
|
||||
[
|
||||
new(
|
||||
@@ -564,11 +633,12 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -592,6 +662,7 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
new(Name: "Rock"),
|
||||
new(Name: "Progressive Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -599,33 +670,34 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: default,
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs:
|
||||
[
|
||||
new(Value: "GBUM71029604")
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new(Name: "dramatic"),
|
||||
new(Name: "anxious")
|
||||
],
|
||||
Isrcs:
|
||||
[
|
||||
new(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
@@ -644,7 +716,11 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
),
|
||||
new(
|
||||
Id: Guid.NewGuid(),
|
||||
@@ -655,11 +731,12 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Title: "You're My Best Friend",
|
||||
OriginalTitle: "You're My Best Friend",
|
||||
Description: "A song by the British rock band Queen, written by bass guitarist John Deacon. It was originally released on the album A Night at the Opera in 1975 and as a single in 1976.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1976, 6, 18),
|
||||
OriginalReleaseYear: 1976,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -683,6 +760,7 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
new(Name: "Rock"),
|
||||
new(Name: "Pop Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 181,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -690,33 +768,34 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 912
|
||||
),
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.BMajor,
|
||||
Bpm: 118,
|
||||
Work: "You're My Best Friend",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: default,
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "You're My Best Friend",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs:
|
||||
[
|
||||
new(Value: "GBUM71029609")
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new(Name: "happy"),
|
||||
new(Name: "warm")
|
||||
],
|
||||
Isrcs:
|
||||
[
|
||||
new(Value: "GBUM71029609")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Vocals
|
||||
),
|
||||
new(
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
@@ -735,13 +814,17 @@ public class AddArtistEndpointSummary : Summary<AddArtistEndpoint, AddArtistRequ
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 567
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
]
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: default
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
+123
-7
@@ -1,6 +1,12 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using FastEndpoints;
|
||||
using Lumina.Contracts.DTO.Common;
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary.MusicLibrary;
|
||||
using Lumina.Contracts.Responses.MediaLibrary.AudioLibrary.MusicLibrary.Artists;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.AudioLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.Common;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaContributors;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
@@ -25,7 +31,7 @@ public class GetArtistEndpointSummary : Summary<GetArtistEndpoint, EmptyRequest>
|
||||
|
||||
ResponseParam<ArtistResponse>(r => r.Id, "The Id of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.LibraryId, "The Id of the media library this artist belongs to.");
|
||||
ResponseParam<ArtistResponse>(r => r.Name, "The name of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.Metadata!.Name, "The name of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.Website, "The website of the artist, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.MusicBrainzArtistId, "The MusicBrainz identifier of the artist, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Contributors, "The list of references to the media contributors that make up the artist, each with the role they played.");
|
||||
@@ -37,17 +43,127 @@ public class GetArtistEndpointSummary : Summary<GetArtistEndpoint, EmptyRequest>
|
||||
example: new ArtistResponse(
|
||||
Id: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Name: "Queen",
|
||||
Metadata: new MusicArtistMetadataDto(
|
||||
Name: "Queen",
|
||||
SortName: "Queen",
|
||||
Disambiguation: "British rock band",
|
||||
Type: MusicArtistType.Group,
|
||||
Gender: MusicArtistGender.NotApplicable,
|
||||
Country: "GB",
|
||||
Area: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
BeginArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
EndArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
LifeSpanBegin: new DateOnly(1970, 6, 27),
|
||||
LifeSpanEnd: new DateOnly(1991, 11, 24),
|
||||
IsEnded: false,
|
||||
Aliases: [new MusicArtistAliasDto(Name: "The Queen", SortName: "Queen", Type: "Artist name", Locale: "en", IsPrimary: false, BeginDate: new DateOnly(1970, 6, 27), EndDate: new DateOnly(1991, 11, 24), IsEnded: true)],
|
||||
Genres: [new GenreDto(Name: "Rock")],
|
||||
Tags: [new TagDto(Name: "classic")]
|
||||
),
|
||||
Website: "https://www.queenonline.com",
|
||||
MusicBrainzArtistId: Guid.NewGuid(),
|
||||
Ipis: ["00012345678"],
|
||||
Isnis: ["0000000123456789"],
|
||||
Contributors:
|
||||
[
|
||||
new(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Vocals),
|
||||
new(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Guitar)
|
||||
new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Vocals),
|
||||
new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Guitar)
|
||||
],
|
||||
Albums: [],
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Ratings: [new AudioRatingDto(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
Albums:
|
||||
[
|
||||
new(
|
||||
Id: Guid.NewGuid(),
|
||||
ArtistId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Metadata: new(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
Language: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
OriginalLanguage: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
Genres: [new(Name: "Rock"), new(Name: "Progressive Rock")],
|
||||
Tags: [new(Name: "classic"), new(Name: "vinyl")],
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
Contributors: [new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Producer)],
|
||||
Ratings: [new(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks:
|
||||
[
|
||||
new(
|
||||
Id: Guid.NewGuid(),
|
||||
AlbumId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
Language: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
OriginalLanguage: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
Tags: [new(Name: "classic"), new(Name: "epic")],
|
||||
Genres: [new(Name: "Rock"), new(Name: "Progressive Rock")],
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
BitDepth: 16,
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980,
|
||||
IsVideo: false
|
||||
),
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: new MusicWorkDto(MusicBrainzWorkId: Guid.NewGuid(), Title: "Bohemian Rhapsody", Type: "Song", Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")], Iswcs: ["T-010489707-6"]),
|
||||
Isrcs: [new(Value: "GBUM71029604")],
|
||||
Moods: [new(Name: "dramatic"), new(Name: "anxious")],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors: [new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Vocals)],
|
||||
Ratings: [new(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
]
|
||||
)
|
||||
]
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
+26
-16
@@ -35,13 +35,13 @@ public class GetArtistAlbumsEndpointSummary : Summary<GetArtistAlbumsEndpoint, E
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.Title, "The title of the album.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.OriginalTitle, "The original title of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.Description, "The description of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseType, "The type of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseTypes, "The type of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.ReleaseStatus, "The status of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.TotalDiscs, "The number of discs of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Metadata!.TotalTracks, "The number of tracks of the release.");
|
||||
ResponseParam<AlbumResponse>(r => r.MediaFormat, "The physical or digital medium of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.Barcode, "The barcode of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.CatalogNumber, "The catalog number of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.CatalogNumbers, "The catalog numbers of the album, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseId, "The MusicBrainz identifier of the release, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group, if applicable.");
|
||||
ResponseParam<AlbumResponse>(r => r.MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist, if applicable.");
|
||||
@@ -72,15 +72,16 @@ public class GetArtistAlbumsEndpointSummary : Summary<GetArtistAlbumsEndpoint, E
|
||||
Id: Guid.NewGuid(),
|
||||
ArtistId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Metadata: new AlbumMetadataDto(
|
||||
Metadata: new MusicAlbumMetadataDto(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
@@ -102,19 +103,21 @@ public class GetArtistAlbumsEndpointSummary : Summary<GetArtistAlbumsEndpoint, E
|
||||
new TagDto(Name: "classic"),
|
||||
new TagDto(Name: "vinyl")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -139,21 +142,24 @@ public class GetArtistAlbumsEndpointSummary : Summary<GetArtistAlbumsEndpoint, E
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks: []
|
||||
),
|
||||
new AlbumResponse(
|
||||
Id: Guid.NewGuid(),
|
||||
ArtistId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Metadata: new AlbumMetadataDto(
|
||||
Metadata: new MusicAlbumMetadataDto(
|
||||
Title: "The Works",
|
||||
OriginalTitle: "The Works",
|
||||
Description: "The eleventh studio album by the British rock band Queen, released in 1984. It was the first Queen album to be released on CD.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1984, 2, 27),
|
||||
OriginalReleaseYear: 1984,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -175,19 +181,21 @@ public class GetArtistAlbumsEndpointSummary : Summary<GetArtistAlbumsEndpoint, E
|
||||
new TagDto(Name: "classic"),
|
||||
new TagDto(Name: "compact disc")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 9
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282771043",
|
||||
CatalogNumber: "EMC 2400141",
|
||||
CatalogNumbers: ["EMC 2400141"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -212,6 +220,8 @@ public class GetArtistAlbumsEndpointSummary : Summary<GetArtistAlbumsEndpoint, E
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks: []
|
||||
)
|
||||
}
|
||||
|
||||
+236
-9
@@ -1,8 +1,15 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using FastEndpoints;
|
||||
using Lumina.Contracts.DTO.Common;
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary;
|
||||
using Lumina.Contracts.DTO.MediaLibrary.AudioLibrary.MusicLibrary;
|
||||
using Lumina.Contracts.Requests.MediaLibrary.AudioLibrary.MusicLibrary.Artists;
|
||||
using Lumina.Contracts.Responses.Common;
|
||||
using Lumina.Contracts.Responses.MediaLibrary.AudioLibrary.MusicLibrary.Artists;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.AudioLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.Common;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaContributors;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
@@ -36,7 +43,7 @@ public class GetArtistsEndpointSummary : Summary<GetArtistsEndpoint, GetArtistsR
|
||||
|
||||
ResponseParam<ArtistResponse>(r => r.Id, "The Id of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.LibraryId, "The Id of the media library this artist belongs to.");
|
||||
ResponseParam<ArtistResponse>(r => r.Name, "The name of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.Metadata!.Name, "The name of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.Website, "The website of the artist, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.MusicBrainzArtistId, "The MusicBrainz identifier of the artist, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Contributors, "The list of references to the media contributors that make up the artist, each with the role they played.");
|
||||
@@ -52,24 +59,244 @@ public class GetArtistsEndpointSummary : Summary<GetArtistsEndpoint, GetArtistsR
|
||||
new ArtistResponse(
|
||||
Id: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Name: "Queen",
|
||||
Metadata: new MusicArtistMetadataDto(
|
||||
Name: "Queen",
|
||||
SortName: "Queen",
|
||||
Disambiguation: "British rock band",
|
||||
Type: MusicArtistType.Group,
|
||||
Gender: MusicArtistGender.NotApplicable,
|
||||
Country: "GB",
|
||||
Area: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
BeginArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
EndArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
LifeSpanBegin: new DateOnly(1970, 6, 27),
|
||||
LifeSpanEnd: new DateOnly(1991, 11, 24),
|
||||
IsEnded: false,
|
||||
Aliases: [new MusicArtistAliasDto(Name: "The Queen", SortName: "Queen", Type: "Artist name", Locale: "en", IsPrimary: false, BeginDate: new DateOnly(1970, 6, 27), EndDate: new DateOnly(1991, 11, 24), IsEnded: true)],
|
||||
Genres: [new GenreDto(Name: "Rock")],
|
||||
Tags: [new TagDto(Name: "classic")]
|
||||
),
|
||||
Website: "https://www.queenonline.com",
|
||||
MusicBrainzArtistId: Guid.NewGuid(),
|
||||
Ipis: ["00012345678"],
|
||||
Isnis: ["0000000123456789"],
|
||||
Contributors: [],
|
||||
Albums: [],
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Ratings: [new AudioRatingDto(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
Albums:
|
||||
[
|
||||
new(
|
||||
Id: Guid.NewGuid(),
|
||||
ArtistId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Metadata: new(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
Language: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
OriginalLanguage: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
Genres: [new(Name: "Rock"), new(Name: "Progressive Rock")],
|
||||
Tags: [new(Name: "classic"), new(Name: "vinyl")],
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
Contributors: [new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Producer)],
|
||||
Ratings: [new(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks:
|
||||
[
|
||||
new(
|
||||
Id: Guid.NewGuid(),
|
||||
AlbumId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
Language: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
OriginalLanguage: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
Tags: [new(Name: "classic"), new(Name: "epic")],
|
||||
Genres: [new(Name: "Rock"), new(Name: "Progressive Rock")],
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
BitDepth: 16,
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980,
|
||||
IsVideo: false
|
||||
),
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: new MusicWorkDto(MusicBrainzWorkId: Guid.NewGuid(), Title: "Bohemian Rhapsody", Type: "Song", Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")], Iswcs: ["T-010489707-6"]),
|
||||
Isrcs: [new(Value: "GBUM71029604")],
|
||||
Moods: [new(Name: "dramatic"), new(Name: "anxious")],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors: [new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Vocals)],
|
||||
Ratings: [new(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
]
|
||||
)
|
||||
]
|
||||
),
|
||||
new ArtistResponse(
|
||||
Id: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Name: "David Bowie",
|
||||
Metadata: new MusicArtistMetadataDto(
|
||||
Name: "David Bowie",
|
||||
SortName: "Queen",
|
||||
Disambiguation: "British rock band",
|
||||
Type: MusicArtistType.Group,
|
||||
Gender: MusicArtistGender.NotApplicable,
|
||||
Country: "GB",
|
||||
Area: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
BeginArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
EndArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
LifeSpanBegin: new DateOnly(1970, 6, 27),
|
||||
LifeSpanEnd: new DateOnly(1991, 11, 24),
|
||||
IsEnded: false,
|
||||
Aliases: [new MusicArtistAliasDto(Name: "The Queen", SortName: "Queen", Type: "Artist name", Locale: "en", IsPrimary: false, BeginDate: new DateOnly(1970, 6, 27), EndDate: new DateOnly(1991, 11, 24), IsEnded: true)],
|
||||
Genres: [new GenreDto(Name: "Rock")],
|
||||
Tags: [new TagDto(Name: "classic")]
|
||||
),
|
||||
Website: "https://www.davidbowie.com",
|
||||
MusicBrainzArtistId: Guid.NewGuid(),
|
||||
Ipis: ["00012345678"],
|
||||
Isnis: ["0000000123456789"],
|
||||
Contributors: [],
|
||||
Albums: [],
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Ratings: [new AudioRatingDto(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
Albums:
|
||||
[
|
||||
new(
|
||||
Id: Guid.NewGuid(),
|
||||
ArtistId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Metadata: new(
|
||||
Title: "Heroes",
|
||||
OriginalTitle: "Heroes",
|
||||
Description: "The twelfth studio album by the English musician David Bowie, released in 1977. It is the second installment of his Berlin Trilogy.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1977, 9, 23),
|
||||
OriginalReleaseYear: 1977,
|
||||
ReReleaseDate: new DateOnly(2017, 9, 22),
|
||||
ReReleaseYear: 2017,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
Language: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
OriginalLanguage: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
Genres: [new(Name: "Art Rock"), new(Name: "Krautrock")],
|
||||
Tags: [new(Name: "classic"), new(Name: "berlin trilogy")],
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 10
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0190295843215",
|
||||
CatalogNumbers: ["PL 12522"],
|
||||
Label: "RCA",
|
||||
ASIN: "B0757T3Q5N",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
Contributors: [new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Producer)],
|
||||
Ratings: [new(Value: 4.6M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 3120)],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks:
|
||||
[
|
||||
new(
|
||||
Id: Guid.NewGuid(),
|
||||
AlbumId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Path: "/music/david-bowie/heroes/01-heroes.flac",
|
||||
Metadata: new(
|
||||
Title: "Heroes",
|
||||
OriginalTitle: "Heroes",
|
||||
Description: "A song by the English musician David Bowie, from the 1977 album of the same name.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new(
|
||||
OriginalReleaseDate: new DateOnly(1977, 9, 23),
|
||||
OriginalReleaseYear: 1977,
|
||||
ReReleaseDate: new DateOnly(2017, 9, 22),
|
||||
ReReleaseYear: 2017,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
Language: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
OriginalLanguage: new(LanguageCode: "en", LanguageName: "English", NativeName: "English"),
|
||||
Tags: [new(Name: "classic"), new(Name: "art rock")],
|
||||
Genres: [new(Name: "Art Rock"), new(Name: "Krautrock")],
|
||||
DurationInSeconds: 371,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
BitDepth: 16,
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 1000,
|
||||
IsVideo: false
|
||||
),
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 110,
|
||||
Work: new MusicWorkDto(MusicBrainzWorkId: Guid.NewGuid(), Title: "Heroes", Type: "Song", Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")], Iswcs: ["T-010489707-6"]),
|
||||
Isrcs: [new(Value: "GBUM71029604")],
|
||||
Moods: [new(Name: "dramatic"), new(Name: "hopeful")],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors: [new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Vocals)],
|
||||
Ratings: [new(Value: 4.6M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 3120)],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
]
|
||||
)
|
||||
]
|
||||
)
|
||||
],
|
||||
CurrentPage = 1,
|
||||
|
||||
+166
-90
@@ -32,7 +32,7 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
Summary = "Updates an existing artist.";
|
||||
Description = "Updates the details of the artist identified by the route, together with its contributors and albums, returning the full details of the updated artist. The artist is updated by an Admin, who can update the artists of all libraries, or by the owner of the library of the artist.";
|
||||
|
||||
RequestParam(r => r.Name, "The name of the artist. Required.");
|
||||
RequestParam(r => r.Metadata!.Name, "The name of the artist. Required.");
|
||||
RequestParam(r => r.Website, "The website of the artist. Optional.");
|
||||
RequestParam(r => r.MusicBrainzArtistId, "The MusicBrainz identifier of the artist. Optional.");
|
||||
RequestParam(r => r.Contributors, "The list of media contributors that make up the artist. Required.");
|
||||
@@ -52,20 +52,20 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language, "The language of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language!.LanguageCode, "The ISO code of the language (e.g., \"en\" for English). Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language!.LanguageName, "The name of the language in English. Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Language!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage, "The original language of the album, if it has been translated. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage!.LanguageCode, "The ISO code of the language (e.g., \"en\" for English). Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage!.LanguageName, "The name of the language in English. Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Tags, "The list of tags that further describe or categorize the album. Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.Genres, "The list of genres associated with the album. Required.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.ReleaseType, "The type of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.ReleaseTypes, "The type of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.ReleaseStatus, "The status of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.TotalDiscs, "The number of discs of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].Metadata!.TotalTracks, "The number of tracks of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].MediaFormat, "The physical or digital medium of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].Barcode, "The barcode of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].CatalogNumber, "The catalog number of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].CatalogNumbers, "The catalog numbers of the album. Optional.");
|
||||
RequestParam(r => r.Albums![0].MusicBrainzReleaseId, "The MusicBrainz identifier of the release. Optional.");
|
||||
RequestParam(r => r.Albums![0].MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group. Optional.");
|
||||
RequestParam(r => r.Albums![0].MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist. Optional.");
|
||||
@@ -88,11 +88,11 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language, "The language of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language!.LanguageCode, "The ISO code of the language (e.g., \"en\" for English). Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language!.LanguageName, "The name of the language in English. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Language!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage, "The original language of the track, if it has been translated. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage!.LanguageCode, "The ISO code of the language (e.g., \"en\" for English). Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage!.LanguageName, "The name of the language in English. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the language (e.g., \"Español\" for Spanish). Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Tags, "The list of tags that further describe or categorize the track. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.Genres, "The list of genres associated with the track. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Metadata!.DurationInSeconds, "The duration of the audio of the track in seconds. Required.");
|
||||
@@ -106,19 +106,37 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Script, "The script used by the language of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Key, "The musical key of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Bpm, "The tempo of the track in beats per minute. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Work, "The title of the work the track is a recording of. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Work!.Title, "The title of the work the track is a recording of. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].MusicBrainzRecordingId, "The MusicBrainz identifier of the recording. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].MusicBrainzTrackId, "The MusicBrainz identifier of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].MusicBrainzWorkId, "The MusicBrainz identifier of the work. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Moods, "The list of moods of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Isrcs, "The list of ISRC (International Standard Recording Code) of the track. Optional.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Contributors, "The list of media contributors that performed on the track. Required.");
|
||||
RequestParam(r => r.Albums![0].Tracks![0].Ratings, "The list of ratings for this track. Required.");
|
||||
|
||||
ExampleRequest = new UpdateArtistRequest(
|
||||
Name: "Queen",
|
||||
Metadata: new MusicArtistMetadataDto(
|
||||
Name: "Queen",
|
||||
SortName: "Queen",
|
||||
Disambiguation: "British rock band",
|
||||
Type: MusicArtistType.Group,
|
||||
Gender: MusicArtistGender.NotApplicable,
|
||||
Country: "GB",
|
||||
Area: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
BeginArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
EndArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
LifeSpanBegin: new DateOnly(1970, 6, 27),
|
||||
LifeSpanEnd: new DateOnly(1991, 11, 24),
|
||||
IsEnded: false,
|
||||
Aliases: [new MusicArtistAliasDto(Name: "The Queen", SortName: "Queen", Type: "Artist name", Locale: "en", IsPrimary: false, BeginDate: new DateOnly(1970, 6, 27), EndDate: new DateOnly(1991, 11, 24), IsEnded: true)],
|
||||
Genres: [new GenreDto(Name: "Rock")],
|
||||
Tags: [new TagDto(Name: "classic")]
|
||||
),
|
||||
Website: "https://www.queenonline.com",
|
||||
MusicBrainzArtistId: Guid.NewGuid(),
|
||||
Ipis: ["00012345678"],
|
||||
Isnis: ["0000000123456789"],
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
@@ -130,18 +148,20 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
Role: MediaContributorRole.Guitar
|
||||
)
|
||||
],
|
||||
Ratings: [new AudioRatingDto(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
Albums: [
|
||||
new UpdateArtistAlbumRequest(
|
||||
AlbumId: Guid.NewGuid(),
|
||||
Metadata: new AlbumMetadataDto(
|
||||
Metadata: new MusicAlbumMetadataDto(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
@@ -163,14 +183,18 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
new GenreDto(Name: "Rock"),
|
||||
new GenreDto(Name: "Progressive Rock")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
@@ -203,15 +227,16 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
new UpdateArtistTrackRequest(
|
||||
TrackId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -233,6 +258,7 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
new GenreDto(Name: "Rock"),
|
||||
new GenreDto(Name: "Progressive Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -240,22 +266,25 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
@@ -280,20 +309,23 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1
|
||||
),
|
||||
new UpdateArtistTrackRequest(
|
||||
TrackId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/07-youre-my-best-friend.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "You're My Best Friend",
|
||||
OriginalTitle: "You're My Best Friend",
|
||||
Description: "A song by the British rock band Queen, written by bass guitarist John Deacon. It was originally released on the album A Night at the Opera in 1975 and as a single in 1976.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1976, 6, 18),
|
||||
OriginalReleaseYear: 1976,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -315,6 +347,7 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
new GenreDto(Name: "Rock"),
|
||||
new GenreDto(Name: "Pop Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 181,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -322,22 +355,25 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 912
|
||||
),
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.BMajor,
|
||||
Bpm: 118,
|
||||
Work: "You're My Best Friend",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "You're My Best Friend",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029609")
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "happy"),
|
||||
new MoodDto(Name: "warm")
|
||||
],
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029609")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
@@ -362,7 +398,9 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 567
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1
|
||||
)
|
||||
]
|
||||
)
|
||||
@@ -371,7 +409,7 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
|
||||
ResponseParam<ArtistResponse>(r => r.Id, "The Id of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.LibraryId, "The Id of the media library this artist belongs to.");
|
||||
ResponseParam<ArtistResponse>(r => r.Name, "The name of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.Metadata!.Name, "The name of the artist.");
|
||||
ResponseParam<ArtistResponse>(r => r.Website, "The website of the artist, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.MusicBrainzArtistId, "The MusicBrainz identifier of the artist, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Contributors, "The list of references to the media contributors that make up the artist, each with the role they played.");
|
||||
@@ -400,13 +438,13 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.OriginalLanguage!.NativeName, "The native name of the original language of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.Tags, "The list of tags of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.Genres, "The list of genres of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.ReleaseType, "The type of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.ReleaseTypes, "The type of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.ReleaseStatus, "The status of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.TotalDiscs, "The number of discs of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Metadata!.TotalTracks, "The number of tracks of the release of the album.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].MediaFormat, "The physical or digital medium of the album, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Barcode, "The barcode of the album, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].CatalogNumber, "The catalog number of the album, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].CatalogNumbers, "The catalog numbers of the album, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].MusicBrainzReleaseId, "The MusicBrainz identifier of the release, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].MusicBrainzReleaseGroupId, "The MusicBrainz identifier of the release group, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].MusicBrainzReleaseArtistId, "The MusicBrainz identifier of the release artist, if applicable.");
|
||||
@@ -451,10 +489,10 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Script, "The script used by the language of the track, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Key, "The musical key of the track, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Bpm, "The tempo of the track in beats per minute, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Work, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Work!.Title, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].MusicBrainzRecordingId, "The MusicBrainz identifier of the recording, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].MusicBrainzTrackId, "The MusicBrainz identifier of the track, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].CreatedOnUtc, "The date and time when the track was created.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].UpdatedOnUtc, "The date and time when the track was last updated, if applicable.");
|
||||
ResponseParam<ArtistResponse>(r => r.Albums![0].Tracks![0].Moods, "The list of moods of the track.");
|
||||
@@ -472,29 +510,49 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
example: new ArtistResponse(
|
||||
Id: artistId,
|
||||
LibraryId: libraryId,
|
||||
Name: "Queen",
|
||||
Metadata: new MusicArtistMetadataDto(
|
||||
Name: "Queen",
|
||||
SortName: "Queen",
|
||||
Disambiguation: "British rock band",
|
||||
Type: MusicArtistType.Group,
|
||||
Gender: MusicArtistGender.NotApplicable,
|
||||
Country: "GB",
|
||||
Area: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
BeginArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
EndArea: new MusicAreaDto(MusicBrainzAreaId: Guid.NewGuid(), Name: "United Kingdom", SortName: "United Kingdom", Disambiguation: "sovereign state", Type: "Country", Iso3166Code: "GB"),
|
||||
LifeSpanBegin: new DateOnly(1970, 6, 27),
|
||||
LifeSpanEnd: new DateOnly(1991, 11, 24),
|
||||
IsEnded: false,
|
||||
Aliases: [new MusicArtistAliasDto(Name: "The Queen", SortName: "Queen", Type: "Artist name", Locale: "en", IsPrimary: false, BeginDate: new DateOnly(1970, 6, 27), EndDate: new DateOnly(1991, 11, 24), IsEnded: true)],
|
||||
Genres: [new GenreDto(Name: "Rock")],
|
||||
Tags: [new TagDto(Name: "classic")]
|
||||
),
|
||||
Website: "https://www.queenonline.com",
|
||||
MusicBrainzArtistId: Guid.NewGuid(),
|
||||
Ipis: ["00012345678"],
|
||||
Isnis: ["0000000123456789"],
|
||||
Contributors:
|
||||
[
|
||||
new(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Vocals),
|
||||
new(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Guitar)
|
||||
new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Vocals),
|
||||
new MediaContributorReferenceDto(ContributorId: Guid.NewGuid(), Role: MediaContributorRole.Guitar)
|
||||
],
|
||||
Ratings: [new AudioRatingDto(Value: 4.5M, MaxValue: 5, Source: AudioRatingSource.MusicBrainz, VoteCount: 2345)],
|
||||
Albums:
|
||||
[
|
||||
new AlbumResponse(
|
||||
Id: albumId,
|
||||
ArtistId: artistId,
|
||||
LibraryId: libraryId,
|
||||
Metadata: new AlbumMetadataDto(
|
||||
Metadata: new MusicAlbumMetadataDto(
|
||||
Title: "A Night at the Opera",
|
||||
OriginalTitle: "A Night at the Opera",
|
||||
Description: "The fourth studio album by the British rock band Queen, released in 1975. It was the most expensive album ever recorded at the time of its release.",
|
||||
Disambiguation: "original release",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 11, 21),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Remastered"
|
||||
),
|
||||
@@ -518,19 +576,21 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
new TagDto(Name: "classic"),
|
||||
new TagDto(Name: "vinyl")
|
||||
],
|
||||
ReleaseType: MusicReleaseType.Album,
|
||||
Script: "Latn",
|
||||
ReleaseTypes: [MusicReleaseType.Album],
|
||||
ReleaseStatus: MusicReleaseStatus.Official,
|
||||
TotalDiscs: 1,
|
||||
TotalTracks: 12
|
||||
),
|
||||
MediaFormat: MusicMediaFormat.CD,
|
||||
Packaging: MusicReleasePackaging.JewelCase,
|
||||
Barcode: "0042282778329",
|
||||
CatalogNumber: "EMC 4008",
|
||||
CatalogNumbers: ["EMC 4008"],
|
||||
Label: "EMI",
|
||||
ASIN: "B000002UTK",
|
||||
MusicBrainzReleaseId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseGroupId: Guid.NewGuid(),
|
||||
MusicBrainzReleaseArtistId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
@@ -557,6 +617,8 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
VoteCount: 1234
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc),
|
||||
Tracks:
|
||||
[
|
||||
new TrackResponse(
|
||||
@@ -564,15 +626,16 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
AlbumId: albumId,
|
||||
LibraryId: libraryId,
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -596,6 +659,7 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
new GenreDto(Name: "Rock"),
|
||||
new GenreDto(Name: "Progressive Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -603,26 +667,27 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs:
|
||||
[
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
Isrcs:
|
||||
[
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
@@ -648,22 +713,27 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
),
|
||||
new TrackResponse(
|
||||
Id: Guid.NewGuid(),
|
||||
AlbumId: albumId,
|
||||
LibraryId: libraryId,
|
||||
Path: "/music/queen/a-night-at-the-opera/07-youre-my-best-friend.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "You're My Best Friend",
|
||||
OriginalTitle: "You're My Best Friend",
|
||||
Description: "A song by the British rock band Queen, written by bass guitarist John Deacon. It was originally released on the album A Night at the Opera in 1975 and as a single in 1976.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1976, 6, 18),
|
||||
OriginalReleaseYear: 1976,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -687,6 +757,7 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
new GenreDto(Name: "Rock"),
|
||||
new GenreDto(Name: "Pop Rock")
|
||||
],
|
||||
IsVideo: false,
|
||||
DurationInSeconds: 181,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -694,26 +765,27 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 912
|
||||
),
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.BMajor,
|
||||
Bpm: 118,
|
||||
Work: "You're My Best Friend",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "You're My Best Friend",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs:
|
||||
[
|
||||
new IsrcDto(Value: "GBUM71029609")
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new MoodDto(Name: "happy"),
|
||||
new MoodDto(Name: "warm")
|
||||
],
|
||||
Isrcs:
|
||||
[
|
||||
new IsrcDto(Value: "GBUM71029609")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
@@ -739,13 +811,17 @@ public class UpdateArtistEndpointSummary : Summary<UpdateArtistEndpoint, UpdateA
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 567
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 7,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
]
|
||||
)
|
||||
],
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
+50
-36
@@ -1,4 +1,4 @@
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
#region ========================================================================= USING =====================================================================================
|
||||
using FastEndpoints;
|
||||
using Lumina.Contracts.DTO.Common;
|
||||
using Lumina.Contracts.DTO.MediaContributors;
|
||||
@@ -32,10 +32,11 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
|
||||
ExampleRequest = new AddTrackRequest(
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -45,8 +46,8 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -69,26 +70,30 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
[
|
||||
new TagDto(Name: "classic"),
|
||||
new TagDto(Name: "epic")
|
||||
]
|
||||
],
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs:
|
||||
[
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
Isrcs:
|
||||
[
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
@@ -114,7 +119,9 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1
|
||||
);
|
||||
|
||||
RequestParam(r => r.Path, "The file system path of the track. Required.");
|
||||
@@ -150,10 +157,10 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
RequestParam(r => r.Script, "The script used by the language of the track. Optional.");
|
||||
RequestParam(r => r.Key, "The musical key of the track. Optional.");
|
||||
RequestParam(r => r.Bpm, "The tempo of the track in beats per minute. Optional.");
|
||||
RequestParam(r => r.Work, "The title of the work the track is a recording of. Optional.");
|
||||
RequestParam(r => r.Work!.Title, "The title of the work the track is a recording of. Optional.");
|
||||
RequestParam(r => r.MusicBrainzRecordingId, "The MusicBrainz identifier of the recording. Optional.");
|
||||
RequestParam(r => r.MusicBrainzTrackId, "The MusicBrainz identifier of the track. Optional.");
|
||||
RequestParam(r => r.MusicBrainzWorkId, "The MusicBrainz identifier of the work. Optional.");
|
||||
RequestParam(r => r.Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work. Optional.");
|
||||
RequestParam(r => r.Moods, "The list of moods of the track. Optional.");
|
||||
RequestParam(r => r.Isrcs, "The list of ISRC (International Standard Recording Code) of the track. Optional.");
|
||||
RequestParam(r => r.Contributors, "The list of media contributors that performed on the track. Required.");
|
||||
@@ -171,10 +178,10 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
ResponseParam<TrackResponse>(r => r.Script, "The script used by the language of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Key, "The musical key of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Bpm, "The tempo of the track in beats per minute, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work!.Title, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzRecordingId, "The MusicBrainz identifier of the recording, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzTrackId, "The MusicBrainz identifier of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.CreatedOnUtc, "The date and time when the track was created.");
|
||||
ResponseParam<TrackResponse>(r => r.UpdatedOnUtc, "The date and time when the track was last updated, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Moods, "The list of moods of the track.");
|
||||
@@ -208,15 +215,16 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
AlbumId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -243,26 +251,28 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
Channels: 2,
|
||||
BitDepth: 16,
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
Bitrate: 980,
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: default,
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -286,7 +296,11 @@ public class AddTrackEndpointSummary : Summary<AddTrackEndpoint, AddTrackRequest
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
+25
-18
@@ -41,10 +41,10 @@ public class GetTrackEndpointSummary : Summary<GetTrackEndpoint, EmptyRequest>
|
||||
ResponseParam<TrackResponse>(r => r.Script, "The script used by the language of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Key, "The musical key of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Bpm, "The tempo of the track in beats per minute, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work!.Title, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzRecordingId, "The MusicBrainz identifier of the recording, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzTrackId, "The MusicBrainz identifier of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.CreatedOnUtc, "The date and time when the track was created.");
|
||||
ResponseParam<TrackResponse>(r => r.UpdatedOnUtc, "The date and time when the track was last updated, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Moods, "The list of moods of the track.");
|
||||
@@ -78,15 +78,16 @@ public class GetTrackEndpointSummary : Summary<GetTrackEndpoint, EmptyRequest>
|
||||
AlbumId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -113,26 +114,28 @@ public class GetTrackEndpointSummary : Summary<GetTrackEndpoint, EmptyRequest>
|
||||
Channels: 2,
|
||||
BitDepth: 16,
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
Bitrate: 980,
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -156,7 +159,11 @@ public class GetTrackEndpointSummary : Summary<GetTrackEndpoint, EmptyRequest>
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
+49
-35
@@ -32,10 +32,11 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
|
||||
ExampleRequest = new UpdateTrackRequest(
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
DurationInSeconds: 354,
|
||||
SampleRate: 44100,
|
||||
Channels: 2,
|
||||
@@ -45,8 +46,8 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -69,26 +70,30 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
[
|
||||
new TagDto(Name: "classic"),
|
||||
new TagDto(Name: "epic")
|
||||
]
|
||||
],
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs:
|
||||
[
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
Moods:
|
||||
[
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
Isrcs:
|
||||
[
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors:
|
||||
[
|
||||
new MediaContributorReferenceDto(
|
||||
@@ -114,7 +119,9 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1
|
||||
);
|
||||
|
||||
RequestParam(r => r.Path, "The file system path of the track. Required.");
|
||||
@@ -150,10 +157,10 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
RequestParam(r => r.Script, "The script used by the language of the track. Optional.");
|
||||
RequestParam(r => r.Key, "The musical key of the track. Optional.");
|
||||
RequestParam(r => r.Bpm, "The tempo of the track in beats per minute. Optional.");
|
||||
RequestParam(r => r.Work, "The title of the work the track is a recording of. Optional.");
|
||||
RequestParam(r => r.Work!.Title, "The title of the work the track is a recording of. Optional.");
|
||||
RequestParam(r => r.MusicBrainzRecordingId, "The MusicBrainz identifier of the recording. Optional.");
|
||||
RequestParam(r => r.MusicBrainzTrackId, "The MusicBrainz identifier of the track. Optional.");
|
||||
RequestParam(r => r.MusicBrainzWorkId, "The MusicBrainz identifier of the work. Optional.");
|
||||
RequestParam(r => r.Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work. Optional.");
|
||||
RequestParam(r => r.Moods, "The list of moods of the track. Optional.");
|
||||
RequestParam(r => r.Isrcs, "The list of ISRC (International Standard Recording Code) of the track. Optional.");
|
||||
RequestParam(r => r.Contributors, "The list of media contributors that performed on the track. Required.");
|
||||
@@ -171,10 +178,10 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
ResponseParam<TrackResponse>(r => r.Script, "The script used by the language of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Key, "The musical key of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Bpm, "The tempo of the track in beats per minute, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work!.Title, "The title of the work the track is a recording of, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzRecordingId, "The MusicBrainz identifier of the recording, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzTrackId, "The MusicBrainz identifier of the track, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Work!.MusicBrainzWorkId, "The MusicBrainz identifier of the work, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.CreatedOnUtc, "The date and time when the track was created.");
|
||||
ResponseParam<TrackResponse>(r => r.UpdatedOnUtc, "The date and time when the track was last updated, if applicable.");
|
||||
ResponseParam<TrackResponse>(r => r.Moods, "The list of moods of the track.");
|
||||
@@ -208,15 +215,16 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
AlbumId: Guid.NewGuid(),
|
||||
LibraryId: Guid.NewGuid(),
|
||||
Path: "/music/queen/a-night-at-the-opera/01-bohemian-rhapsody.flac",
|
||||
Metadata: new AudioMetadataDto(
|
||||
Metadata: new MusicTrackMetadataDto(
|
||||
Title: "Bohemian Rhapsody",
|
||||
OriginalTitle: "Bohemian Rhapsody",
|
||||
Description: "A song by the British rock band Queen. It was written by Freddie Mercury and originally released on the album A Night at the Opera in 1975.",
|
||||
Disambiguation: "album version",
|
||||
ReleaseInfo: new ReleaseInfoDto(
|
||||
OriginalReleaseDate: new DateOnly(1975, 10, 31),
|
||||
OriginalReleaseYear: 1975,
|
||||
ReReleaseDate: default,
|
||||
ReReleaseYear: default,
|
||||
ReReleaseDate: new DateOnly(2011, 11, 21),
|
||||
ReReleaseYear: 2011,
|
||||
ReleaseCountry: ReleaseCountry.GB,
|
||||
ReleaseVersion: "Original"
|
||||
),
|
||||
@@ -243,26 +251,28 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
Channels: 2,
|
||||
BitDepth: 16,
|
||||
AudioCodec: "FLAC",
|
||||
Bitrate: 980
|
||||
Bitrate: 980,
|
||||
IsVideo: false
|
||||
),
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
Script: "Latn",
|
||||
Key: MusicKey.CMajor,
|
||||
Bpm: 72,
|
||||
Work: "Bohemian Rhapsody",
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
CreatedOnUtc: DateTime.UtcNow,
|
||||
UpdatedOnUtc: DateTime.UtcNow,
|
||||
Work: new MusicWorkDto(
|
||||
MusicBrainzWorkId: Guid.NewGuid(),
|
||||
Title: "Bohemian Rhapsody",
|
||||
Type: "Song",
|
||||
Languages: [new LanguageInfoDto(LanguageCode: "en", LanguageName: "English", NativeName: "English")],
|
||||
Iswcs: ["T-010489707-6"]
|
||||
),
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
Moods: [
|
||||
new MoodDto(Name: "dramatic"),
|
||||
new MoodDto(Name: "anxious")
|
||||
],
|
||||
Isrcs: [
|
||||
new IsrcDto(Value: "GBUM71029604")
|
||||
],
|
||||
MusicBrainzRecordingId: Guid.NewGuid(),
|
||||
MusicBrainzTrackId: Guid.NewGuid(),
|
||||
Contributors: [
|
||||
new MediaContributorReferenceDto(
|
||||
ContributorId: Guid.NewGuid(),
|
||||
@@ -286,7 +296,11 @@ public class UpdateTrackEndpointSummary : Summary<UpdateTrackEndpoint, UpdateTra
|
||||
Source: AudioRatingSource.LastFm,
|
||||
VoteCount: 1234
|
||||
)
|
||||
]
|
||||
],
|
||||
TrackNumber: 1,
|
||||
DiscNumber: 1,
|
||||
CreatedOnUtc: new DateTime(2025, 1, 15, 10, 30, 0, DateTimeKind.Utc),
|
||||
UpdatedOnUtc: new DateTime(2025, 1, 20, 14, 45, 0, DateTimeKind.Utc)
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
+1
@@ -8,6 +8,7 @@ using Lumina.Contracts.Responses.MediaLibrary.WrittenContentLibrary.BookLibrary.
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.BookLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.Common;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaContributors;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaLibrary;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
|
||||
+1
@@ -8,6 +8,7 @@ using Lumina.Contracts.Responses.MediaLibrary.WrittenContentLibrary.BookLibrary.
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.BookLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaContributors;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.Common;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaLibrary;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
|
||||
+1
@@ -9,6 +9,7 @@ using Lumina.Contracts.Responses.MediaLibrary.WrittenContentLibrary.BookLibrary.
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.BookLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaContributors;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.Common;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaLibrary;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
|
||||
+1
@@ -8,6 +8,7 @@ using Lumina.Contracts.Requests.MediaLibrary.WrittenContentLibrary.BookLibrary.B
|
||||
using Lumina.Contracts.Responses.MediaLibrary.WrittenContentLibrary.BookLibrary.Books;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.BookLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaContributors;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.MediaLibrary;
|
||||
using Lumina.Domain.SharedKernel.Common.Enums.Common;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
+1
@@ -29,6 +29,7 @@ public class GetUserSettingsEndpointSummary : Summary<GetUserSettingsEndpoint, E
|
||||
ShouldIgnoreThePrefixForAlphaPicker: false,
|
||||
IsThemeCachingEnabled: true,
|
||||
ShouldAggregateMetadataWhenMissing: false,
|
||||
ShouldAggregateArtworkWhenMissing: false,
|
||||
ShouldRenderPdfAsImages: false,
|
||||
ShouldPreserveBookStyles: true
|
||||
));
|
||||
|
||||
+3
@@ -27,6 +27,7 @@ public class UpdateUserSettingsEndpointSummary : Summary<UpdateUserSettingsEndpo
|
||||
ShouldIgnoreThePrefixForAlphaPicker: false,
|
||||
IsThemeCachingEnabled: true,
|
||||
ShouldAggregateMetadataWhenMissing: false,
|
||||
ShouldAggregateArtworkWhenMissing: false,
|
||||
ShouldRenderPdfAsImages: false,
|
||||
ShouldPreserveBookStyles: true
|
||||
);
|
||||
@@ -35,6 +36,8 @@ public class UpdateUserSettingsEndpointSummary : Summary<UpdateUserSettingsEndpo
|
||||
RequestParam(r => r.ItemsPerPage, "The number of library items displayed per page when pagination is enabled. Required.");
|
||||
RequestParam(r => r.ShouldIgnoreThePrefixForAlphaPicker, "Whether the \"The\" prefix of library item titles is ignored by the alpha picker, or not. Required.");
|
||||
RequestParam(r => r.IsThemeCachingEnabled, "Whether the theme data served to this user is cached, or not. Required.");
|
||||
RequestParam(r => r.ShouldAggregateMetadataWhenMissing, "Whether the metadata of the media library items is aggregated from multiple providers, when fields are missing, or not. Required.");
|
||||
RequestParam(r => r.ShouldAggregateArtworkWhenMissing, "Whether the artwork of the media library items is aggregated from multiple providers, when it is missing, or not. Required.");
|
||||
RequestParam(r => r.ShouldRenderPdfAsImages, "Whether PDF books are rendered as page images for the user, or not. Required.");
|
||||
RequestParam(r => r.ShouldPreserveBookStyles, "Whether the styles of the book content are preserved when it is rendered for the user, or not. Required.");
|
||||
|
||||
|
||||
@@ -109,6 +109,7 @@ public class Program
|
||||
{
|
||||
ILogger<Program> logger = services.GetRequiredService<ILogger<Program>>();
|
||||
logger.LogCritical(ex, "Failed to run database migrations");
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user