Everything works well and good structure.

This commit is contained in:
cdricms
2026-03-21 17:41:59 +01:00
parent ada1c12f57
commit 2d1e8e1044
30 changed files with 1068 additions and 875 deletions

View File

@@ -0,0 +1,7 @@
import Foundation
public struct ArtistCredit: Codable, Sendable {
public let name: String
public let artist: Artist?
public let joinphrase: String?
}

View File

@@ -0,0 +1,21 @@
import Foundation
public struct CoverArtImage: Codable, Sendable {
public let image: String
public let thumbnails: [String: String]
public let types: [String]
public let front: Bool
public let back: Bool
public let edit: Int
public let comment: String
public let id: String
}
public struct CoverArtResponse: Codable, Sendable {
public let images: [CoverArtImage]
public let release: String
public var frontImage: CoverArtImage? {
images.first { $0.front }
}
}

View File

@@ -0,0 +1,7 @@
import Foundation
public struct LifeSpan: Codable, Sendable {
public let begin: String?
public let end: String?
public let ended: Bool?
}

View File

@@ -0,0 +1,14 @@
import Foundation
public struct Relation: Codable, Sendable {
public let type: String
public let direction: String
public let url: URLResource?
public let artist: Artist?
public let release: Release?
// Add other entities as needed
enum CodingKeys: String, CodingKey {
case type, direction, url, artist, release
}
}

View File

@@ -0,0 +1,6 @@
import Foundation
public struct URLResource: Codable, Sendable {
public let id: String
public let resource: String
}