From 51aa55c04365a6c4ca53136eaab7be1a821f2294 Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Fri, 18 Oct 2024 16:57:04 +0200 Subject: [PATCH 01/11] created empty API module --- Package.swift | 14 ++++++++++++++ Sources/API/HelloWorld.swift | 11 +++++++++++ 2 files changed, 25 insertions(+) create mode 100644 Sources/API/HelloWorld.swift diff --git a/Package.swift b/Package.swift index 7ff7e240..c87e0e17 100644 --- a/Package.swift +++ b/Package.swift @@ -34,6 +34,10 @@ let package = Package( name: "Common", targets: ["Common"] ), + .library( + name: "API", + targets: ["API"] + ), ], dependencies: [ .package(url: "https://github.com/groue/GRDB.swift.git", from: "6.27.0"), @@ -66,6 +70,15 @@ let package = Package( .plugin(name: "SwiftLint", package: "SwiftLintPlugin"), ] ), + .target( + name: "API", + dependencies: [ + .AnyCodable, + ], + plugins: [ + .plugin(name: "SwiftLint", package: "SwiftLintPlugin"), + ] + ), .testTarget( name: "CatalogueTests", dependencies: [ @@ -163,6 +176,7 @@ extension Target.Dependency { static let template = byName(name: "Template") static let eventProducer = byName(name: "EventProducer") static let catalogue = byName(name: "Catalogue") + static let api = byName(name: "API") static let common = byName(name: "Common") static let auth = byName(name: "Auth") static let player = byName(name: "Player") diff --git a/Sources/API/HelloWorld.swift b/Sources/API/HelloWorld.swift new file mode 100644 index 00000000..de9e1d5f --- /dev/null +++ b/Sources/API/HelloWorld.swift @@ -0,0 +1,11 @@ +import Foundation + +public struct HelloWorld { + public let text = "Hello, World!" + + public init() {} + + func sayHello() -> String { + text + } +} From 7d0552e202ed9bbf5b69c15b735106d0cde1d5b6 Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Fri, 18 Oct 2024 18:14:32 +0200 Subject: [PATCH 02/11] added Config, Utils and Generated folders --- .../Config/custom_template/TidalAPI.mustache | 81 + .../API/Config/custom_template/api.mustache | 458 + .../input/tidal-catalog-v2-openapi-3.0.json | 13518 ++++++++++++++++ .../input/tidal-search-v2-openapi-3.0.json | 4379 +++++ .../input/tidal-user-content-openapi-3.0.json | 3581 ++++ .../input/tidal-user-v2-openapi-3.0.json | 12605 ++++++++++++++ Sources/API/Config/openapi-config.yml | 11 + Sources/API/Utils/APIError.swift | 61 + Sources/API/Utils/OpenAPIClientAPI+Auth.swift | 5 + Sources/API/Utils/RequestHelper.swift | 114 + 10 files changed, 34813 insertions(+) create mode 100644 Sources/API/Config/custom_template/TidalAPI.mustache create mode 100644 Sources/API/Config/custom_template/api.mustache create mode 100644 Sources/API/Config/input/tidal-catalog-v2-openapi-3.0.json create mode 100644 Sources/API/Config/input/tidal-search-v2-openapi-3.0.json create mode 100644 Sources/API/Config/input/tidal-user-content-openapi-3.0.json create mode 100644 Sources/API/Config/input/tidal-user-v2-openapi-3.0.json create mode 100644 Sources/API/Config/openapi-config.yml create mode 100644 Sources/API/Utils/APIError.swift create mode 100644 Sources/API/Utils/OpenAPIClientAPI+Auth.swift create mode 100644 Sources/API/Utils/RequestHelper.swift diff --git a/Sources/API/Config/custom_template/TidalAPI.mustache b/Sources/API/Config/custom_template/TidalAPI.mustache new file mode 100644 index 00000000..41accd60 --- /dev/null +++ b/Sources/API/Config/custom_template/TidalAPI.mustache @@ -0,0 +1,81 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +{{#operations}} +/// This is a wrapper around `{{classname}}` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await {{classname}}.getResource() +/// ``` +public enum {{classname}}Tidal { +{{#operation}} + +{{#allParams}} + {{#isEnum}} + + /** + * enum for parameter {{paramName}} + */ + public enum {{enumName}}_{{operationId}}: {{^isContainer}}{{{dataType}}}{{/isContainer}}{{#isContainer}}String{{/isContainer}}, CaseIterable{{#useVapor}}, Content{{/useVapor}} { + {{^enumUnknownDefaultCase}} + {{#allowableValues}} + {{#enumVars}} + case {{name}} = {{{value}}} + {{/enumVars}} + {{/allowableValues}} + {{/enumUnknownDefaultCase}} + {{#enumUnknownDefaultCase}} + {{#allowableValues}} + {{#enumVars}} + {{^-last}} + case {{name}} = {{{value}}} + {{/-last}} + {{/enumVars}} + {{/allowableValues}} + {{/enumUnknownDefaultCase}} + + func to{{classname}}Enum() -> {{classname}}.{{enumName}}_{{operationId}} { + switch self { + {{^enumUnknownDefaultCase}} + {{#allowableValues}} + {{#enumVars}} + case .{{name}}: return .{{name}} + {{/enumVars}} + {{/allowableValues}} + {{/enumUnknownDefaultCase}} + {{#enumUnknownDefaultCase}} + {{#allowableValues}} + {{#enumVars}} + {{^-last}} + case .{{name}}: return .{{name}} + {{/-last}} + {{/enumVars}} + {{/allowableValues}} + {{/enumUnknownDefaultCase}} + } + } + } + {{/isEnum}} + {{/allParams}} + + /** + {{summary}} + + {{#params}} + - parameter {{paramName}}: ({{paramLocation}}) {{description}} + {{/params}} + - returns: {{returnType}} + */ + public static func {{operationId}}({{#allParams}}{{paramName}}: {{#isEnum}}{{#isContainer}}[{{classname}}Tidal.{{enumName}}_{{operationId}}]{{/isContainer}}{{^isContainer}}{{classname}}Tidal.{{enumName}}_{{operationId}}{{/isContainer}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}) async throws{{#returnType}} -> {{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{/returnType}} { + return try await RequestHelper.createRequest { + {{classname}}.{{operationId}}WithRequestBuilder({{#allParams}}{{paramName}}: {{#isEnum}}{{paramName}}{{^required}}?{{/required}}.to{{classname}}Enum(){{/isEnum}}{{^isEnum}}{{paramName}}{{/isEnum}}{{^-last}}, {{/-last}}{{/allParams}}) + } + } +{{/operation}} +} +{{/operations}} diff --git a/Sources/API/Config/custom_template/api.mustache b/Sources/API/Config/custom_template/api.mustache new file mode 100644 index 00000000..b33d3e56 --- /dev/null +++ b/Sources/API/Config/custom_template/api.mustache @@ -0,0 +1,458 @@ +{{#operations}}// +// {{classname}}.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation{{#usePromiseKit}} +import PromiseKit{{/usePromiseKit}}{{#useRxSwift}} +import RxSwift{{/useRxSwift}}{{#useCombine}} +#if canImport(Combine) +import Combine +#endif{{/useCombine}}{{#useVapor}} +import Vapor{{/useVapor}} +#if canImport(AnyCodable) +import AnyCodable +#endif{{#swiftUseApiNamespace}} + +extension {{projectName}}API { +{{/swiftUseApiNamespace}} + +{{#description}} +/** {{{.}}} */{{/description}} +{{#objcCompatible}}@objcMembers {{/objcCompatible}}internal class {{classname}}{{#objcCompatible}} : NSObject{{/objcCompatible}} { +{{#operation}} + {{#allParams}} + {{#isEnum}} + + /** + * enum for parameter {{paramName}} + */ + {{#nonPublicApi}}internal{{/nonPublicApi}}{{^nonPublicApi}}public{{/nonPublicApi}} enum {{enumName}}_{{operationId}}: {{^isContainer}}{{{dataType}}}{{/isContainer}}{{#isContainer}}String{{/isContainer}}, CaseIterable{{#useVapor}}, Content{{/useVapor}} { + {{^enumUnknownDefaultCase}} + {{#allowableValues}} + {{#enumVars}} + case {{name}} = {{{value}}} + {{/enumVars}} + {{/allowableValues}} + {{/enumUnknownDefaultCase}} + {{#enumUnknownDefaultCase}} + {{#allowableValues}} + {{#enumVars}} + {{^-last}} + case {{name}} = {{{value}}} + {{/-last}} + {{/enumVars}} + {{/allowableValues}} + {{/enumUnknownDefaultCase}} + } + {{/isEnum}} + {{/allParams}} +{{^useVapor}} +{{^usePromiseKit}} +{{^useRxSwift}} +{{^useResult}} +{{^useCombine}} +{{^useAsyncAwait}} + + /** + {{#summary}} + {{{.}}} + {{/summary}}{{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{description}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}}{{/allParams}} + - parameter apiResponseQueue: The queue on which api response is dispatched. + - parameter completion: completion handler to receive the data and the error objects + */ + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + @discardableResult + internal class func {{operationId}}({{#allParams}}{{paramName}}: {{#isEnum}}{{#isContainer}}[{{enumName}}_{{operationId}}]{{/isContainer}}{{^isContainer}}{{enumName}}_{{operationId}}{{/isContainer}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}{{#hasParams}}, {{/hasParams}}apiResponseQueue: DispatchQueue = {{projectName}}API.apiResponseQueue, completion: @escaping ((_ data: {{{returnType}}}{{^returnType}}Void{{/returnType}}?, _ error: Error?) -> Void)) -> RequestTask { + return {{operationId}}WithRequestBuilder({{#allParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/allParams}}).execute(apiResponseQueue) { result in + switch result { + {{#returnType}} + case let .success(response): + completion(response.body, nil) + {{/returnType}} + {{^returnType}} + case .success: + completion((), nil) + {{/returnType}} + case let .failure(error): + completion(nil, error) + } + } + } +{{/useAsyncAwait}} +{{/useCombine}} +{{/useResult}} +{{/useRxSwift}} +{{/usePromiseKit}} +{{/useVapor}} +{{#usePromiseKit}} + + /** + {{#summary}} + {{{.}}} + {{/summary}}{{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{description}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}}{{/allParams}} + - returns: Promise<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}> + */ + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + internal class func {{operationId}}({{#allParams}} {{paramName}}: {{#isEnum}}{{#isContainer}}[{{enumName}}_{{operationId}}]{{/isContainer}}{{^isContainer}}{{enumName}}_{{operationId}}{{/isContainer}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}) -> Promise<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}> { + let deferred = Promise<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}>.pending() + {{operationId}}WithRequestBuilder({{#allParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/allParams}}).execute { result in + switch result { + {{#returnType}} + case let .success(response): + deferred.resolver.fulfill(response.body) + {{/returnType}} + {{^returnType}} + case .success: + deferred.resolver.fulfill(()) + {{/returnType}} + case let .failure(error): + deferred.resolver.reject(error) + } + } + return deferred.promise + } +{{/usePromiseKit}} +{{#useRxSwift}} + + /** + {{#summary}} + {{{.}}} + {{/summary}}{{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{description}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}}{{/allParams}} + - parameter apiResponseQueue: The queue on which api response is dispatched. + - returns: Observable<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}> + */ + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + internal class func {{operationId}}({{#allParams}}{{paramName}}: {{#isEnum}}{{#isContainer}}[{{enumName}}_{{operationId}}]{{/isContainer}}{{^isContainer}}{{enumName}}_{{operationId}}{{/isContainer}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}{{#hasParams}}, {{/hasParams}}apiResponseQueue: DispatchQueue = {{projectName}}API.apiResponseQueue) -> Observable<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}> { + return Observable.create { observer -> Disposable in + let requestTask = {{operationId}}WithRequestBuilder({{#allParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/allParams}}).execute(apiResponseQueue) { result in + switch result { + {{#returnType}} + case let .success(response): + observer.onNext(response.body) + {{/returnType}} + {{^returnType}} + case .success: + observer.onNext(()) + {{/returnType}} + case let .failure(error): + observer.onError(error) + } + observer.onCompleted() + } + + return Disposables.create { + requestTask.cancel() + } + } + } +{{/useRxSwift}} +{{#useCombine}} + + /** + {{#summary}} + {{{.}}} + {{/summary}}{{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{description}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}}{{/allParams}} + - returns: AnyPublisher<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}, Error> + */ + #if canImport(Combine) + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func {{operationId}}({{#allParams}}{{paramName}}: {{#isEnum}}{{#isContainer}}[{{enumName}}_{{operationId}}]{{/isContainer}}{{^isContainer}}{{enumName}}_{{operationId}}{{/isContainer}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}) -> AnyPublisher<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}, Error> { + let requestBuilder = {{operationId}}WithRequestBuilder({{#allParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/allParams}}) + let requestTask = requestBuilder.requestTask + return Future<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}, Error> { promise in + requestBuilder.execute { result in + switch result { + {{#returnType}} + case let .success(response): + promise(.success(response.body)) + {{/returnType}} + {{^returnType}} + case .success: + promise(.success(())) + {{/returnType}} + case let .failure(error): + promise(.failure(error)) + } + } + } + .handleEvents(receiveCancel: { + requestTask.cancel() + }) + .eraseToAnyPublisher() + } + #endif +{{/useCombine}} +{{#useAsyncAwait}} + + /** + {{#summary}} + {{{.}}} + {{/summary}}{{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{description}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}}{{/allParams}} + - returns: {{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}} + */ + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func {{operationId}}({{#allParams}}{{paramName}}: {{#isEnum}}{{#isContainer}}[{{enumName}}_{{operationId}}]{{/isContainer}}{{^isContainer}}{{enumName}}_{{operationId}}{{/isContainer}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}) async throws{{#returnType}} -> {{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{/returnType}} { + return try await {{operationId}}WithRequestBuilder({{#allParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/allParams}}).execute().body + } +{{/useAsyncAwait}} +{{#useResult}} + + /** + {{#summary}} + {{{.}}} + {{/summary}}{{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{description}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}}{{/allParams}} + - parameter apiResponseQueue: The queue on which api response is dispatched. + - parameter completion: completion handler to receive the result + */ + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + @discardableResult + internal class func {{operationId}}({{#allParams}}{{paramName}}: {{#isEnum}}{{#isContainer}}[{{enumName}}_{{operationId}}]{{/isContainer}}{{^isContainer}}{{enumName}}_{{operationId}}{{/isContainer}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}{{#hasParams}}, {{/hasParams}}apiResponseQueue: DispatchQueue = {{projectName}}API.apiResponseQueue, completion: @escaping ((_ result: Swift.Result<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}, ErrorResponse>) -> Void)) -> RequestTask { + return {{operationId}}WithRequestBuilder({{#allParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/allParams}}).execute(apiResponseQueue) { result in + switch result { + {{#returnType}} + case let .success(response): + completion(.success(response.body)) + {{/returnType}} + {{^returnType}} + case .success: + completion(.success(())) + {{/returnType}} + case let .failure(error): + completion(.failure(error)) + } + } + } +{{/useResult}} +{{#useVapor}} + + /** + {{#summary}} + {{{.}}} + {{/summary}} + {{httpMethod}} {{{path}}}{{#notes}} + {{{.}}}{{/notes}}{{#subresourceOperation}} + subresourceOperation: {{.}}{{/subresourceOperation}}{{#defaultResponse}} + defaultResponse: {{.}}{{/defaultResponse}} + {{#authMethods}} + - {{#isBasicBasic}}BASIC{{/isBasicBasic}}{{#isBasicBearer}}Bearer Token{{/isBasicBearer}}{{#isOAuth}}OAuth{{/isOAuth}}{{#isApiKey}}API Key{{/isApiKey}}: + - type: {{type}}{{#keyParamName}} {{keyParamName}} {{#isKeyInQuery}}(QUERY){{/isKeyInQuery}}{{#isKeyInHeader}}(HEADER){{/isKeyInHeader}}{{/keyParamName}} + - name: {{name}} + {{/authMethods}} + {{#hasResponseHeaders}} + - responseHeaders: [{{#responseHeaders}}{{{baseName}}}({{{dataType}}}){{^-last}}, {{/-last}}{{/responseHeaders}}] + {{/hasResponseHeaders}} + {{#externalDocs}} + - externalDocs: {{.}} + {{/externalDocs}} + {{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{{description}}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}} + {{/allParams}} + - returns: `EventLoopFuture` of `ClientResponse` {{{description}}} + */ + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + internal class func {{operationId}}Raw({{#allParams}}{{paramName}}: {{#isEnum}}{{#isArray}}[{{enumName}}_{{operationId}}]{{/isArray}}{{^isArray}}{{#isContainer}}{{{dataType}}}{{/isContainer}}{{^isContainer}}{{{datatypeWithEnum}}}_{{operationId}}{{/isContainer}}{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}{{#hasParams}}, {{/hasParams}}headers: HTTPHeaders = {{projectName}}API.customHeaders, beforeSend: (inout ClientRequest) throws -> () = { _ in }) -> EventLoopFuture { + {{^pathParams}}let{{/pathParams}}{{#pathParams}}{{#-first}}var{{/-first}}{{/pathParams}} localVariablePath = "{{{path}}}"{{#pathParams}} + let {{paramName}}PreEscape = String(describing: {{#isEnum}}{{paramName}}{{#isContainer}}{{{dataType}}}{{/isContainer}}{{^isContainer}}.rawValue{{/isContainer}}{{/isEnum}}{{^isEnum}}{{paramName}}{{/isEnum}}) + let {{paramName}}PostEscape = {{paramName}}PreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{{=<% %>=}}{<%baseName%>}<%={{ }}=%>", with: {{paramName}}PostEscape, options: .literal, range: nil){{/pathParams}} + let localVariableURLString = {{projectName}}API.basePath + localVariablePath + + guard let localVariableApiClient = {{#swiftUseApiNamespace}}{{projectName}}API.{{/swiftUseApiNamespace}}Configuration.apiClient else { + fatalError("Configuration.apiClient is not set.") + } + + return localVariableApiClient.send(.{{httpMethod}}, headers: headers, to: URI(string: localVariableURLString)) { localVariableRequest in + try {{#swiftUseApiNamespace}}{{projectName}}API.{{/swiftUseApiNamespace}}Configuration.apiWrapper(&localVariableRequest) + {{#hasHeaderParams}}{{#headerParams}} + localVariableRequest.headers.add(name: "{{baseName}}", value: {{#isArray}}{{paramName}}{{^required}}?{{/required}}.map { $0{{#isEnum}}.rawValue{{/isEnum}}.description }.description{{/isArray}}{{^isArray}}{{#isEnum}}{{paramName}}{{^required}}?{{/required}}.rawValue.description{{/isEnum}}{{^isEnum}}{{paramName}}{{^required}}?{{/required}}.description{{/isEnum}}{{/isArray}}{{^required}} ?? ""{{/required}}) + {{/headerParams}}{{/hasHeaderParams}} + {{#hasQueryParams}}struct QueryParams: Content { + {{#queryParams}} + var {{paramName}}: {{#isEnum}}{{#isArray}}[{{enumName}}_{{operationId}}]{{/isArray}}{{^isArray}}{{#isContainer}}{{{dataType}}}{{/isContainer}}{{^isContainer}}{{{datatypeWithEnum}}}_{{operationId}}{{/isContainer}}{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}?{{/required}} + {{/queryParams}} + + enum CodingKeys: String, CodingKey { + {{#queryParams}} + case {{paramName}}{{#baseName}} = "{{.}}"{{/baseName}} + {{/queryParams}} + } + } + try localVariableRequest.query.encode(QueryParams({{#queryParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/queryParams}})){{/hasQueryParams}} + {{#hasBodyParam}} + {{#bodyParam}}{{#required}}{{#isBinary}}localVariableRequest.body = ByteBuffer(data: {{paramName}}){{/isBinary}}{{^isBinary}}{{#isFile}}localVariableRequest.body = ByteBuffer(data: {{paramName}}){{/isFile}}try localVariableRequest.content.encode({{paramName}}, using: Configuration.contentConfiguration.requireEncoder(for: {{{dataType}}}.defaultContentType)){{/isBinary}}{{/required}}{{^required}}if let localVariableBody = {{paramName}} { + {{#isBinary}}localVariableRequest.body = ByteBuffer(data: localVariableBody){{/isBinary}}{{^isBinary}}{{#isFile}}localVariableRequest.body = ByteBuffer(data: localVariableBody){{/isFile}}try localVariableRequest.content.encode(localVariableBody, using: Configuration.contentConfiguration.requireEncoder(for: {{{dataType}}}.defaultContentType)){{/isBinary}} + }{{/required}}{{/bodyParam}} + {{/hasBodyParam}} + {{#hasFormParams}}struct FormParams: Content { + static let defaultContentType = Vapor.HTTPMediaType.formData + {{#formParams}} + var {{paramName}}: {{#isEnum}}{{#isArray}}[{{enumName}}_{{operationId}}]{{/isArray}}{{^isArray}}{{#isContainer}}{{{dataType}}}{{/isContainer}}{{^isContainer}}{{{datatypeWithEnum}}}_{{operationId}}{{/isContainer}}{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}?{{/required}} + {{/formParams}} + } + try localVariableRequest.content.encode(FormParams({{#formParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/formParams}}), using: Configuration.contentConfiguration.requireEncoder(for: FormParams.defaultContentType)){{/hasFormParams}} + try beforeSend(&localVariableRequest) + } + } + + {{#nonPublicApi}}internal{{/nonPublicApi}}{{^nonPublicApi}}public{{/nonPublicApi}} enum {{#lambda.titlecase}}{{operationId}}{{/lambda.titlecase}} { + {{#responses}} + case http{{code}}({{#dataType}}value: {{{.}}}, {{/dataType}}raw: ClientResponse) + {{/responses}} + {{^hasDefaultResponse}} + case http0(raw: ClientResponse) + {{/hasDefaultResponse}} + } + + /** + {{#summary}} + {{{.}}} + {{/summary}} + {{httpMethod}} {{{path}}}{{#notes}} + {{{.}}}{{/notes}}{{#subresourceOperation}} + subresourceOperation: {{.}}{{/subresourceOperation}}{{#defaultResponse}} + defaultResponse: {{.}}{{/defaultResponse}} + {{#authMethods}} + - {{#isBasicBasic}}BASIC{{/isBasicBasic}}{{#isBasicBearer}}Bearer Token{{/isBasicBearer}}{{#isOAuth}}OAuth{{/isOAuth}}{{#isApiKey}}API Key{{/isApiKey}}: + - type: {{type}}{{#keyParamName}} {{keyParamName}} {{#isKeyInQuery}}(QUERY){{/isKeyInQuery}}{{#isKeyInHeader}}(HEADER){{/isKeyInHeader}}{{/keyParamName}} + - name: {{name}} + {{/authMethods}} + {{#hasResponseHeaders}} + - responseHeaders: [{{#responseHeaders}}{{{baseName}}}({{{dataType}}}){{^-last}}, {{/-last}}{{/responseHeaders}}] + {{/hasResponseHeaders}} + {{#externalDocs}} + - externalDocs: {{.}} + {{/externalDocs}} + {{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{{description}}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}} + {{/allParams}} + - returns: `EventLoopFuture` of `{{#lambda.titlecase}}{{operationId}}{{/lambda.titlecase}}` {{{description}}} + */ + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + internal class func {{operationId}}({{#allParams}}{{paramName}}: {{#isEnum}}{{#isArray}}[{{enumName}}_{{operationId}}]{{/isArray}}{{^isArray}}{{#isContainer}}{{{dataType}}}{{/isContainer}}{{^isContainer}}{{{datatypeWithEnum}}}_{{operationId}}{{/isContainer}}{{/isArray}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}{{#hasParams}}, {{/hasParams}}headers: HTTPHeaders = {{projectName}}API.customHeaders, beforeSend: (inout ClientRequest) throws -> () = { _ in }) -> EventLoopFuture<{{#lambda.titlecase}}{{operationId}}{{/lambda.titlecase}}> { + return {{operationId}}Raw({{#allParams}}{{paramName}}: {{paramName}}{{^-last}}, {{/-last}}{{/allParams}}{{#hasParams}}, {{/hasParams}}headers: headers, beforeSend: beforeSend).flatMapThrowing { response -> {{#lambda.titlecase}}{{operationId}}{{/lambda.titlecase}} in + switch response.status.code { + {{#responses}} + {{#isDefault}}default{{/isDefault}}{{^isDefault}}case {{code}}{{/isDefault}}: + return .http{{code}}({{#dataType}}value: {{#isBinary}}Data(buffer: response.body ?? ByteBuffer()){{/isBinary}}{{^isBinary}}{{#isFile}}Data(buffer: response.body ?? ByteBuffer()){{/isFile}}{{^isFile}}try response.content.decode({{{dataType}}}.self, using: Configuration.contentConfiguration.requireDecoder(for: {{{dataType}}}.defaultContentType)){{/isFile}}{{/isBinary}}, {{/dataType}}raw: response) + {{/responses}} + {{^hasDefaultResponse}} + default: + return .http0(raw: response) + {{/hasDefaultResponse}} + } + } + } +{{/useVapor}} +{{^useVapor}} + + /** + {{#summary}} + {{{.}}} + {{/summary}} + - {{httpMethod}} {{{path}}}{{#notes}} + - {{{.}}}{{/notes}}{{#subresourceOperation}} + - subresourceOperation: {{.}}{{/subresourceOperation}}{{#defaultResponse}} + - defaultResponse: {{.}}{{/defaultResponse}} + {{#authMethods}} + - {{#isBasicBasic}}BASIC{{/isBasicBasic}}{{#isBasicBearer}}Bearer Token{{/isBasicBearer}}{{#isOAuth}}OAuth{{/isOAuth}}{{#isApiKey}}API Key{{/isApiKey}}: + - type: {{type}}{{#keyParamName}} {{keyParamName}} {{#isKeyInQuery}}(QUERY){{/isKeyInQuery}}{{#isKeyInHeader}}(HEADER){{/isKeyInHeader}}{{/keyParamName}} + - name: {{name}} + {{/authMethods}} + {{#hasResponseHeaders}} + - responseHeaders: [{{#responseHeaders}}{{{baseName}}}({{{dataType}}}){{^-last}}, {{/-last}}{{/responseHeaders}}] + {{/hasResponseHeaders}} + {{#externalDocs}} + - externalDocs: {{.}} + {{/externalDocs}} + {{#allParams}} + - parameter {{paramName}}: ({{#isFormParam}}form{{/isFormParam}}{{#isQueryParam}}query{{/isQueryParam}}{{#isPathParam}}path{{/isPathParam}}{{#isHeaderParam}}header{{/isHeaderParam}}{{#isBodyParam}}body{{/isBodyParam}}) {{description}} {{^required}}(optional{{#defaultValue}}, default to {{{.}}}{{/defaultValue}}){{/required}} + {{/allParams}} + - returns: RequestBuilder<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}> {{description}} + */ + {{#isDeprecated}} + @available(*, deprecated, message: "This operation is deprecated.") + {{/isDeprecated}} + internal class func {{operationId}}WithRequestBuilder({{#allParams}}{{paramName}}: {{#isEnum}}{{#isContainer}}[{{enumName}}_{{operationId}}]{{/isContainer}}{{^isContainer}}{{enumName}}_{{operationId}}{{/isContainer}}{{/isEnum}}{{^isEnum}}{{{dataType}}}{{/isEnum}}{{^required}}? = nil{{/required}}{{^-last}}, {{/-last}}{{/allParams}}) -> RequestBuilder<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}> { + {{^pathParams}}let{{/pathParams}}{{#pathParams}}{{#-first}}var{{/-first}}{{/pathParams}} localVariablePath = "{{{path}}}"{{#pathParams}} + let {{paramName}}PreEscape = "\({{#isEnum}}{{paramName}}{{#isContainer}}{{{dataType}}}{{/isContainer}}{{^isContainer}}.rawValue{{/isContainer}}{{/isEnum}}{{^isEnum}}APIHelper.mapValueToPathItem({{paramName}}){{/isEnum}})" + let {{paramName}}PostEscape = {{paramName}}PreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{{=<% %>=}}{<%baseName%>}<%={{ }}=%>", with: {{paramName}}PostEscape, options: .literal, range: nil){{/pathParams}} + let localVariableURLString = {{projectName}}API.basePath + localVariablePath + {{#bodyParam}} + {{#isBinary}} + let localVariableParameters = ["body": {{paramName}}] + {{/isBinary}} + {{^isBinary}} + let localVariableParameters = JSONEncodingHelper.encodingParameters(forEncodableObject: {{paramName}}) + {{/isBinary}} + {{/bodyParam}} + {{^bodyParam}} + {{#hasFormParams}} + let localVariableFormParams: [String: Any?] = [ + {{#formParams}} + {{> _param}}, + {{/formParams}} + ] + + let localVariableNonNullParameters = APIHelper.rejectNil(localVariableFormParams) + let localVariableParameters = APIHelper.convertBoolToString(localVariableNonNullParameters) + {{/hasFormParams}} + {{^hasFormParams}} + let localVariableParameters: [String: Any]? = nil + {{/hasFormParams}} +{{/bodyParam}}{{#hasQueryParams}} + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([{{^queryParams}}:{{/queryParams}} + {{#queryParams}} + {{> _param}}, + {{/queryParams}} + ]){{/hasQueryParams}}{{^hasQueryParams}} + let localVariableUrlComponents = URLComponents(string: localVariableURLString){{/hasQueryParams}} + + let localVariableNillableHeaders: [String: Any?] = [{{^headerParams}}{{^hasFormParams}}{{^hasConsumes}} + :{{/hasConsumes}}{{/hasFormParams}}{{/headerParams}}{{#hasFormParams}} + "Content-Type": {{^consumes}}"multipart/form-data"{{/consumes}}{{#consumes.0}}"{{{mediaType}}}"{{/consumes.0}},{{/hasFormParams}}{{^hasFormParams}}{{#hasConsumes}} + "Content-Type": {{#consumes.0}}"{{{mediaType}}}"{{/consumes.0}},{{/hasConsumes}}{{/hasFormParams}}{{#headerParams}} + {{> _param}},{{/headerParams}} + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder<{{{returnType}}}{{#returnType}}{{#isResponseOptional}}?{{/isResponseOptional}}{{/returnType}}{{^returnType}}Void{{/returnType}}>.Type = {{projectName}}API.requestBuilderFactory.{{#returnType}}getBuilder(){{/returnType}}{{^returnType}}getNonDecodableBuilder(){{/returnType}} + + return localVariableRequestBuilder.init(method: "{{httpMethod}}", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: {{#hasAuthMethods}}true{{/hasAuthMethods}}{{^hasAuthMethods}}false{{/hasAuthMethods}}) + } +{{/useVapor}} +{{/operation}} +} +{{#swiftUseApiNamespace}} +} +{{/swiftUseApiNamespace}} +{{/operations}} diff --git a/Sources/API/Config/input/tidal-catalog-v2-openapi-3.0.json b/Sources/API/Config/input/tidal-catalog-v2-openapi-3.0.json new file mode 100644 index 00000000..5ee0fd7d --- /dev/null +++ b/Sources/API/Config/input/tidal-catalog-v2-openapi-3.0.json @@ -0,0 +1,13518 @@ +{ + "openapi" : "3.0.1", + "info" : { + "title" : "Catalogue v2 - beta", + "description" : "The Catalogue API v2 provides a set of JSON:API compatible endpoints for accessing the TIDAL metadata catalogue: albums, artists, tracks, videos, and more", + "contact" : { + "url" : "https://github.com/orgs/tidal-music/discussions" + }, + "version" : "1.0.0", + "x-url-compatible-spec-id" : "catalogue-v2", + "x-spec-default-endpoint-url-unique-name" : "get-albums-v2" + }, + "externalDocs" : { + "description" : "TIDAL Developer Documentation", + "url" : "https://developer.tidal.com/documentation" + }, + "servers" : [ { + "url" : "https://openapi.tidal.com/v2", + "description" : "Production" + } ], + "tags" : [ { + "name" : "Albums", + "description" : "Albums JSON:API endpoints" + }, { + "name" : "Artists", + "description" : "Artists JSON:API endpoints" + }, { + "name" : "Tracks", + "description" : "Tracks JSON:API endpoints" + }, { + "name" : "Videos", + "description" : "Videos JSON:API endpoints" + }, { + "name" : "Providers", + "description" : "Providers JSON:API endpoints" + } ], + "paths" : { + "/videos" : { + "get" : { + "tags" : [ "Videos" ], + "summary" : "Get multiple videos", + "description" : "Retrieve multiple video details.", + "operationId" : "getVideosByFilters", + "parameters" : [ { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists, albums, providers", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on id attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "75623239" + } + }, + "example" : "75623239" + }, { + "name" : "filter[isrc]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on isrc attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "USSM21600755" + } + }, + "example" : "USSM21600755" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Videos_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id", "isrc" ], + "url-compatible-unique-name" : "get-videos-v2", + "json-api-available-relationships" : [ "artists", "albums", "providers" ] + } + } + }, + "/videos/{id}" : { + "get" : { + "tags" : [ "Videos" ], + "summary" : "Get single video", + "description" : "Retrieve video details by TIDAL video id.", + "operationId" : "getVideoById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL video id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 75623239 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists, albums, providers", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Videos_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-video-v2", + "json-api-available-relationships" : [ "artists", "albums", "providers" ] + } + } + }, + "/videos/{id}/relationships/providers" : { + "get" : { + "tags" : [ "Videos" ], + "summary" : "Relationship: providers", + "description" : "This endpoint can be used to retrieve a list of video's related providers.", + "operationId" : "getVideoProvidersRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the video", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 75623239 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: providers", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "providers" + } + }, + "example" : "providers" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Providers_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-video-providers-v2", + "json-api-available-relationships" : [ "providers" ] + } + } + }, + "/videos/{id}/relationships/artists" : { + "get" : { + "tags" : [ "Videos" ], + "summary" : "Relationship: artists", + "description" : "Retrieve artist details of the related video.", + "operationId" : "getVideoArtistsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL video id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 75623239 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-video-artists-v2", + "json-api-available-relationships" : [ "artists" ] + } + } + }, + "/videos/{id}/relationships/albums" : { + "get" : { + "tags" : [ "Videos" ], + "summary" : "Relationship: albums", + "description" : "Retrieve album details of the related video.", + "operationId" : "getVideoAlbumsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL video id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 75623239 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: albums", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "albums" + } + }, + "example" : "albums" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Albums_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-video-albums-v2", + "json-api-available-relationships" : [ "albums" ] + } + } + }, + "/tracks" : { + "get" : { + "tags" : [ "Tracks" ], + "summary" : "Get multiple tracks", + "description" : "Retrieve multiple track details.", + "operationId" : "getTracksByFilters", + "parameters" : [ { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on id attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "251380837" + } + }, + "example" : "251380837" + }, { + "name" : "filter[isrc]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on isrc attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "USSM12209515" + } + }, + "example" : "USSM12209515" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Tracks_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id", "isrc" ], + "url-compatible-unique-name" : "get-tracks-v2", + "json-api-available-relationships" : [ "artists", "albums", "providers", "similarTracks", "radio" ] + } + } + }, + "/tracks/{id}" : { + "get" : { + "tags" : [ "Tracks" ], + "summary" : "Get single track", + "description" : "Retrieve track details by TIDAL track id.", + "operationId" : "getTrackById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL track id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380837 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Tracks_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-track-v2", + "json-api-available-relationships" : [ "artists", "albums", "providers", "similarTracks", "radio" ] + } + } + }, + "/tracks/{id}/relationships/similarTracks" : { + "get" : { + "tags" : [ "Tracks" ], + "summary" : "Relationship: similar tracks", + "description" : "This endpoint can be used to retrieve a list of tracks similar to the given track.", + "operationId" : "getTrackSimilarTracksRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the track", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380837 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: similarTracks", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "similarTracks" + } + }, + "example" : "similarTracks" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Tracks_Relationships_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-similar-tracks-v2", + "json-api-available-relationships" : [ "similarTracks" ] + } + } + }, + "/tracks/{id}/relationships/radio" : { + "get" : { + "tags" : [ "Tracks" ], + "summary" : "Relationship: radio", + "description" : "This endpoint can be used to retrieve a list of radios for the given track.", + "operationId" : "getTrackRadioRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the track", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380837 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: radio", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "radio" + } + }, + "example" : "radio" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Tracks_Relationships_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-track-radio-v2", + "json-api-available-relationships" : [ "radio" ] + } + } + }, + "/tracks/{id}/relationships/providers" : { + "get" : { + "tags" : [ "Tracks" ], + "summary" : "Relationship: providers", + "description" : "This endpoint can be used to retrieve a list of track's related providers.", + "operationId" : "getTrackProvidersRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the track", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380837 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: providers", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "providers" + } + }, + "example" : "providers" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Providers_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-track-providers-v2", + "json-api-available-relationships" : [ "providers" ] + } + } + }, + "/tracks/{id}/relationships/artists" : { + "get" : { + "tags" : [ "Tracks" ], + "summary" : "Relationship: artists", + "description" : "Retrieve artist details of the related track.", + "operationId" : "getTrackArtistsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL track id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380837 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-track-artists-v2", + "json-api-available-relationships" : [ "artists" ] + } + } + }, + "/tracks/{id}/relationships/albums" : { + "get" : { + "tags" : [ "Tracks" ], + "summary" : "Relationship: albums", + "description" : "Retrieve album details of the related track.", + "operationId" : "getTrackAlbumsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL track id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380837 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: albums", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "albums" + } + }, + "example" : "albums" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Albums_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-track-albums-v2", + "json-api-available-relationships" : [ "albums" ] + } + } + }, + "/providers" : { + "get" : { + "tags" : [ "Providers" ], + "summary" : "Get multiple providers", + "description" : "Retrieve multiple provider details.", + "operationId" : "getProvidersByFilters", + "parameters" : [ { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : null + } + } + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "provider id", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "771" + } + }, + "example" : "771" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Providers_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id" ], + "url-compatible-unique-name" : "get-providers-v2", + "json-api-available-relationships" : [ ] + } + } + }, + "/providers/{id}" : { + "get" : { + "tags" : [ "Providers" ], + "summary" : "Get single provider", + "description" : "Retrieve provider details by TIDAL provider id.", + "operationId" : "getProviderById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL provider id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 771 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : null + } + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Providers_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-provider-v2", + "json-api-available-relationships" : [ ] + } + } + }, + "/artists" : { + "get" : { + "tags" : [ "Artists" ], + "summary" : "Get multiple artists", + "description" : "Retrieve multiple artist details.", + "operationId" : "getArtistsByFilters", + "parameters" : [ { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "albums" + } + }, + "example" : "albums" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on id attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "1566" + } + }, + "example" : "1566" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id" ], + "url-compatible-unique-name" : "get-artists-v2", + "json-api-available-relationships" : [ "albums", "tracks", "videos", "similarArtists", "trackProviders", "radio" ] + } + } + }, + "/artists/{id}" : { + "get" : { + "tags" : [ "Artists" ], + "summary" : "Get single artist", + "description" : "Retrieve artist details by TIDAL artist id.", + "operationId" : "getArtistById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL artist id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1566 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "albums" + } + }, + "example" : "albums" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-artist-v2", + "json-api-available-relationships" : [ "albums", "tracks", "videos", "similarArtists", "trackProviders", "radio" ] + } + } + }, + "/artists/{id}/relationships/videos" : { + "get" : { + "tags" : [ "Artists" ], + "summary" : "Relationship: videos", + "description" : "Retrieve video details by related artist.", + "operationId" : "getArtistVideosRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL artist id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1566 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: videos", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "videos" + } + }, + "example" : "videos" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Videos_Relationships_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-artist-videos-v2", + "json-api-available-relationships" : [ "videos" ] + } + } + }, + "/artists/{id}/relationships/tracks" : { + "get" : { + "tags" : [ "Artists" ], + "summary" : "Relationship: tracks", + "description" : "Retrieve track details by related artist.", + "operationId" : "getArtistTracksRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL artist id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1566 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "collapseBy", + "in" : "query", + "description" : "Collapse by options for getting artist tracks. Available options: FINGERPRINT, ID. FINGERPRINT option might collapse similar tracks based item fingerprints while collapsing by ID always returns all available items.", + "required" : false, + "schema" : { + "type" : "string", + "default" : "FINGERPRINT", + "enum" : [ "FINGERPRINT", "NONE" ] + }, + "example" : "FINGERPRINT" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: tracks", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "tracks" + } + }, + "example" : "tracks" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Tracks_Relationships_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-artist-tracks-v2", + "json-api-available-relationships" : [ "tracks" ] + } + } + }, + "/artists/{id}/relationships/trackProviders" : { + "get" : { + "tags" : [ "Artists" ], + "summary" : "Relationship: track providers", + "description" : "Retrieve providers that have released tracks for this artist", + "operationId" : "getArtistTrackProvidersRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the artist", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1566 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: trackProviders", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "trackProviders" + } + }, + "example" : "trackProviders" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-artist-track-providers-v2", + "json-api-available-relationships" : [ "trackProviders" ] + } + } + }, + "/artists/{id}/relationships/similarArtists" : { + "get" : { + "tags" : [ "Artists" ], + "summary" : "Relationship: similar artists", + "description" : "This endpoint can be used to retrieve a list of artists similar to the given artist.", + "operationId" : "getArtistSimilarArtistsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the artist", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1566 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: similarArtists", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "similarArtists" + } + }, + "example" : "similarArtists" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-similar-artists-v2", + "json-api-available-relationships" : [ "similarArtists" ] + } + } + }, + "/artists/{id}/relationships/radio" : { + "get" : { + "tags" : [ "Artists" ], + "summary" : "Relationship: radio", + "description" : "This endpoint can be used to retrieve a list of radios for the given artist.", + "operationId" : "getArtistRadioRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the artist", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1566 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: radio", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "radio" + } + }, + "example" : "radio" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-artist-radio-v2", + "json-api-available-relationships" : [ "radio" ] + } + } + }, + "/artists/{id}/relationships/albums" : { + "get" : { + "tags" : [ "Artists" ], + "summary" : "Relationship: albums", + "description" : "Retrieve album details of the related artist.", + "operationId" : "getArtistAlbumsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL artist id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1566 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: albums", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "albums" + } + }, + "example" : "albums" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Albums_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-artist-albums-v2", + "json-api-available-relationships" : [ "albums" ] + } + } + }, + "/albums" : { + "get" : { + "tags" : [ "Albums" ], + "summary" : "Get multiple albums", + "description" : "Retrieve multiple album details.", + "operationId" : "getAlbumsByFilters", + "parameters" : [ { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on id attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "251380836" + } + }, + "example" : "251380836" + }, { + "name" : "filter[barcodeId]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on barcodeId attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "196589525444" + } + }, + "example" : "196589525444" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Albums_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id", "barcodeId" ], + "url-compatible-unique-name" : "get-albums-v2", + "json-api-available-relationships" : [ "artists", "items", "providers", "similarAlbums" ] + } + } + }, + "/albums/{id}" : { + "get" : { + "tags" : [ "Albums" ], + "summary" : "Get single album", + "description" : "Retrieve album details by TIDAL album id.", + "operationId" : "getAlbumById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL album id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Albums_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-album-v2", + "json-api-available-relationships" : [ "artists", "items", "providers", "similarAlbums" ] + } + } + }, + "/albums/{id}/relationships/similarAlbums" : { + "get" : { + "tags" : [ "Albums" ], + "summary" : "Relationship: similar albums", + "description" : "This endpoint can be used to retrieve a list of albums similar to the given album.", + "operationId" : "getAlbumSimilarAlbumsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the album", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: similarAlbums", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "similarAlbums" + } + }, + "example" : "similarAlbums" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Albums_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-similar-albums-v2", + "json-api-available-relationships" : [ "similarAlbums" ] + } + } + }, + "/albums/{id}/relationships/providers" : { + "get" : { + "tags" : [ "Albums" ], + "summary" : "Relationship: providers", + "description" : "This endpoint can be used to retrieve a list of album's related providers.", + "operationId" : "getAlbumProvidersRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL id of the album", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: providers", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "providers" + } + }, + "example" : "providers" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Providers_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-album-providers-v2", + "json-api-available-relationships" : [ "providers" ] + } + } + }, + "/albums/{id}/relationships/items" : { + "get" : { + "tags" : [ "Albums" ], + "summary" : "Relationship: items", + "description" : "Retrieve album item details.", + "operationId" : "getAlbumItemsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL album id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: items", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "items" + } + }, + "example" : "items" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Albums_Items_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-album-items-v2", + "json-api-available-relationships" : [ "items" ] + } + } + }, + "/albums/{id}/relationships/artists" : { + "get" : { + "tags" : [ "Albums" ], + "summary" : "Relationship: artists", + "description" : "Retrieve artist details of the related album.", + "operationId" : "getAlbumArtistsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL album id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-album-artists-v2", + "json-api-available-relationships" : [ "artists" ] + } + } + } + }, + "components" : { + "schemas" : { + "Error_Document" : { + "type" : "object", + "properties" : { + "errors" : { + "type" : "array", + "description" : "array of error objects", + "items" : { + "$ref" : "#/components/schemas/Error_Object" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "Error_Object" : { + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "unique identifier for this particular occurrence of the problem" + }, + "status" : { + "type" : "string", + "description" : "HTTP status code applicable to this problem" + }, + "code" : { + "type" : "string", + "description" : "application-specific error code" + }, + "detail" : { + "type" : "string", + "description" : "human-readable explanation specific to this occurrence of the problem" + }, + "source" : { + "$ref" : "#/components/schemas/Error_Object_Source" + } + } + }, + "Error_Object_Source" : { + "type" : "object", + "properties" : { + "pointer" : { + "type" : "string", + "description" : "a JSON Pointer [RFC6901] to the value in the request document that caused the error", + "example" : "/data/attributes/title" + }, + "parameter" : { + "type" : "string", + "description" : "string indicating which URI query parameter caused the error.", + "example" : "countryCode" + }, + "header" : { + "type" : "string", + "description" : "string indicating the name of a single request header which caused the error", + "example" : "X-some-custom-header" + } + }, + "description" : "object containing references to the primary source of the error" + }, + "Links" : { + "required" : [ "self" ], + "type" : "object", + "properties" : { + "self" : { + "type" : "string", + "description" : "the link that generated the current response document", + "example" : "/artists/xyz/relationships/tracks" + }, + "next" : { + "type" : "string", + "description" : "the next page of data (pagination)", + "example" : "/artists/xyz/relationships/tracks?page[cursor]=zyx" + } + }, + "description" : "links object" + }, + "Albums_Attributes" : { + "required" : [ "barcodeId", "duration", "explicit", "mediaTags", "numberOfItems", "numberOfVolumes", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Original title", + "example" : "4:44" + }, + "barcodeId" : { + "type" : "string", + "description" : "Barcode id (EAN-13 or UPC-A)", + "example" : "00854242007552" + }, + "numberOfVolumes" : { + "type" : "integer", + "description" : "Number of volumes", + "format" : "int32", + "example" : 1 + }, + "numberOfItems" : { + "type" : "integer", + "description" : "Number of album items", + "format" : "int32", + "example" : 13 + }, + "duration" : { + "type" : "string", + "description" : "Duration (ISO-8601)", + "example" : "P41M5S" + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether an album consist of any explicit content", + "example" : true + }, + "releaseDate" : { + "type" : "string", + "description" : "Release date (ISO-8601)", + "format" : "date", + "example" : "2017-06-30" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "popularity" : { + "type" : "number", + "description" : "Album popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines an album availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "mediaTags" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Media metadata tags", + "example" : "LOSSLESS" + } + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album cover images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "videoLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album cover videos", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Video_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to an album resource, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Albums_Item_Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + }, + "meta" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier_Meta" + } + } + }, + "Albums_Item_Resource_Identifier_Meta" : { + "required" : [ "trackNumber", "volumeNumber" ], + "type" : "object", + "properties" : { + "volumeNumber" : { + "type" : "integer", + "description" : "volume number", + "format" : "int32", + "example" : 1 + }, + "trackNumber" : { + "type" : "integer", + "description" : "track number", + "format" : "int32", + "example" : 4 + } + } + }, + "Albums_Items_Relationship" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Album items (tracks/videos) relationship" + }, + "Albums_Relationships" : { + "required" : [ "artists", "items", "providers", "similarAlbums" ], + "type" : "object", + "properties" : { + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "items" : { + "$ref" : "#/components/schemas/Albums_Items_Relationship" + }, + "similarAlbums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Albums_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Albums_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Albums_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Artists_Attributes" : { + "required" : [ "name", "popularity" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Artist name", + "example" : "JAY Z" + }, + "popularity" : { + "type" : "number", + "description" : "Artist popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an artist images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to an artist resource, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Artists_Relationships" : { + "required" : [ "albums", "radio", "similarArtists", "trackProviders", "tracks", "videos" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "tracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "videos" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "similarArtists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "trackProviders" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Relationship" + }, + "radio" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Artists_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Artists_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Artists_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Artists_Track_Providers_Relationship" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Providers that have released tracks for this artist" + }, + "Artists_Track_Providers_Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + }, + "meta" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier_Meta" + } + } + }, + "Artists_Track_Providers_Resource_Identifier_Meta" : { + "required" : [ "numberOfTracks" ], + "type" : "object", + "properties" : { + "numberOfTracks" : { + "type" : "integer", + "description" : "total number of tracks released together with the provider", + "format" : "int64", + "example" : 14 + } + } + }, + "Catalogue_Item_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/External_Link_Meta" + } + } + }, + "Catalogue_Item_Image_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + } + }, + "Catalogue_Item_Video_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to a video", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.mp4" + }, + "meta" : { + "$ref" : "#/components/schemas/Video_Link_Meta" + } + } + }, + "External_Link_Meta" : { + "required" : [ "type" ], + "type" : "object", + "properties" : { + "type" : { + "type" : "string", + "description" : "external link type", + "example" : "TIDAL_SHARING", + "enum" : [ "TIDAL_SHARING", "TIDAL_AUTOPLAY_ANDROID", "TIDAL_AUTOPLAY_IOS", "TIDAL_AUTOPLAY_WEB", "TWITTER", "FACEBOOK", "INSTAGRAM", "TIKTOK", "SNAPCHAT", "HOMEPAGE" ] + } + }, + "description" : "metadata about an external link" + }, + "Image_Link_Meta" : { + "required" : [ "height", "width" ], + "type" : "object", + "properties" : { + "width" : { + "type" : "integer", + "description" : "image width (in pixels)", + "format" : "int32", + "example" : 80 + }, + "height" : { + "type" : "integer", + "description" : "image height (in pixels)", + "format" : "int32", + "example" : 80 + } + }, + "description" : "metadata about an image" + }, + "Multi_Data_Relationship_Doc" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Playlist owners relationship" + }, + "Playlists_Attributes" : { + "required" : [ "bounded", "createdAt", "externalLinks", "imageLinks", "lastModifiedAt", "name", "playlistType", "privacy" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Playlist name", + "example" : "My Playlist" + }, + "description" : { + "type" : "string", + "description" : "Playlist description", + "example" : "All the good details about what is inside this playlist" + }, + "bounded" : { + "type" : "boolean", + "description" : "Indicates if the playlist has a duration and set number of tracks", + "example" : true + }, + "duration" : { + "type" : "string", + "description" : "Duration of the playlist expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "numberOfItems" : { + "type" : "integer", + "description" : "Number of items in the playlist", + "format" : "int32", + "example" : 5 + }, + "externalLinks" : { + "type" : "array", + "description" : "Sharing links to the playlist", + "example" : true, + "items" : { + "$ref" : "#/components/schemas/Playlists_External_Link" + } + }, + "createdAt" : { + "type" : "string", + "description" : "Datetime of playlist creation (ISO 8601)", + "format" : "date-time" + }, + "lastModifiedAt" : { + "type" : "string", + "description" : "Datetime of last modification of the playlist (ISO 8601)", + "format" : "date-time" + }, + "privacy" : { + "type" : "string", + "description" : "Privacy setting of the playlist", + "example" : "PUBLIC" + }, + "playlistType" : { + "type" : "string", + "description" : "The type of the playlist", + "example" : "EDITORIAL" + }, + "imageLinks" : { + "type" : "array", + "description" : "Images associated with the playlist", + "example" : true, + "items" : { + "$ref" : "#/components/schemas/Playlists_Image_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Playlists_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/External_Link_Meta" + } + }, + "description" : "Sharing links to the playlist", + "example" : true + }, + "Playlists_Image_Link" : { + "required" : [ "href" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + }, + "description" : "Images associated with the playlist", + "example" : true + }, + "Playlists_Relationships" : { + "required" : [ "items", "owners" ], + "type" : "object", + "properties" : { + "items" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "owners" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Playlists_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Playlists_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Playlists_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Providers_Attributes" : { + "required" : [ "name" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Provider name. Conditionally visible.", + "example" : "Columbia/Legacy" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Providers_Relationships" : { + "type" : "object", + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Providers_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Providers_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Providers_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + }, + "description" : "array of relationship resource linkages" + }, + "Tracks_Attributes" : { + "required" : [ "duration", "explicit", "isrc", "mediaTags", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Album item's title", + "example" : "Kill Jay Z" + }, + "version" : { + "type" : "string", + "description" : "Version of the album's item; complements title", + "example" : "Kill Jay Z" + }, + "isrc" : { + "type" : "string", + "description" : "ISRC code", + "example" : "TIDAL2274" + }, + "duration" : { + "type" : "string", + "description" : "Duration expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether a catalog item consist of any explicit content", + "example" : false + }, + "popularity" : { + "type" : "number", + "description" : "Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines a catalog item availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "mediaTags" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Media metadata tags", + "example" : "LOSSLESS" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to a catalog item, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Tracks_Relationships" : { + "required" : [ "albums", "artists", "providers", "radio", "similarTracks" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "similarTracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "radio" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Tracks_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Tracks_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Tracks_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Video_Link_Meta" : { + "required" : [ "height", "width" ], + "type" : "object", + "properties" : { + "width" : { + "type" : "integer", + "description" : "video width (in pixels)", + "format" : "int32", + "example" : 80 + }, + "height" : { + "type" : "integer", + "description" : "video height (in pixels)", + "format" : "int32", + "example" : 80 + } + }, + "description" : "metadata about a video" + }, + "Videos_Attributes" : { + "required" : [ "duration", "explicit", "isrc", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Album item's title", + "example" : "Kill Jay Z" + }, + "version" : { + "type" : "string", + "description" : "Version of the album's item; complements title", + "example" : "Kill Jay Z" + }, + "isrc" : { + "type" : "string", + "description" : "ISRC code", + "example" : "TIDAL2274" + }, + "duration" : { + "type" : "string", + "description" : "Duration expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "releaseDate" : { + "type" : "string", + "description" : "Release date (ISO-8601)", + "format" : "date", + "example" : "2017-06-27" + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether a catalog item consist of any explicit content", + "example" : false + }, + "popularity" : { + "type" : "number", + "description" : "Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines a catalog item availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album item images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to a catalog item, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Videos_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/Videos_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "Videos_Relationships" : { + "required" : [ "albums", "artists", "providers" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Videos_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Videos_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Videos_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Videos_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Videos_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "Providers_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Providers_Resource" + } ] + } + } + } + }, + "Artists_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "Albums_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + } ] + } + } + } + }, + "Singleton_Data_Relationship_Doc" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "User recommendations" + }, + "Tracks_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/Tracks_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Users_Attributes" : { + "required" : [ "country", "username" ], + "type" : "object", + "properties" : { + "username" : { + "type" : "string", + "description" : "user name", + "example" : "username" + }, + "country" : { + "type" : "string", + "description" : "ISO 3166-1 alpha-2 country code", + "example" : "US" + }, + "email" : { + "type" : "string", + "description" : "email address", + "example" : "test@test.com" + }, + "emailVerified" : { + "type" : "boolean", + "description" : "Is the email verified", + "example" : true + }, + "firstName" : { + "type" : "string", + "description" : "Users first name", + "example" : "John" + }, + "lastName" : { + "type" : "string", + "description" : "Users last name", + "example" : "Rambo" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Users_Relationships" : { + "required" : [ "entitlements", "publicProfile", "recommendations" ], + "type" : "object", + "properties" : { + "entitlements" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "publicProfile" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "recommendations" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Users_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Users_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Users_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Tracks_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Tracks_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Tracks_Relationships_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "Providers_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/Providers_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "Providers_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Providers_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "Artists_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/Artists_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Artists_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Artists_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Videos_Relationships_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + } ] + } + } + } + }, + "Artists_Track_Providers_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Providers_Resource" + } ] + } + } + } + }, + "Albums_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/Albums_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "Albums_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Albums_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "Albums_Items_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + } + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"880e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"415\",\n \"code\": \"UNSUPPORTED_MEDIA_TYPE\",\n \"detail\": \"Unsupported request media type: application/json. Expected media type format: application/vnd.api+json\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Bad_Request_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"550e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"400\",\n \"code\": \"INVALID_ENUM_VALUE\",\n \"detail\": \"country code must be in ISO2 format\",\n \"source\": {\n \"parameter\": \"countryCode\"\n },\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n },\n {\n \"id\": \"770e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"400\",\n \"code\": \"VALUE_REGEX_MISMATCH\",\n \"detail\": \"barcode should have a valid EAN-13 or UPC-A format\",\n \"source\": {\n \"parameter\": \"filter[barcodeId]\"\n },\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Internal_Server_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"120e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"500\",\n \"code\": \"INTERNAL_SERVER_ERROR\",\n \"detail\": \"The service encountered an error\",\n \"meta\": {\n \"category\": \"API_ERROR\"\n }\n }\n ]\n}\n" + }, + "Not_Acceptable_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"570e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"406\",\n \"code\": \"NOT_ACCEPTABLE\",\n \"detail\": \"Not acceptable response media type on client: application/xml\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Method_Not_Supported_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"320e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"405\",\n \"code\": \"METHOD_NOT_SUPPORTED\",\n \"detail\": \"The resource doesnt support the requested HTTP method: POST\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Resource_Not_Found_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"770e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"404\",\n \"code\": \"NOT_FOUND\",\n \"detail\": \"Resource for a given 'id' is not found\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Unavailable_For_Legal_Reasons_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"490e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"451\",\n \"code\": \"UNAVAILABLE_FOR_LEGAL_REASONS_RESPONSE\",\n \"detail\": \"Unavailable due to demand from the right-holders to prohibit access to the resource.\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + } + }, + "securitySchemes" : { + "Authorization_Code_PKCE" : { + "type" : "oauth2", + "description" : "Use this grant flow to access users both personalized and non-personalized TIDAL data.", + "flows" : { + "authorizationCode" : { + "authorizationUrl" : "https://login.tidal.com/", + "tokenUrl" : "https://auth.tidal.com/v1/", + "scopes" : { + "user.read" : "Read access to a user's account information, such as country and email address.", + "entitlements.read" : "Read access to a user's entitlements", + "playlists.read" : "Read access to a user's playlists", + "recommendations.read" : "Read access to a user's recommendations", + "public-profile.read" : "Read access to a user's public profile", + "public-profile.write" : "Write access to a user's public profile" + } + } + }, + "x-scopes-required-access-tier" : { + "user.read" : "THIRD_PARTY", + "entitlements.read" : "THIRD_PARTY", + "playlists.read" : "THIRD_PARTY", + "recommendations.read" : "THIRD_PARTY", + "public-profile.read" : "INTERNAL", + "public-profile.write" : "INTERNAL" + } + }, + "Client_Credentials" : { + "type" : "oauth2", + "description" : "Use this grant flow to access non-personalized TIDAL data.", + "flows" : { + "clientCredentials" : { + "tokenUrl" : "https://auth.tidal.com/v1/", + "scopes" : { } + } + } + } + } + } +} \ No newline at end of file diff --git a/Sources/API/Config/input/tidal-search-v2-openapi-3.0.json b/Sources/API/Config/input/tidal-search-v2-openapi-3.0.json new file mode 100644 index 00000000..ba0e7056 --- /dev/null +++ b/Sources/API/Config/input/tidal-search-v2-openapi-3.0.json @@ -0,0 +1,4379 @@ +{ + "openapi" : "3.0.1", + "info" : { + "title" : "Search v2 - beta", + "description" : "The Search API v2 provides a set of JSON:API compatible endpoints for searching the TIDAL metadata catalogue: albums, artists, tracks, videos, and more", + "contact" : { + "url" : "https://github.com/orgs/tidal-music/discussions" + }, + "version" : "1.0.0", + "x-url-compatible-spec-id" : "search-v2", + "x-spec-default-endpoint-url-unique-name" : "get-searchresults-v2" + }, + "externalDocs" : { + "description" : "TIDAL Developer Documentation", + "url" : "https://developer.tidal.com/documentation" + }, + "servers" : [ { + "url" : "https://openapi.tidal.com/v2", + "description" : "Production" + } ], + "tags" : [ { + "name" : "Search Results", + "description" : "Search Results JSON:API endpoints" + } ], + "paths" : { + "/searchresults/{query}" : { + "get" : { + "tags" : [ "Search Results" ], + "summary" : "Search for music metadata by a query", + "description" : "Search for music: albums, artists, tracks, etc.", + "operationId" : "getSearchResultsByQuery", + "parameters" : [ { + "name" : "query", + "in" : "path", + "description" : "Search query", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "moon" + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists, albums, tracks, videos, playlists, topHits", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Search_Results_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-searchresults-v2", + "json-api-available-relationships" : [ "artists", "albums", "tracks", "videos", "playlists", "topHits" ] + } + } + }, + "/searchresults/{query}/relationships/videos" : { + "get" : { + "tags" : [ "Search Results" ], + "summary" : "Relationship: videos", + "description" : "Search for videos by a query.", + "operationId" : "getSearchResultsVideosRelationship", + "parameters" : [ { + "name" : "query", + "in" : "path", + "description" : "Search query", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "moon" + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: videos", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "videos" + } + }, + "example" : "videos" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Videos_Relationships_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-searchresults-relationship-videos-v2", + "json-api-available-relationships" : [ "videos" ] + } + } + }, + "/searchresults/{query}/relationships/tracks" : { + "get" : { + "tags" : [ "Search Results" ], + "summary" : "Relationship: tracks", + "description" : "Search for tracks by a query.", + "operationId" : "getSearchResultsTracksRelationship", + "parameters" : [ { + "name" : "query", + "in" : "path", + "description" : "Search query", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "moon" + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: tracks", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "tracks" + } + }, + "example" : "tracks" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Tracks_Relationships_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-searchresults-relationship-tracks-v2", + "json-api-available-relationships" : [ "tracks" ] + } + } + }, + "/searchresults/{query}/relationships/topHits" : { + "get" : { + "tags" : [ "Search Results" ], + "summary" : "Relationship: topHits", + "description" : "Search for top hits by a query: artists, albums, tracks, videos.", + "operationId" : "getSearchResultsTopHitsRelationship", + "parameters" : [ { + "name" : "query", + "in" : "path", + "description" : "Search query", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "moon" + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: topHits", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "topHits" + } + }, + "example" : "topHits" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Search_Results_Top_Hits_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-searchresults-relationship-tophits-v2", + "json-api-available-relationships" : [ "topHits" ] + } + } + }, + "/searchresults/{query}/relationships/playlists" : { + "get" : { + "tags" : [ "Search Results" ], + "summary" : "Relationship: playlists", + "description" : "Search for playlists by a query.", + "operationId" : "getSearchResultsPlaylistsRelationship", + "parameters" : [ { + "name" : "query", + "in" : "path", + "description" : "Searh query", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "moon" + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: playlists", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "playlists" + } + }, + "example" : "playlists" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-searchresults-relationship-playlists-v2", + "json-api-available-relationships" : [ "playlists" ] + } + } + }, + "/searchresults/{query}/relationships/artists" : { + "get" : { + "tags" : [ "Search Results" ], + "summary" : "Relationship: artists", + "description" : "Search for artists by a query.", + "operationId" : "getSearchResultsArtistsRelationship", + "parameters" : [ { + "name" : "query", + "in" : "path", + "description" : "Search query", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "moon" + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: artists", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "artists" + } + }, + "example" : "artists" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Artists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-searchresults-relationship-artists-v2", + "json-api-available-relationships" : [ "artists" ] + } + } + }, + "/searchresults/{query}/relationships/albums" : { + "get" : { + "tags" : [ "Search Results" ], + "summary" : "Relationship: albums", + "description" : "Search for albums by a query.", + "operationId" : "getSearchResultsAlbumsRelationship", + "parameters" : [ { + "name" : "query", + "in" : "path", + "description" : "Search query", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "moon" + }, { + "name" : "countryCode", + "in" : "query", + "description" : "ISO 3166-1 alpha-2 country code", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: albums", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "albums" + } + }, + "example" : "albums" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Albums_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Client_Credentials" : [ ] + }, { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-searchresults-relationship-albums-v2", + "json-api-available-relationships" : [ "albums" ] + } + } + } + }, + "components" : { + "schemas" : { + "Error_Document" : { + "type" : "object", + "properties" : { + "errors" : { + "type" : "array", + "description" : "array of error objects", + "items" : { + "$ref" : "#/components/schemas/Error_Object" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "Error_Object" : { + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "unique identifier for this particular occurrence of the problem" + }, + "status" : { + "type" : "string", + "description" : "HTTP status code applicable to this problem" + }, + "code" : { + "type" : "string", + "description" : "application-specific error code" + }, + "detail" : { + "type" : "string", + "description" : "human-readable explanation specific to this occurrence of the problem" + }, + "source" : { + "$ref" : "#/components/schemas/Error_Object_Source" + } + } + }, + "Error_Object_Source" : { + "type" : "object", + "properties" : { + "pointer" : { + "type" : "string", + "description" : "a JSON Pointer [RFC6901] to the value in the request document that caused the error", + "example" : "/data/attributes/title" + }, + "parameter" : { + "type" : "string", + "description" : "string indicating which URI query parameter caused the error.", + "example" : "countryCode" + }, + "header" : { + "type" : "string", + "description" : "string indicating the name of a single request header which caused the error", + "example" : "X-some-custom-header" + } + }, + "description" : "object containing references to the primary source of the error" + }, + "Links" : { + "required" : [ "self" ], + "type" : "object", + "properties" : { + "self" : { + "type" : "string", + "description" : "the link that generated the current response document", + "example" : "/artists/xyz/relationships/tracks" + }, + "next" : { + "type" : "string", + "description" : "the next page of data (pagination)", + "example" : "/artists/xyz/relationships/tracks?page[cursor]=zyx" + } + }, + "description" : "links object" + }, + "Albums_Attributes" : { + "required" : [ "barcodeId", "duration", "explicit", "mediaTags", "numberOfItems", "numberOfVolumes", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Original title", + "example" : "4:44" + }, + "barcodeId" : { + "type" : "string", + "description" : "Barcode id (EAN-13 or UPC-A)", + "example" : "00854242007552" + }, + "numberOfVolumes" : { + "type" : "integer", + "description" : "Number of volumes", + "format" : "int32", + "example" : 1 + }, + "numberOfItems" : { + "type" : "integer", + "description" : "Number of album items", + "format" : "int32", + "example" : 13 + }, + "duration" : { + "type" : "string", + "description" : "Duration (ISO-8601)", + "example" : "P41M5S" + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether an album consist of any explicit content", + "example" : true + }, + "releaseDate" : { + "type" : "string", + "description" : "Release date (ISO-8601)", + "format" : "date", + "example" : "2017-06-30" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "popularity" : { + "type" : "number", + "description" : "Album popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines an album availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "mediaTags" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Media metadata tags", + "example" : "LOSSLESS" + } + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album cover images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "videoLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album cover videos", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Video_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to an album resource, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Albums_Item_Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + }, + "meta" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier_Meta" + } + } + }, + "Albums_Item_Resource_Identifier_Meta" : { + "required" : [ "trackNumber", "volumeNumber" ], + "type" : "object", + "properties" : { + "volumeNumber" : { + "type" : "integer", + "description" : "volume number", + "format" : "int32", + "example" : 1 + }, + "trackNumber" : { + "type" : "integer", + "description" : "track number", + "format" : "int32", + "example" : 4 + } + } + }, + "Albums_Items_Relationship" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Album items (tracks/videos) relationship" + }, + "Albums_Relationships" : { + "required" : [ "artists", "items", "providers", "similarAlbums" ], + "type" : "object", + "properties" : { + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "items" : { + "$ref" : "#/components/schemas/Albums_Items_Relationship" + }, + "similarAlbums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Albums_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Albums_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Albums_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Artists_Attributes" : { + "required" : [ "name", "popularity" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Artist name", + "example" : "JAY Z" + }, + "popularity" : { + "type" : "number", + "description" : "Artist popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an artist images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to an artist resource, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Artists_Relationships" : { + "required" : [ "albums", "radio", "similarArtists", "trackProviders", "tracks", "videos" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "tracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "videos" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "similarArtists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "trackProviders" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Relationship" + }, + "radio" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Artists_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Artists_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Artists_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Artists_Track_Providers_Relationship" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Providers that have released tracks for this artist" + }, + "Artists_Track_Providers_Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + }, + "meta" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier_Meta" + } + } + }, + "Artists_Track_Providers_Resource_Identifier_Meta" : { + "required" : [ "numberOfTracks" ], + "type" : "object", + "properties" : { + "numberOfTracks" : { + "type" : "integer", + "description" : "total number of tracks released together with the provider", + "format" : "int64", + "example" : 14 + } + } + }, + "Catalogue_Item_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/External_Link_Meta" + } + } + }, + "Catalogue_Item_Image_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + } + }, + "Catalogue_Item_Video_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to a video", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.mp4" + }, + "meta" : { + "$ref" : "#/components/schemas/Video_Link_Meta" + } + } + }, + "External_Link_Meta" : { + "required" : [ "type" ], + "type" : "object", + "properties" : { + "type" : { + "type" : "string", + "description" : "external link type", + "example" : "TIDAL_SHARING", + "enum" : [ "TIDAL_SHARING", "TIDAL_AUTOPLAY_ANDROID", "TIDAL_AUTOPLAY_IOS", "TIDAL_AUTOPLAY_WEB", "TWITTER", "FACEBOOK", "INSTAGRAM", "TIKTOK", "SNAPCHAT", "HOMEPAGE" ] + } + }, + "description" : "metadata about an external link" + }, + "Image_Link_Meta" : { + "required" : [ "height", "width" ], + "type" : "object", + "properties" : { + "width" : { + "type" : "integer", + "description" : "image width (in pixels)", + "format" : "int32", + "example" : 80 + }, + "height" : { + "type" : "integer", + "description" : "image height (in pixels)", + "format" : "int32", + "example" : 80 + } + }, + "description" : "metadata about an image" + }, + "Multi_Data_Relationship_Doc" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Playlist owners relationship" + }, + "Playlists_Attributes" : { + "required" : [ "bounded", "createdAt", "externalLinks", "imageLinks", "lastModifiedAt", "name", "playlistType", "privacy" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Playlist name", + "example" : "My Playlist" + }, + "description" : { + "type" : "string", + "description" : "Playlist description", + "example" : "All the good details about what is inside this playlist" + }, + "bounded" : { + "type" : "boolean", + "description" : "Indicates if the playlist has a duration and set number of tracks", + "example" : true + }, + "duration" : { + "type" : "string", + "description" : "Duration of the playlist expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "numberOfItems" : { + "type" : "integer", + "description" : "Number of items in the playlist", + "format" : "int32", + "example" : 5 + }, + "externalLinks" : { + "type" : "array", + "description" : "Sharing links to the playlist", + "example" : true, + "items" : { + "$ref" : "#/components/schemas/Playlists_External_Link" + } + }, + "createdAt" : { + "type" : "string", + "description" : "Datetime of playlist creation (ISO 8601)", + "format" : "date-time" + }, + "lastModifiedAt" : { + "type" : "string", + "description" : "Datetime of last modification of the playlist (ISO 8601)", + "format" : "date-time" + }, + "privacy" : { + "type" : "string", + "description" : "Privacy setting of the playlist", + "example" : "PUBLIC" + }, + "playlistType" : { + "type" : "string", + "description" : "The type of the playlist", + "example" : "EDITORIAL" + }, + "imageLinks" : { + "type" : "array", + "description" : "Images associated with the playlist", + "example" : true, + "items" : { + "$ref" : "#/components/schemas/Playlists_Image_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Playlists_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/External_Link_Meta" + } + }, + "description" : "Sharing links to the playlist", + "example" : true + }, + "Playlists_Image_Link" : { + "required" : [ "href" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + }, + "description" : "Images associated with the playlist", + "example" : true + }, + "Playlists_Relationships" : { + "required" : [ "items", "owners" ], + "type" : "object", + "properties" : { + "items" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "owners" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Playlists_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Playlists_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Playlists_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Providers_Attributes" : { + "required" : [ "name" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Provider name. Conditionally visible.", + "example" : "Columbia/Legacy" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Providers_Relationships" : { + "type" : "object", + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Providers_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Providers_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Providers_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + }, + "description" : "relationship resource linkage" + }, + "Search_Results_Attributes" : { + "required" : [ "trackingId" ], + "type" : "object", + "properties" : { + "trackingId" : { + "type" : "string", + "description" : "search request unique tracking number", + "example" : "5896e37d-e847-4ca6-9629-ef8001719f7f" + }, + "didYouMean" : { + "type" : "string", + "description" : "'did you mean' prompt", + "example" : "beatles" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Search_Results_Relationships" : { + "required" : [ "albums", "artists", "playlists", "topHits", "tracks", "videos" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "tracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "videos" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "playlists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "topHits" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Search_Results_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Search_Results_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Search_Results_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + }, + "description" : "primary resource data" + }, + "Search_Results_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Search_Results_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Singleton_Data_Relationship_Doc" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "User recommendations" + }, + "Tracks_Attributes" : { + "required" : [ "duration", "explicit", "isrc", "mediaTags", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Album item's title", + "example" : "Kill Jay Z" + }, + "version" : { + "type" : "string", + "description" : "Version of the album's item; complements title", + "example" : "Kill Jay Z" + }, + "isrc" : { + "type" : "string", + "description" : "ISRC code", + "example" : "TIDAL2274" + }, + "duration" : { + "type" : "string", + "description" : "Duration expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether a catalog item consist of any explicit content", + "example" : false + }, + "popularity" : { + "type" : "number", + "description" : "Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines a catalog item availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "mediaTags" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Media metadata tags", + "example" : "LOSSLESS" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to a catalog item, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Tracks_Relationships" : { + "required" : [ "albums", "artists", "providers", "radio", "similarTracks" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "similarTracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "radio" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Tracks_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Tracks_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Tracks_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Users_Attributes" : { + "required" : [ "country", "username" ], + "type" : "object", + "properties" : { + "username" : { + "type" : "string", + "description" : "user name", + "example" : "username" + }, + "country" : { + "type" : "string", + "description" : "ISO 3166-1 alpha-2 country code", + "example" : "US" + }, + "email" : { + "type" : "string", + "description" : "email address", + "example" : "test@test.com" + }, + "emailVerified" : { + "type" : "boolean", + "description" : "Is the email verified", + "example" : true + }, + "firstName" : { + "type" : "string", + "description" : "Users first name", + "example" : "John" + }, + "lastName" : { + "type" : "string", + "description" : "Users last name", + "example" : "Rambo" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Users_Relationships" : { + "required" : [ "entitlements", "publicProfile", "recommendations" ], + "type" : "object", + "properties" : { + "entitlements" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "publicProfile" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "recommendations" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Users_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Users_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Users_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Video_Link_Meta" : { + "required" : [ "height", "width" ], + "type" : "object", + "properties" : { + "width" : { + "type" : "integer", + "description" : "video width (in pixels)", + "format" : "int32", + "example" : 80 + }, + "height" : { + "type" : "integer", + "description" : "video height (in pixels)", + "format" : "int32", + "example" : 80 + } + }, + "description" : "metadata about a video" + }, + "Videos_Attributes" : { + "required" : [ "duration", "explicit", "isrc", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Album item's title", + "example" : "Kill Jay Z" + }, + "version" : { + "type" : "string", + "description" : "Version of the album's item; complements title", + "example" : "Kill Jay Z" + }, + "isrc" : { + "type" : "string", + "description" : "ISRC code", + "example" : "TIDAL2274" + }, + "duration" : { + "type" : "string", + "description" : "Duration expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "releaseDate" : { + "type" : "string", + "description" : "Release date (ISO-8601)", + "format" : "date", + "example" : "2017-06-27" + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether a catalog item consist of any explicit content", + "example" : false + }, + "popularity" : { + "type" : "number", + "description" : "Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines a catalog item availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album item images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to a catalog item, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Videos_Relationships" : { + "required" : [ "albums", "artists", "providers" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Videos_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Videos_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Videos_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Videos_Relationships_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + } ] + } + } + } + }, + "Tracks_Relationships_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "Search_Results_Top_Hits_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Playlists_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Artists_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "Albums_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + } ] + } + } + } + } + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"880e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"415\",\n \"code\": \"UNSUPPORTED_MEDIA_TYPE\",\n \"detail\": \"Unsupported request media type: application/json. Expected media type format: application/vnd.api+json\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Bad_Request_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"550e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"400\",\n \"code\": \"INVALID_ENUM_VALUE\",\n \"detail\": \"country code must be in ISO2 format\",\n \"source\": {\n \"parameter\": \"countryCode\"\n },\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n },\n {\n \"id\": \"770e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"400\",\n \"code\": \"VALUE_REGEX_MISMATCH\",\n \"detail\": \"barcode should have a valid EAN-13 or UPC-A format\",\n \"source\": {\n \"parameter\": \"filter[barcodeId]\"\n },\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Internal_Server_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"120e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"500\",\n \"code\": \"INTERNAL_SERVER_ERROR\",\n \"detail\": \"The service encountered an error\",\n \"meta\": {\n \"category\": \"API_ERROR\"\n }\n }\n ]\n}\n" + }, + "Not_Acceptable_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"570e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"406\",\n \"code\": \"NOT_ACCEPTABLE\",\n \"detail\": \"Not acceptable response media type on client: application/xml\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Method_Not_Supported_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"320e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"405\",\n \"code\": \"METHOD_NOT_SUPPORTED\",\n \"detail\": \"The resource doesnt support the requested HTTP method: POST\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Resource_Not_Found_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"770e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"404\",\n \"code\": \"NOT_FOUND\",\n \"detail\": \"Resource for a given 'id' is not found\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Unavailable_For_Legal_Reasons_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"490e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"451\",\n \"code\": \"UNAVAILABLE_FOR_LEGAL_REASONS_RESPONSE\",\n \"detail\": \"Unavailable due to demand from the right-holders to prohibit access to the resource.\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + } + }, + "securitySchemes" : { + "Authorization_Code_PKCE" : { + "type" : "oauth2", + "description" : "Use this grant flow to access users both personalized and non-personalized TIDAL data.", + "flows" : { + "authorizationCode" : { + "authorizationUrl" : "https://login.tidal.com/", + "tokenUrl" : "https://auth.tidal.com/v1/", + "scopes" : { + "user.read" : "Read access to a user's account information, such as country and email address.", + "entitlements.read" : "Read access to a user's entitlements", + "playlists.read" : "Read access to a user's playlists", + "recommendations.read" : "Read access to a user's recommendations", + "public-profile.read" : "Read access to a user's public profile", + "public-profile.write" : "Write access to a user's public profile" + } + } + }, + "x-scopes-required-access-tier" : { + "user.read" : "THIRD_PARTY", + "entitlements.read" : "THIRD_PARTY", + "playlists.read" : "THIRD_PARTY", + "recommendations.read" : "THIRD_PARTY", + "public-profile.read" : "INTERNAL", + "public-profile.write" : "INTERNAL" + } + }, + "Client_Credentials" : { + "type" : "oauth2", + "description" : "Use this grant flow to access non-personalized TIDAL data.", + "flows" : { + "clientCredentials" : { + "tokenUrl" : "https://auth.tidal.com/v1/", + "scopes" : { } + } + } + } + } + } +} \ No newline at end of file diff --git a/Sources/API/Config/input/tidal-user-content-openapi-3.0.json b/Sources/API/Config/input/tidal-user-content-openapi-3.0.json new file mode 100644 index 00000000..f04f8fa6 --- /dev/null +++ b/Sources/API/Config/input/tidal-user-content-openapi-3.0.json @@ -0,0 +1,3581 @@ +{ + "openapi" : "3.0.1", + "info" : { + "title" : "Playlist v2 - beta", + "description" : "The Playlist API v2 provides a set of JSON:API compatible endpoints for accessing and managing various playlists", + "contact" : { + "url" : "https://github.com/orgs/tidal-music/discussions" + }, + "version" : "1.0.0", + "x-url-compatible-spec-id" : "user-playlist-v2", + "x-spec-default-endpoint-url-unique-name" : "get-playlists-v2" + }, + "externalDocs" : { + "description" : "TIDAL Developer Documentation", + "url" : "https://developer.tidal.com/documentation" + }, + "servers" : [ { + "url" : "https://openapi.tidal.com/v2", + "description" : "Production" + } ], + "tags" : [ { + "name" : "Playlists", + "description" : "Playlists JSON:API endpoints" + } ], + "paths" : { + "/playlists" : { + "get" : { + "tags" : [ "Playlists" ], + "summary" : "Get multiple playlists", + "description" : "Get user playlists", + "operationId" : "getPlaylistsByFilters", + "parameters" : [ { + "name" : "countryCode", + "in" : "query", + "description" : "Country code (ISO 3166-1 alpha-2)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: items, owners", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "items" + } + }, + "example" : "items" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "public.usercontent.getPlaylists.ids.descr", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "123456" + } + }, + "example" : "123456" + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Playlists retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "*/*" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "playlists.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id" ], + "url-compatible-unique-name" : "get-playlists-v2", + "json-api-available-relationships" : [ "items", "owners" ] + } + } + }, + "/playlists/{id}" : { + "get" : { + "tags" : [ "Playlists" ], + "summary" : "Get single playlist", + "description" : "Get playlist by id", + "operationId" : "getPlaylistById", + "parameters" : [ { + "name" : "countryCode", + "in" : "query", + "description" : "Country code (ISO 3166-1 alpha-2)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "id", + "in" : "path", + "description" : "TIDAL playlist id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 12345678 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: items, owners", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "items" + } + }, + "example" : "items" + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Playlist retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "playlists.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-playlist-by-id-v2", + "json-api-available-relationships" : [ "items", "owners" ] + } + } + }, + "/playlists/{id}/relationships/owners" : { + "get" : { + "tags" : [ "Playlists" ], + "summary" : "Relationship: owner", + "description" : "Get playlist owner", + "operationId" : "getPlaylistOwnersRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL playlist id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 12345678 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "Country code (ISO 3166-1 alpha-2)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: owners", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "owners" + } + }, + "example" : "owners" + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Playlist owner retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Owners_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "playlists.read", "user.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-playlist-owner-v2", + "json-api-available-relationships" : [ "owners" ] + } + } + }, + "/playlists/{id}/relationships/items" : { + "get" : { + "tags" : [ "Playlists" ], + "summary" : "Relationship: items", + "description" : "Get playlist items", + "operationId" : "getPlaylistItemsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL playlist id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 12345678 + }, { + "name" : "countryCode", + "in" : "query", + "description" : "Country code (ISO 3166-1 alpha-2)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: items", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "items" + } + }, + "example" : "items" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Playlist items retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Items_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "playlists.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-playlist-items-v2", + "json-api-available-relationships" : [ "items" ] + } + } + }, + "/playlists/me" : { + "get" : { + "tags" : [ "Playlists" ], + "summary" : "Get current user's playlists", + "description" : "Get my playlists", + "operationId" : "getMyPlaylists", + "parameters" : [ { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: items, owners", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "items" + } + }, + "example" : "items" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Playlists retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "playlists.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-my-playlists-v2", + "json-api-available-relationships" : [ "items", "owners" ] + } + } + } + }, + "components" : { + "schemas" : { + "Error_Document" : { + "type" : "object", + "properties" : { + "errors" : { + "type" : "array", + "description" : "array of error objects", + "items" : { + "$ref" : "#/components/schemas/Error_Object" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "Error_Object" : { + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "unique identifier for this particular occurrence of the problem" + }, + "status" : { + "type" : "string", + "description" : "HTTP status code applicable to this problem" + }, + "code" : { + "type" : "string", + "description" : "application-specific error code" + }, + "detail" : { + "type" : "string", + "description" : "human-readable explanation specific to this occurrence of the problem" + }, + "source" : { + "$ref" : "#/components/schemas/Error_Object_Source" + } + } + }, + "Error_Object_Source" : { + "type" : "object", + "properties" : { + "pointer" : { + "type" : "string", + "description" : "a JSON Pointer [RFC6901] to the value in the request document that caused the error", + "example" : "/data/attributes/title" + }, + "parameter" : { + "type" : "string", + "description" : "string indicating which URI query parameter caused the error.", + "example" : "countryCode" + }, + "header" : { + "type" : "string", + "description" : "string indicating the name of a single request header which caused the error", + "example" : "X-some-custom-header" + } + }, + "description" : "object containing references to the primary source of the error" + }, + "Links" : { + "required" : [ "self" ], + "type" : "object", + "properties" : { + "self" : { + "type" : "string", + "description" : "the link that generated the current response document", + "example" : "/artists/xyz/relationships/tracks" + }, + "next" : { + "type" : "string", + "description" : "the next page of data (pagination)", + "example" : "/artists/xyz/relationships/tracks?page[cursor]=zyx" + } + }, + "description" : "links object" + }, + "Albums_Attributes" : { + "required" : [ "barcodeId", "duration", "explicit", "mediaTags", "numberOfItems", "numberOfVolumes", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Original title", + "example" : "4:44" + }, + "barcodeId" : { + "type" : "string", + "description" : "Barcode id (EAN-13 or UPC-A)", + "example" : "00854242007552" + }, + "numberOfVolumes" : { + "type" : "integer", + "description" : "Number of volumes", + "format" : "int32", + "example" : 1 + }, + "numberOfItems" : { + "type" : "integer", + "description" : "Number of album items", + "format" : "int32", + "example" : 13 + }, + "duration" : { + "type" : "string", + "description" : "Duration (ISO-8601)", + "example" : "P41M5S" + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether an album consist of any explicit content", + "example" : true + }, + "releaseDate" : { + "type" : "string", + "description" : "Release date (ISO-8601)", + "format" : "date", + "example" : "2017-06-30" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "popularity" : { + "type" : "number", + "description" : "Album popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines an album availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "mediaTags" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Media metadata tags", + "example" : "LOSSLESS" + } + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album cover images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "videoLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album cover videos", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Video_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to an album resource, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Albums_Item_Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + }, + "meta" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier_Meta" + } + } + }, + "Albums_Item_Resource_Identifier_Meta" : { + "required" : [ "trackNumber", "volumeNumber" ], + "type" : "object", + "properties" : { + "volumeNumber" : { + "type" : "integer", + "description" : "volume number", + "format" : "int32", + "example" : 1 + }, + "trackNumber" : { + "type" : "integer", + "description" : "track number", + "format" : "int32", + "example" : 4 + } + } + }, + "Albums_Items_Relationship" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Album items (tracks/videos) relationship" + }, + "Albums_Relationships" : { + "required" : [ "artists", "items", "providers", "similarAlbums" ], + "type" : "object", + "properties" : { + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "items" : { + "$ref" : "#/components/schemas/Albums_Items_Relationship" + }, + "similarAlbums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Albums_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Albums_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Albums_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Artists_Attributes" : { + "required" : [ "name", "popularity" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Artist name", + "example" : "JAY Z" + }, + "popularity" : { + "type" : "number", + "description" : "Artist popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an artist images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to an artist resource, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Artists_Relationships" : { + "required" : [ "albums", "radio", "similarArtists", "trackProviders", "tracks", "videos" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "tracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "videos" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "similarArtists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "trackProviders" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Relationship" + }, + "radio" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Artists_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Artists_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Artists_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Artists_Track_Providers_Relationship" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Providers that have released tracks for this artist" + }, + "Artists_Track_Providers_Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + }, + "meta" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier_Meta" + } + } + }, + "Artists_Track_Providers_Resource_Identifier_Meta" : { + "required" : [ "numberOfTracks" ], + "type" : "object", + "properties" : { + "numberOfTracks" : { + "type" : "integer", + "description" : "total number of tracks released together with the provider", + "format" : "int64", + "example" : 14 + } + } + }, + "Catalogue_Item_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/External_Link_Meta" + } + } + }, + "Catalogue_Item_Image_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + } + }, + "Catalogue_Item_Video_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to a video", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.mp4" + }, + "meta" : { + "$ref" : "#/components/schemas/Video_Link_Meta" + } + } + }, + "External_Link_Meta" : { + "required" : [ "type" ], + "type" : "object", + "properties" : { + "type" : { + "type" : "string", + "description" : "external link type", + "example" : "TIDAL_SHARING", + "enum" : [ "TIDAL_SHARING", "TIDAL_AUTOPLAY_ANDROID", "TIDAL_AUTOPLAY_IOS", "TIDAL_AUTOPLAY_WEB", "TWITTER", "FACEBOOK", "INSTAGRAM", "TIKTOK", "SNAPCHAT", "HOMEPAGE" ] + } + }, + "description" : "metadata about an external link" + }, + "Image_Link_Meta" : { + "required" : [ "height", "width" ], + "type" : "object", + "properties" : { + "width" : { + "type" : "integer", + "description" : "image width (in pixels)", + "format" : "int32", + "example" : 80 + }, + "height" : { + "type" : "integer", + "description" : "image height (in pixels)", + "format" : "int32", + "example" : 80 + } + }, + "description" : "metadata about an image" + }, + "Multi_Data_Relationship_Doc" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "User profile public picks" + }, + "Playlists_Attributes" : { + "required" : [ "bounded", "createdAt", "externalLinks", "imageLinks", "lastModifiedAt", "name", "playlistType", "privacy" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Playlist name", + "example" : "My Playlist" + }, + "description" : { + "type" : "string", + "description" : "Playlist description", + "example" : "All the good details about what is inside this playlist" + }, + "bounded" : { + "type" : "boolean", + "description" : "Indicates if the playlist has a duration and set number of tracks", + "example" : true + }, + "duration" : { + "type" : "string", + "description" : "Duration of the playlist expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "numberOfItems" : { + "type" : "integer", + "description" : "Number of items in the playlist", + "format" : "int32", + "example" : 5 + }, + "externalLinks" : { + "type" : "array", + "description" : "Sharing links to the playlist", + "example" : true, + "items" : { + "$ref" : "#/components/schemas/Playlists_External_Link" + } + }, + "createdAt" : { + "type" : "string", + "description" : "Datetime of playlist creation (ISO 8601)", + "format" : "date-time" + }, + "lastModifiedAt" : { + "type" : "string", + "description" : "Datetime of last modification of the playlist (ISO 8601)", + "format" : "date-time" + }, + "privacy" : { + "type" : "string", + "description" : "Privacy setting of the playlist", + "example" : "PUBLIC" + }, + "playlistType" : { + "type" : "string", + "description" : "The type of the playlist", + "example" : "EDITORIAL" + }, + "imageLinks" : { + "type" : "array", + "description" : "Images associated with the playlist", + "example" : true, + "items" : { + "$ref" : "#/components/schemas/Playlists_Image_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Playlists_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/External_Link_Meta" + } + }, + "description" : "Sharing links to the playlist", + "example" : true + }, + "Playlists_Image_Link" : { + "required" : [ "href" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + }, + "description" : "Images associated with the playlist", + "example" : true + }, + "Playlists_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/Playlists_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + } ] + } + } + } + }, + "Playlists_Relationships" : { + "required" : [ "items", "owners" ], + "type" : "object", + "properties" : { + "items" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "owners" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Playlists_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Playlists_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Playlists_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Providers_Attributes" : { + "required" : [ "name" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Provider name. Conditionally visible.", + "example" : "Columbia/Legacy" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Providers_Relationships" : { + "type" : "object", + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Providers_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Providers_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Providers_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + }, + "description" : "relationship resource linkage" + }, + "Singleton_Data_Relationship_Doc" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "User recommendations" + }, + "Tracks_Attributes" : { + "required" : [ "duration", "explicit", "isrc", "mediaTags", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Album item's title", + "example" : "Kill Jay Z" + }, + "version" : { + "type" : "string", + "description" : "Version of the album's item; complements title", + "example" : "Kill Jay Z" + }, + "isrc" : { + "type" : "string", + "description" : "ISRC code", + "example" : "TIDAL2274" + }, + "duration" : { + "type" : "string", + "description" : "Duration expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether a catalog item consist of any explicit content", + "example" : false + }, + "popularity" : { + "type" : "number", + "description" : "Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines a catalog item availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "mediaTags" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Media metadata tags", + "example" : "LOSSLESS" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to a catalog item, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Tracks_Relationships" : { + "required" : [ "albums", "artists", "providers", "radio", "similarTracks" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "similarTracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "radio" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Tracks_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Tracks_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Tracks_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Entitlements_Attributes" : { + "required" : [ "entitlements" ], + "type" : "object", + "properties" : { + "entitlements" : { + "type" : "array", + "description" : "entitlements for user", + "items" : { + "type" : "string", + "description" : "entitlements for user", + "enum" : [ "MUSIC", "DJ" ] + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "User_Entitlements_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/User_Entitlements_Attributes" + }, + "relationships" : { + "type" : "object", + "description" : "relationships object describing relationships between the resource and other resources" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Public_Profiles_Attributes" : { + "required" : [ "color" ], + "type" : "object", + "properties" : { + "profileName" : { + "type" : "string", + "description" : "Public Name of the user profile", + "example" : "JohnSmith" + }, + "picture" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Image_Link" + }, + "color" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Color information for the user profile when no image is available", + "example" : "326650" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "ExternalLinks for the user's profile", + "items" : { + "$ref" : "#/components/schemas/User_Public_Profiles_External_Link" + } + }, + "numberOfFollowers" : { + "type" : "integer", + "description" : "Number of followers for the user", + "format" : "int32", + "example" : 32 + }, + "numberOfFollows" : { + "type" : "integer", + "description" : "Number of users the user follows", + "format" : "int32", + "example" : 32 + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "User_Public_Profiles_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/User_Public_Profiles_External_Link_Meta" + } + } + }, + "User_Public_Profiles_External_Link_Meta" : { + "required" : [ "handle", "type" ], + "type" : "object", + "properties" : { + "type" : { + "type" : "string", + "description" : "external link type", + "example" : "TIDAL_SHARING", + "enum" : [ "TIDAL_SHARING", "TIDAL_AUTOPLAY_ANDROID", "TIDAL_AUTOPLAY_IOS", "TIDAL_AUTOPLAY_WEB", "TWITTER", "FACEBOOK", "INSTAGRAM", "TIKTOK", "SNAPCHAT", "HOMEPAGE" ] + }, + "handle" : { + "type" : "string", + "description" : "external link handle", + "example" : "JohnSmith" + } + }, + "description" : "metadata about an external link" + }, + "User_Public_Profiles_Image_Link" : { + "required" : [ "href" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + }, + "description" : "ImageLink to the users image" + }, + "User_Public_Profiles_Relationships" : { + "required" : [ "followers", "following", "publicPicks", "publicPlaylists" ], + "type" : "object", + "properties" : { + "followers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "following" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "publicPlaylists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "publicPicks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "User_Public_Profiles_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Recommendations_Attributes" : { + "type" : "object", + "description" : "attributes object representing some of the resource's data" + }, + "User_Recommendations_Relationships" : { + "required" : [ "discoveryMixes", "myMixes", "newArrivalMixes" ], + "type" : "object", + "properties" : { + "myMixes" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "discoveryMixes" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "newArrivalMixes" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "User_Recommendations_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/User_Recommendations_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/User_Recommendations_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Users_Attributes" : { + "required" : [ "country", "username" ], + "type" : "object", + "properties" : { + "username" : { + "type" : "string", + "description" : "user name", + "example" : "username" + }, + "country" : { + "type" : "string", + "description" : "ISO 3166-1 alpha-2 country code", + "example" : "US" + }, + "email" : { + "type" : "string", + "description" : "email address", + "example" : "test@test.com" + }, + "emailVerified" : { + "type" : "boolean", + "description" : "Is the email verified", + "example" : true + }, + "firstName" : { + "type" : "string", + "description" : "Users first name", + "example" : "John" + }, + "lastName" : { + "type" : "string", + "description" : "Users last name", + "example" : "Rambo" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Users_Relationships" : { + "required" : [ "entitlements", "publicProfile", "recommendations" ], + "type" : "object", + "properties" : { + "entitlements" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "publicProfile" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "recommendations" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Users_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Users_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Users_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Video_Link_Meta" : { + "required" : [ "height", "width" ], + "type" : "object", + "properties" : { + "width" : { + "type" : "integer", + "description" : "video width (in pixels)", + "format" : "int32", + "example" : 80 + }, + "height" : { + "type" : "integer", + "description" : "video height (in pixels)", + "format" : "int32", + "example" : 80 + } + }, + "description" : "metadata about a video" + }, + "Videos_Attributes" : { + "required" : [ "duration", "explicit", "isrc", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Album item's title", + "example" : "Kill Jay Z" + }, + "version" : { + "type" : "string", + "description" : "Version of the album's item; complements title", + "example" : "Kill Jay Z" + }, + "isrc" : { + "type" : "string", + "description" : "ISRC code", + "example" : "TIDAL2274" + }, + "duration" : { + "type" : "string", + "description" : "Duration expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "releaseDate" : { + "type" : "string", + "description" : "Release date (ISO-8601)", + "format" : "date", + "example" : "2017-06-27" + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether a catalog item consist of any explicit content", + "example" : false + }, + "popularity" : { + "type" : "number", + "description" : "Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines a catalog item availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album item images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to a catalog item, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Videos_Relationships" : { + "required" : [ "albums", "artists", "providers" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Videos_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Videos_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Videos_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Playlists_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Playlists_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + } ] + } + } + } + }, + "Playlists_Owners_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Users_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + } ] + } + } + } + }, + "Playlists_Items_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + } + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"880e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"415\",\n \"code\": \"UNSUPPORTED_MEDIA_TYPE\",\n \"detail\": \"Unsupported request media type: application/json. Expected media type format: application/vnd.api+json\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Bad_Request_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"550e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"400\",\n \"code\": \"INVALID_ENUM_VALUE\",\n \"detail\": \"country code must be in ISO2 format\",\n \"source\": {\n \"parameter\": \"countryCode\"\n },\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n },\n {\n \"id\": \"770e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"400\",\n \"code\": \"VALUE_REGEX_MISMATCH\",\n \"detail\": \"barcode should have a valid EAN-13 or UPC-A format\",\n \"source\": {\n \"parameter\": \"filter[barcodeId]\"\n },\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Internal_Server_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"120e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"500\",\n \"code\": \"INTERNAL_SERVER_ERROR\",\n \"detail\": \"The service encountered an error\",\n \"meta\": {\n \"category\": \"API_ERROR\"\n }\n }\n ]\n}\n" + }, + "Not_Acceptable_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"570e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"406\",\n \"code\": \"NOT_ACCEPTABLE\",\n \"detail\": \"Not acceptable response media type on client: application/xml\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Method_Not_Supported_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"320e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"405\",\n \"code\": \"METHOD_NOT_SUPPORTED\",\n \"detail\": \"The resource doesnt support the requested HTTP method: POST\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Resource_Not_Found_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"770e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"404\",\n \"code\": \"NOT_FOUND\",\n \"detail\": \"Resource for a given 'id' is not found\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Unavailable_For_Legal_Reasons_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"490e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"451\",\n \"code\": \"UNAVAILABLE_FOR_LEGAL_REASONS_RESPONSE\",\n \"detail\": \"Unavailable due to demand from the right-holders to prohibit access to the resource.\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + } + }, + "securitySchemes" : { + "Authorization_Code_PKCE" : { + "type" : "oauth2", + "description" : "Use this grant flow to access users private data e.g. user personal details", + "flows" : { + "authorizationCode" : { + "authorizationUrl" : "https://login.tidal.com/", + "tokenUrl" : "https://auth.tidal.com/v1/", + "scopes" : { + "user.read" : "Read access to a user's account information, such as country and email address.", + "entitlements.read" : "Read access to a user's entitlements", + "playlists.read" : "Read access to a user's playlists", + "recommendations.read" : "Read access to a user's recommendations", + "public-profile.read" : "Read access to a user's public profile", + "public-profile.write" : "Write access to a user's public profile" + } + } + }, + "x-scopes-required-access-tier" : { + "user.read" : "THIRD_PARTY", + "entitlements.read" : "THIRD_PARTY", + "playlists.read" : "THIRD_PARTY", + "recommendations.read" : "THIRD_PARTY", + "public-profile.read" : "INTERNAL", + "public-profile.write" : "INTERNAL" + } + }, + "Client_Credentials" : { + "type" : "oauth2", + "description" : "Use this grant flow to access public user data e.g. public user profile", + "flows" : { + "clientCredentials" : { + "tokenUrl" : "https://auth.tidal.com/v1/", + "scopes" : { } + } + } + } + } + } +} \ No newline at end of file diff --git a/Sources/API/Config/input/tidal-user-v2-openapi-3.0.json b/Sources/API/Config/input/tidal-user-v2-openapi-3.0.json new file mode 100644 index 00000000..65092b31 --- /dev/null +++ b/Sources/API/Config/input/tidal-user-v2-openapi-3.0.json @@ -0,0 +1,12605 @@ +{ + "openapi" : "3.0.1", + "info" : { + "title" : "User v2 - beta", + "description" : "The User API v2 provides a set of JSON:API compatible endpoints for getting the TIDAL users, and more", + "contact" : { + "url" : "https://github.com/orgs/tidal-music/discussions" + }, + "version" : "1.0.0", + "x-url-compatible-spec-id" : "user-v2", + "x-spec-default-endpoint-url-unique-name" : "get-me-v2" + }, + "externalDocs" : { + "description" : "TIDAL Developer Documentation", + "url" : "https://developer.tidal.com/documentation" + }, + "servers" : [ { + "url" : "https://openapi.tidal.com/v2", + "description" : "Production" + } ], + "tags" : [ { + "name" : "Users", + "description" : "Users JSON:API endpoints" + }, { + "name" : "User Entitlements", + "description" : "User Entitlements JSON:API endpoints" + }, { + "name" : "User Recommendations", + "description" : "User recommendations JSON:API endpoints" + }, { + "name" : "User Public Profiles", + "description" : "User Public Profiles JSON:API endpoints" + }, { + "name" : "User Public Profile Picks", + "description" : "User Public Profile Picks JSON:API endpoints" + } ], + "paths" : { + "/userPublicProfilePicks/{id}/relationships/item" : { + "get" : { + "tags" : [ "User Public Profile Picks" ], + "summary" : "Relationship: item (read)", + "description" : "Retrieves a picks item relationship", + "operationId" : "getUserPublicProfilePickItemRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL pick id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "b73h3" + }, { + "name" : "locale", + "in" : "query", + "description" : "Locale language tag (IETF BCP 47 Language Tag)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "en-US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: item", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "item" + } + }, + "example" : "item" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Item_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-userPublicProfilePicks-item", + "json-api-available-relationships" : [ "item" ] + } + }, + "patch" : { + "tags" : [ "User Public Profile Picks" ], + "summary" : "Relationship: item (update)", + "description" : "Updates a picks item relationship, e.g. sets a 'track', 'album' or 'artist' reference.", + "operationId" : "setUserPublicProfilePickItemRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL pick id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "b73h=3" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : null + } + } + } ], + "requestBody" : { + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Update_User_Public_Profile_Picks_Relationship_Document" + } + } + }, + "required" : true + }, + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "202" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "*/*" : { + "schema" : { + "type" : "object" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "profile.write" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "patch-userPublicProfilePicks-item", + "json-api-available-relationships" : [ ] + } + } + }, + "/users" : { + "get" : { + "tags" : [ "Users" ], + "summary" : "Get multiple users by id", + "description" : "Get multiple users by id", + "operationId" : "getUsersByFilters", + "parameters" : [ { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "entitlements" + } + }, + "example" : "entitlements" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on id attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "251380836" + } + }, + "example" : "251380836" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Users_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "user.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id" ], + "url-compatible-unique-name" : "get-users-v2", + "json-api-available-relationships" : [ "entitlements", "publicProfile", "recommendations" ] + } + } + }, + "/users/{id}" : { + "get" : { + "tags" : [ "Users" ], + "summary" : "Get a single user by id", + "description" : "Get a single user by id", + "operationId" : "getUserById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User Id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "entitlements" + } + }, + "example" : "entitlements" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Users_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "user.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-user-v2", + "json-api-available-relationships" : [ "entitlements", "publicProfile", "recommendations" ] + } + } + }, + "/users/{id}/relationships/recommendations" : { + "get" : { + "tags" : [ "Users" ], + "summary" : "Relationship: user recommendations", + "description" : "Get user recommendations", + "operationId" : "getUserRecommendationsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User Id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: recommendations", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "recommendations" + } + }, + "example" : "recommendations" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Users_Recommendations_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-user-userrecommendations-v2", + "json-api-available-relationships" : [ "recommendations" ] + } + } + }, + "/users/{id}/relationships/publicProfile" : { + "get" : { + "tags" : [ "Users" ], + "summary" : "Relationship: public profile", + "description" : "Get user public profile", + "operationId" : "getUserPublicProfileRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User Id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "locale", + "in" : "query", + "description" : "Locale language tag (IETF BCP 47 Language Tag)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "en-US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: publicProfile", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "publicProfile" + } + }, + "example" : "publicProfile" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-user-userprofile-v2", + "json-api-available-relationships" : [ "publicProfile" ] + } + } + }, + "/users/{id}/relationships/entitlements" : { + "get" : { + "tags" : [ "Users" ], + "summary" : "Relationship: entitlements", + "description" : "Get user entitlements relationship", + "operationId" : "getUserEntitlementsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User Id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: entitlements", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "entitlements" + } + }, + "example" : "entitlements" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Entitlements_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-user-userentitlements-v2", + "json-api-available-relationships" : [ "entitlements" ] + } + } + }, + "/users/me" : { + "get" : { + "tags" : [ "Users" ], + "summary" : "Get the current user", + "description" : "Get the current user", + "operationId" : "getMyUser", + "parameters" : [ { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "entitlements" + } + }, + "example" : "entitlements" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Users_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "user.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-me-v2", + "json-api-available-relationships" : [ "entitlements", "publicProfile", "recommendations" ] + } + } + }, + "/userRecommendations" : { + "get" : { + "tags" : [ "User Recommendations" ], + "summary" : "Get recommendations for users in batch", + "description" : "Get recommendations for users in batch", + "operationId" : "getUserRecommendationsByFilters", + "parameters" : [ { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "myMixes" + } + }, + "example" : "myMixes" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "User recommendations id", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "251380836" + } + }, + "example" : "251380836" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Recommendations_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "recommendations.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id" ], + "url-compatible-unique-name" : "get-userrecommendations-batch-v2", + "json-api-available-relationships" : [ "myMixes", "discoveryMixes", "newArrivalMixes" ] + } + } + }, + "/userRecommendations/{id}" : { + "get" : { + "tags" : [ "User Recommendations" ], + "summary" : "Get user recommendations for user", + "description" : "Get user recommendations for user", + "operationId" : "getUserRecommendationsById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User recommendations id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "myMixes" + } + }, + "example" : "myMixes" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Recommendations_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "recommendations.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-userrecommendations-v2", + "json-api-available-relationships" : [ "myMixes", "discoveryMixes", "newArrivalMixes" ] + } + } + }, + "/userRecommendations/{id}/relationships/newArrivalMixes" : { + "get" : { + "tags" : [ "User Recommendations" ], + "summary" : "Relationship: new arrivals mixes", + "description" : "Get new arrival mixes relationship", + "operationId" : "getUserRecommendationsNewArrivalMixesRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User recommendations id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: newArrivalMixes", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "newArrivalMixes" + } + }, + "example" : "newArrivalMixes" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "recommendations.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-userrecommendations-newarrivalmixes-v2", + "json-api-available-relationships" : [ "newArrivalMixes" ] + } + } + }, + "/userRecommendations/{id}/relationships/myMixes" : { + "get" : { + "tags" : [ "User Recommendations" ], + "summary" : "Relationship: my mixes", + "description" : "Get my mixes relationship", + "operationId" : "getUserRecommendationsMyMixesRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User recommendations id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: myMixes", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "myMixes" + } + }, + "example" : "myMixes" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "recommendations.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-userrecommendations-mymixes-v2", + "json-api-available-relationships" : [ "myMixes" ] + } + } + }, + "/userRecommendations/{id}/relationships/discoveryMixes" : { + "get" : { + "tags" : [ "User Recommendations" ], + "summary" : "Relationship: discovery mixes", + "description" : "Get discovery mixes relationship", + "operationId" : "getUserRecommendationsDiscoveryMixesRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User recommendations id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: discoveryMixes", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "discoveryMixes" + } + }, + "example" : "discoveryMixes" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "recommendations.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-userrecommendations-discoverymixes-v2", + "json-api-available-relationships" : [ "discoveryMixes" ] + } + } + }, + "/userRecommendations/me" : { + "get" : { + "tags" : [ "User Recommendations" ], + "summary" : "Get the current users recommendations", + "description" : "Get the current users recommendations", + "operationId" : "getMyUserRecommendations", + "parameters" : [ { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "myMixes" + } + }, + "example" : "myMixes" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Recommendations_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "recommendations.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-myrecommendations-v2", + "json-api-available-relationships" : [ "myMixes", "discoveryMixes", "newArrivalMixes" ] + } + } + }, + "/userPublicProfiles" : { + "get" : { + "tags" : [ "User Public Profiles" ], + "summary" : "Get user public profiles", + "description" : "Reads user public profile details by TIDAL user ids.", + "operationId" : "getUserPublicProfilesByFilters", + "parameters" : [ { + "name" : "locale", + "in" : "query", + "description" : "Locale language tag (IETF BCP 47 Language Tag)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "en-US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "publicPlaylists" + } + }, + "example" : "publicPlaylists" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "TIDAL user id", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "1234567890" + } + }, + "example" : "1234567890" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "User profile retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id" ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-user-public-profiles", + "json-api-available-relationships" : [ "publicPlaylists", "publicPicks", "followers", "following" ] + } + } + }, + "/userPublicProfiles/{id}" : { + "get" : { + "tags" : [ "User Public Profiles" ], + "summary" : "Get user public profile by id", + "description" : "Retrieve user public profile details by TIDAL user id.", + "operationId" : "getUserPublicProfileById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL user id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1234567890 + }, { + "name" : "locale", + "in" : "query", + "description" : "Locale language tag (IETF BCP 47 Language Tag)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "en-US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "publicPlaylists" + } + }, + "example" : "publicPlaylists" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "User profile retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-user-public-profile", + "json-api-available-relationships" : [ "publicPlaylists", "publicPicks", "followers", "following" ] + } + } + }, + "/userPublicProfiles/{id}/relationships/publicPlaylists" : { + "get" : { + "tags" : [ "User Public Profiles" ], + "summary" : "Relationship: playlists", + "description" : "Retrieves user's public playlists.", + "operationId" : "getUserPublicProfilePublicPlaylistsRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL user id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1234567890 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: publicPlaylists", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "publicPlaylists" + } + }, + "example" : "publicPlaylists" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Public playlists retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Playlists_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read", "playlists.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-user-profile-public-playlists", + "json-api-available-relationships" : [ "publicPlaylists" ] + } + } + }, + "/userPublicProfiles/{id}/relationships/publicPicks" : { + "get" : { + "tags" : [ "User Public Profiles" ], + "summary" : "Relationship: picks", + "description" : "Retrieve user's public picks.", + "operationId" : "getUserPublicProfilePublicPicksRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL user id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1234567890 + }, { + "name" : "locale", + "in" : "query", + "description" : "Locale language tag (IETF BCP 47 Language Tag)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "en-US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: publicPicks", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "publicPicks" + } + }, + "example" : "publicPicks" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Public picks retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-user-profile-public-picks", + "json-api-available-relationships" : [ "publicPicks" ] + } + } + }, + "/userPublicProfiles/{id}/relationships/following" : { + "get" : { + "tags" : [ "User Public Profiles" ], + "summary" : "Relationship: following", + "description" : "Retrieve user's public followings", + "operationId" : "getUserPublicProfileFollowingRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL user id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1234567890 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: following", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "following" + } + }, + "example" : "following" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Public following retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Users_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read", "user.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-user-profile-public-following", + "json-api-available-relationships" : [ "following" ] + } + } + }, + "/userPublicProfiles/{id}/relationships/followers" : { + "get" : { + "tags" : [ "User Public Profiles" ], + "summary" : "Relationship: followers", + "description" : "Retrieve user's public followers", + "operationId" : "getUserPublicProfileFollowersRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL user id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 1234567890 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: followers", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "followers" + } + }, + "example" : "followers" + }, { + "name" : "page[cursor]", + "in" : "query", + "description" : "Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified", + "required" : false, + "schema" : { + "type" : "string" + } + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Public followers retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Users_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read", "user.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-user-profile-public-followers", + "json-api-available-relationships" : [ "followers" ] + } + } + }, + "/userPublicProfiles/me" : { + "get" : { + "tags" : [ "User Public Profiles" ], + "summary" : "Get my user profile", + "description" : "Retrieve the logged-in user's public profile details.", + "operationId" : "getMyUserPublicProfile", + "parameters" : [ { + "name" : "locale", + "in" : "query", + "description" : "Locale language tag (IETF BCP 47 Language Tag)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "en-US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "publicPlaylists" + } + }, + "example" : "publicPlaylists" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "User profile retrieved successfully", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-my-user-profile", + "json-api-available-relationships" : [ "publicPlaylists", "publicPicks", "followers", "following" ] + } + } + }, + "/userPublicProfilePicks" : { + "get" : { + "tags" : [ "User Public Profile Picks" ], + "summary" : "Get picks", + "description" : "Retrieves a filtered collection of user's public picks.", + "operationId" : "getUserPublicProfilePicksByFilters", + "parameters" : [ { + "name" : "locale", + "in" : "query", + "description" : "Locale language tag (IETF BCP 47 Language Tag)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "en-US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "item" + } + }, + "example" : "item" + }, { + "name" : "filter[id]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on id attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "123123" + } + }, + "example" : "123123" + }, { + "name" : "filter[userPublicProfile.id]", + "in" : "query", + "description" : "Allows to filter the collection of resources based on userPublicProfile.id attribute value", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "123123" + } + }, + "example" : "123123" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ "id", "userPublicProfile.id" ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-userPublicProfilePicks", + "json-api-available-relationships" : [ "item", "userPublicProfile" ] + } + } + }, + "/userPublicProfilePicks/{id}/relationships/userPublicProfile" : { + "get" : { + "tags" : [ "User Public Profile Picks" ], + "summary" : "Relationship: user public profile", + "description" : "Retrieves a picks owner public profile", + "operationId" : "getUserPublicProfilePickUserPublicProfileRelationship", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "TIDAL pick id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "b73h=3" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: userPublicProfile", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "userPublicProfile" + } + }, + "example" : "userPublicProfile" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Relationship_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-userPublicProfilePicks-userPublicProfile", + "json-api-available-relationships" : [ "userPublicProfile" ] + } + } + }, + "/userPublicProfilePicks/me" : { + "get" : { + "tags" : [ "User Public Profile Picks" ], + "summary" : "Get my picks", + "description" : "Retrieves picks for the logged-in user.", + "operationId" : "getMyUserPublicProfilePicks", + "parameters" : [ { + "name" : "locale", + "in" : "query", + "description" : "Locale language tag (IETF BCP 47 Language Tag)", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : "en-US" + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : "item" + } + }, + "example" : "item" + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Multi_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "public-profile.read" ] + }, { + "Client_Credentials" : [ ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "required-access-tier" : "INTERNAL", + "url-compatible-unique-name" : "get-userPublicProfilePicks-me", + "json-api-available-relationships" : [ "item", "userPublicProfile" ] + } + } + }, + "/userEntitlements/{id}" : { + "get" : { + "tags" : [ "User Entitlements" ], + "summary" : "Get user entitlements for user", + "description" : "Get user entitlements for user", + "operationId" : "getUserEntitlementsById", + "parameters" : [ { + "name" : "id", + "in" : "path", + "description" : "User entitlements id", + "required" : true, + "schema" : { + "type" : "string" + }, + "example" : 251380836 + }, { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : null + } + } + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Entitlements_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "entitlements.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-userentitlement-v2", + "json-api-available-relationships" : [ ] + } + } + }, + "/userEntitlements/me" : { + "get" : { + "tags" : [ "User Entitlements" ], + "summary" : "Get the current users entitlements", + "description" : "Get the current users entitlements", + "operationId" : "getMyUserEntitlements", + "parameters" : [ { + "name" : "include", + "in" : "query", + "description" : "Allows the client to customize which related resources should be returned", + "required" : false, + "schema" : { + "type" : "array", + "items" : { + "type" : "string", + "example" : null + } + } + } ], + "responses" : { + "500" : { + "description" : "Internal Server Error. Something went wrong on the server party.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Internal_Server_Error_Doc" : { + "$ref" : "#/components/examples/Internal_Server_Error_Doc" + } + } + } + } + }, + "415" : { + "description" : "Unsupported Media Type. The API is using content negotiation. Ensure the proper media type is set into Content-Type header.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "$ref" : "#/components/examples/Unsupported_Media_Type_Error_Doc" + } + } + } + } + }, + "404" : { + "description" : "Resource not found. The requested resource is not found.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Resource_Not_Found_Error_Doc" : { + "$ref" : "#/components/examples/Resource_Not_Found_Error_Doc" + } + } + } + } + }, + "406" : { + "description" : "Not acceptable. The server doesn't support any of the requested by client acceptable content types.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Not_Acceptable_Error_Doc" : { + "$ref" : "#/components/examples/Not_Acceptable_Error_Doc" + } + } + } + } + }, + "405" : { + "description" : "Method not supported. Ensure a proper HTTP method for an HTTP request is used.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Method_Not_Supported_Error_Doc" : { + "$ref" : "#/components/examples/Method_Not_Supported_Error_Doc" + } + } + } + } + }, + "400" : { + "description" : "Bad request on client party. Ensure the proper HTTP request is sent (query parameters, request body, etc.).", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/Error_Document" + }, + "examples" : { + "Bad_Request_Error_Doc" : { + "$ref" : "#/components/examples/Bad_Request_Error_Doc" + } + } + } + } + }, + "200" : { + "description" : "Successfully executed request.", + "headers" : { + "X-RateLimit-Remaining" : { + "description" : "Number of tokens currently remaining. Refer to X-RateLimit-Replenish-Rate header for replenishment information.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Burst-Capacity" : { + "description" : "Initial number of tokens, and max number of tokens that can be replenished.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "20" + }, + "X-RateLimit-Replenish-Rate" : { + "description" : "Number of tokens replenished per second.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + }, + "X-RateLimit-Requested-Tokens" : { + "description" : "Request cost in tokens.", + "required" : true, + "schema" : { + "type" : "integer", + "format" : "int32" + }, + "example" : "5" + } + }, + "content" : { + "application/vnd.api+json" : { + "schema" : { + "$ref" : "#/components/schemas/User_Entitlements_Single_Data_Document" + } + } + } + } + }, + "security" : [ { + "Authorization_Code_PKCE" : [ "entitlements.read" ] + } ], + "x-endpoint-properties" : { + "json-api-available-filters" : [ ], + "url-compatible-unique-name" : "get-myuserentitlement-v2", + "json-api-available-relationships" : [ ] + } + } + } + }, + "components" : { + "schemas" : { + "Error_Document" : { + "type" : "object", + "properties" : { + "errors" : { + "type" : "array", + "description" : "array of error objects", + "items" : { + "$ref" : "#/components/schemas/Error_Object" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + } + }, + "Error_Object" : { + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "unique identifier for this particular occurrence of the problem" + }, + "status" : { + "type" : "string", + "description" : "HTTP status code applicable to this problem" + }, + "code" : { + "type" : "string", + "description" : "application-specific error code" + }, + "detail" : { + "type" : "string", + "description" : "human-readable explanation specific to this occurrence of the problem" + }, + "source" : { + "$ref" : "#/components/schemas/Error_Object_Source" + } + } + }, + "Error_Object_Source" : { + "type" : "object", + "properties" : { + "pointer" : { + "type" : "string", + "description" : "a JSON Pointer [RFC6901] to the value in the request document that caused the error", + "example" : "/data/attributes/title" + }, + "parameter" : { + "type" : "string", + "description" : "string indicating which URI query parameter caused the error.", + "example" : "countryCode" + }, + "header" : { + "type" : "string", + "description" : "string indicating the name of a single request header which caused the error", + "example" : "X-some-custom-header" + } + }, + "description" : "object containing references to the primary source of the error" + }, + "Links" : { + "required" : [ "self" ], + "type" : "object", + "properties" : { + "self" : { + "type" : "string", + "description" : "the link that generated the current response document", + "example" : "/artists/xyz/relationships/tracks" + }, + "next" : { + "type" : "string", + "description" : "the next page of data (pagination)", + "example" : "/artists/xyz/relationships/tracks?page[cursor]=zyx" + } + }, + "description" : "links object" + }, + "Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Update_User_Public_Profile_Picks_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + } + }, + "External_Link_Meta" : { + "required" : [ "type" ], + "type" : "object", + "properties" : { + "type" : { + "type" : "string", + "description" : "external link type", + "example" : "TIDAL_SHARING", + "enum" : [ "TIDAL_SHARING", "TIDAL_AUTOPLAY_ANDROID", "TIDAL_AUTOPLAY_IOS", "TIDAL_AUTOPLAY_WEB", "TWITTER", "FACEBOOK", "INSTAGRAM", "TIKTOK", "SNAPCHAT", "HOMEPAGE" ] + } + }, + "description" : "metadata about an external link" + }, + "Image_Link_Meta" : { + "required" : [ "height", "width" ], + "type" : "object", + "properties" : { + "width" : { + "type" : "integer", + "description" : "image width (in pixels)", + "format" : "int32", + "example" : 80 + }, + "height" : { + "type" : "integer", + "description" : "image height (in pixels)", + "format" : "int32", + "example" : 80 + } + }, + "description" : "metadata about an image" + }, + "Multi_Data_Relationship_Doc" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Playlist owners relationship" + }, + "Playlists_Attributes" : { + "required" : [ "bounded", "createdAt", "externalLinks", "imageLinks", "lastModifiedAt", "name", "playlistType", "privacy" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Playlist name", + "example" : "My Playlist" + }, + "description" : { + "type" : "string", + "description" : "Playlist description", + "example" : "All the good details about what is inside this playlist" + }, + "bounded" : { + "type" : "boolean", + "description" : "Indicates if the playlist has a duration and set number of tracks", + "example" : true + }, + "duration" : { + "type" : "string", + "description" : "Duration of the playlist expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "numberOfItems" : { + "type" : "integer", + "description" : "Number of items in the playlist", + "format" : "int32", + "example" : 5 + }, + "externalLinks" : { + "type" : "array", + "description" : "Sharing links to the playlist", + "example" : true, + "items" : { + "$ref" : "#/components/schemas/Playlists_External_Link" + } + }, + "createdAt" : { + "type" : "string", + "description" : "Datetime of playlist creation (ISO 8601)", + "format" : "date-time" + }, + "lastModifiedAt" : { + "type" : "string", + "description" : "Datetime of last modification of the playlist (ISO 8601)", + "format" : "date-time" + }, + "privacy" : { + "type" : "string", + "description" : "Privacy setting of the playlist", + "example" : "PUBLIC" + }, + "playlistType" : { + "type" : "string", + "description" : "The type of the playlist", + "example" : "EDITORIAL" + }, + "imageLinks" : { + "type" : "array", + "description" : "Images associated with the playlist", + "example" : true, + "items" : { + "$ref" : "#/components/schemas/Playlists_Image_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Playlists_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/External_Link_Meta" + } + }, + "description" : "Sharing links to the playlist", + "example" : true + }, + "Playlists_Image_Link" : { + "required" : [ "href" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + }, + "description" : "Images associated with the playlist", + "example" : true + }, + "Playlists_Relationships" : { + "required" : [ "items", "owners" ], + "type" : "object", + "properties" : { + "items" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "owners" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Playlists_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Playlists_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Playlists_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Prompt_Colors" : { + "required" : [ "primary", "secondary" ], + "type" : "object", + "properties" : { + "primary" : { + "type" : "string", + "description" : "Primary color to visually render the pick", + "example" : "#FF0000" + }, + "secondary" : { + "type" : "string", + "description" : "Secondary color to visually render the pick", + "example" : "#00FF00" + } + }, + "description" : "Primary and Secondary color to visually render the pick" + }, + "Singleton_Data_Relationship_Doc" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Pick's owning user public profile relationship" + }, + "User_Entitlements_Attributes" : { + "required" : [ "entitlements" ], + "type" : "object", + "properties" : { + "entitlements" : { + "type" : "array", + "description" : "entitlements for user", + "items" : { + "type" : "string", + "description" : "entitlements for user", + "enum" : [ "MUSIC", "DJ" ] + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "User_Entitlements_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/User_Entitlements_Attributes" + }, + "relationships" : { + "type" : "object", + "description" : "relationships object describing relationships between the resource and other resources" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Public_Profile_Picks_Attributes" : { + "required" : [ "colors", "description", "supportedContentType", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Pick title", + "example" : "My favorite track on repeat" + }, + "description" : { + "type" : "string", + "description" : "Description of pick", + "example" : "This is the track I listen to when I need to focus" + }, + "supportedContentType" : { + "type" : "string", + "description" : "CatalogueResourceType for supported item for the pick", + "example" : "TRACK", + "enum" : [ "TRACKS", "VIDEOS", "ALBUMS", "ARTISTS", "PROVIDERS" ] + }, + "colors" : { + "$ref" : "#/components/schemas/Prompt_Colors" + }, + "lastModifiedAt" : { + "type" : "string", + "description" : "Date of last modification of the pick (ISO 8601)", + "format" : "date-time", + "example" : "2021-08-31T12:00:00Z" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "User_Public_Profile_Picks_Relationships" : { + "required" : [ "item", "userPublicProfile" ], + "type" : "object", + "properties" : { + "item" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "userPublicProfile" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "User_Public_Profile_Picks_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Public_Profiles_Attributes" : { + "required" : [ "color" ], + "type" : "object", + "properties" : { + "profileName" : { + "type" : "string", + "description" : "Public Name of the user profile", + "example" : "JohnSmith" + }, + "picture" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Image_Link" + }, + "color" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Color information for the user profile when no image is available", + "example" : "326650" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "ExternalLinks for the user's profile", + "items" : { + "$ref" : "#/components/schemas/User_Public_Profiles_External_Link" + } + }, + "numberOfFollowers" : { + "type" : "integer", + "description" : "Number of followers for the user", + "format" : "int32", + "example" : 32 + }, + "numberOfFollows" : { + "type" : "integer", + "description" : "Number of users the user follows", + "format" : "int32", + "example" : 32 + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "User_Public_Profiles_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/User_Public_Profiles_External_Link_Meta" + } + } + }, + "User_Public_Profiles_External_Link_Meta" : { + "required" : [ "handle", "type" ], + "type" : "object", + "properties" : { + "type" : { + "type" : "string", + "description" : "external link type", + "example" : "TIDAL_SHARING", + "enum" : [ "TIDAL_SHARING", "TIDAL_AUTOPLAY_ANDROID", "TIDAL_AUTOPLAY_IOS", "TIDAL_AUTOPLAY_WEB", "TWITTER", "FACEBOOK", "INSTAGRAM", "TIKTOK", "SNAPCHAT", "HOMEPAGE" ] + }, + "handle" : { + "type" : "string", + "description" : "external link handle", + "example" : "JohnSmith" + } + }, + "description" : "metadata about an external link" + }, + "User_Public_Profiles_Image_Link" : { + "required" : [ "href" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + }, + "description" : "ImageLink to the users image" + }, + "User_Public_Profiles_Relationships" : { + "required" : [ "followers", "following", "publicPicks", "publicPlaylists" ], + "type" : "object", + "properties" : { + "followers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "following" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "publicPlaylists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "publicPicks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "User_Public_Profiles_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Recommendations_Attributes" : { + "type" : "object", + "description" : "attributes object representing some of the resource's data" + }, + "User_Recommendations_Relationships" : { + "required" : [ "discoveryMixes", "myMixes", "newArrivalMixes" ], + "type" : "object", + "properties" : { + "myMixes" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "discoveryMixes" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "newArrivalMixes" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "User_Recommendations_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/User_Recommendations_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/User_Recommendations_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Users_Attributes" : { + "required" : [ "country", "username" ], + "type" : "object", + "properties" : { + "username" : { + "type" : "string", + "description" : "user name", + "example" : "username" + }, + "country" : { + "type" : "string", + "description" : "ISO 3166-1 alpha-2 country code", + "example" : "US" + }, + "email" : { + "type" : "string", + "description" : "email address", + "example" : "test@test.com" + }, + "emailVerified" : { + "type" : "boolean", + "description" : "Is the email verified", + "example" : true + }, + "firstName" : { + "type" : "string", + "description" : "Users first name", + "example" : "John" + }, + "lastName" : { + "type" : "string", + "description" : "Users last name", + "example" : "Rambo" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Users_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/Users_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Users_Relationships" : { + "required" : [ "entitlements", "publicProfile", "recommendations" ], + "type" : "object", + "properties" : { + "entitlements" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "publicProfile" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + }, + "recommendations" : { + "$ref" : "#/components/schemas/Singleton_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Users_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Users_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Users_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Users_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Users_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Users_Recommendations_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "User_Public_Profiles_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Resource" + } ] + } + } + } + }, + "User_Entitlements_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + } ] + } + } + } + }, + "Catalogue_Item_External_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to something that is related to a resource", + "example" : "https://tidal.com/browse/artist/1566" + }, + "meta" : { + "$ref" : "#/components/schemas/External_Link_Meta" + } + } + }, + "Catalogue_Item_Image_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to an image", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.jpg" + }, + "meta" : { + "$ref" : "#/components/schemas/Image_Link_Meta" + } + } + }, + "Tracks_Attributes" : { + "required" : [ "duration", "explicit", "isrc", "mediaTags", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Album item's title", + "example" : "Kill Jay Z" + }, + "version" : { + "type" : "string", + "description" : "Version of the album's item; complements title", + "example" : "Kill Jay Z" + }, + "isrc" : { + "type" : "string", + "description" : "ISRC code", + "example" : "TIDAL2274" + }, + "duration" : { + "type" : "string", + "description" : "Duration expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether a catalog item consist of any explicit content", + "example" : false + }, + "popularity" : { + "type" : "number", + "description" : "Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines a catalog item availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "mediaTags" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Media metadata tags", + "example" : "LOSSLESS" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to a catalog item, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Tracks_Relationships" : { + "required" : [ "albums", "artists", "providers", "radio", "similarTracks" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "similarTracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "radio" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Tracks_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Tracks_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Tracks_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Recommendations_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Videos_Attributes" : { + "required" : [ "duration", "explicit", "isrc", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Album item's title", + "example" : "Kill Jay Z" + }, + "version" : { + "type" : "string", + "description" : "Version of the album's item; complements title", + "example" : "Kill Jay Z" + }, + "isrc" : { + "type" : "string", + "description" : "ISRC code", + "example" : "TIDAL2274" + }, + "duration" : { + "type" : "string", + "description" : "Duration expressed in accordance with ISO 8601", + "example" : "P30M5S" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "releaseDate" : { + "type" : "string", + "description" : "Release date (ISO-8601)", + "format" : "date", + "example" : "2017-06-27" + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether a catalog item consist of any explicit content", + "example" : false + }, + "popularity" : { + "type" : "number", + "description" : "Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines a catalog item availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album item images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to a catalog item, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Videos_Relationships" : { + "required" : [ "albums", "artists", "providers" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Videos_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Videos_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Videos_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Recommendations_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Playlists_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "Albums_Attributes" : { + "required" : [ "barcodeId", "duration", "explicit", "mediaTags", "numberOfItems", "numberOfVolumes", "popularity", "title" ], + "type" : "object", + "properties" : { + "title" : { + "type" : "string", + "description" : "Original title", + "example" : "4:44" + }, + "barcodeId" : { + "type" : "string", + "description" : "Barcode id (EAN-13 or UPC-A)", + "example" : "00854242007552" + }, + "numberOfVolumes" : { + "type" : "integer", + "description" : "Number of volumes", + "format" : "int32", + "example" : 1 + }, + "numberOfItems" : { + "type" : "integer", + "description" : "Number of album items", + "format" : "int32", + "example" : 13 + }, + "duration" : { + "type" : "string", + "description" : "Duration (ISO-8601)", + "example" : "P41M5S" + }, + "explicit" : { + "type" : "boolean", + "description" : "Indicates whether an album consist of any explicit content", + "example" : true + }, + "releaseDate" : { + "type" : "string", + "description" : "Release date (ISO-8601)", + "format" : "date", + "example" : "2017-06-30" + }, + "copyright" : { + "type" : "string", + "description" : "Copyright information", + "example" : "(p)(c) 2017 S. CARTER ENTERPRISES, LLC. MARKETED BY ROC NATION & DISTRIBUTED BY ROC NATION/UMG RECORDINGS INC." + }, + "popularity" : { + "type" : "number", + "description" : "Album popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "availability" : { + "type" : "array", + "description" : "Defines an album availability e.g. for streaming, DJs, stems", + "items" : { + "type" : "string", + "enum" : [ "STREAM", "DJ", "STEM" ] + } + }, + "mediaTags" : { + "type" : "array", + "items" : { + "type" : "string", + "description" : "Media metadata tags", + "example" : "LOSSLESS" + } + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album cover images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "videoLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an album cover videos", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Video_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to an album resource, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Albums_Item_Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + }, + "meta" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier_Meta" + } + } + }, + "Albums_Item_Resource_Identifier_Meta" : { + "required" : [ "trackNumber", "volumeNumber" ], + "type" : "object", + "properties" : { + "volumeNumber" : { + "type" : "integer", + "description" : "volume number", + "format" : "int32", + "example" : 1 + }, + "trackNumber" : { + "type" : "integer", + "description" : "track number", + "format" : "int32", + "example" : 4 + } + } + }, + "Albums_Items_Relationship" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Albums_Item_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Album items (tracks/videos) relationship" + }, + "Albums_Relationships" : { + "required" : [ "artists", "items", "providers", "similarAlbums" ], + "type" : "object", + "properties" : { + "artists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "items" : { + "$ref" : "#/components/schemas/Albums_Items_Relationship" + }, + "similarAlbums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "providers" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Albums_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Albums_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Albums_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Artists_Attributes" : { + "required" : [ "name", "popularity" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Artist name", + "example" : "JAY Z" + }, + "popularity" : { + "type" : "number", + "description" : "Artist popularity (ranged in 0.00 ... 1.00). Conditionally visible", + "format" : "double", + "example" : 0.56 + }, + "imageLinks" : { + "type" : "array", + "description" : "Represents available links to, and metadata about, an artist images", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_Image_Link" + } + }, + "externalLinks" : { + "type" : "array", + "description" : "Represents available links to something that is related to an artist resource, but external to the TIDAL API", + "items" : { + "$ref" : "#/components/schemas/Catalogue_Item_External_Link" + } + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Artists_Relationships" : { + "required" : [ "albums", "radio", "similarArtists", "trackProviders", "tracks", "videos" ], + "type" : "object", + "properties" : { + "albums" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "tracks" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "videos" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "similarArtists" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + }, + "trackProviders" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Relationship" + }, + "radio" : { + "$ref" : "#/components/schemas/Multi_Data_Relationship_Doc" + } + }, + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Artists_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Artists_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Artists_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "Artists_Track_Providers_Relationship" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "items" : { + "type" : "array", + "items" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier" + } + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + }, + "description" : "Providers that have released tracks for this artist" + }, + "Artists_Track_Providers_Resource_Identifier" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + }, + "meta" : { + "$ref" : "#/components/schemas/Artists_Track_Providers_Resource_Identifier_Meta" + } + } + }, + "Artists_Track_Providers_Resource_Identifier_Meta" : { + "required" : [ "numberOfTracks" ], + "type" : "object", + "properties" : { + "numberOfTracks" : { + "type" : "integer", + "description" : "total number of tracks released together with the provider", + "format" : "int64", + "example" : 14 + } + } + }, + "Catalogue_Item_Video_Link" : { + "required" : [ "href", "meta" ], + "type" : "object", + "properties" : { + "href" : { + "type" : "string", + "description" : "link to a video", + "example" : "https://resources.tidal.com/images/717dfdae/beb0/4aea/a553/a70064c30386/80x80.mp4" + }, + "meta" : { + "$ref" : "#/components/schemas/Video_Link_Meta" + } + } + }, + "User_Public_Profiles_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + }, { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + } ] + } + } + } + }, + "Video_Link_Meta" : { + "required" : [ "height", "width" ], + "type" : "object", + "properties" : { + "width" : { + "type" : "integer", + "description" : "video width (in pixels)", + "format" : "int32", + "example" : 80 + }, + "height" : { + "type" : "integer", + "description" : "video height (in pixels)", + "format" : "int32", + "example" : 80 + } + }, + "description" : "metadata about a video" + }, + "User_Public_Profiles_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + }, { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + } ] + } + } + } + }, + "User_Public_Profile_Picks_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Resource" + }, { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + } ] + } + } + } + }, + "Users_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of relationship resource linkages", + "items" : { + "$ref" : "#/components/schemas/Resource_Identifier" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Users_Resource" + }, { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/User_Recommendations_Resource" + } ] + } + } + } + }, + "Providers_Attributes" : { + "required" : [ "name" ], + "type" : "object", + "properties" : { + "name" : { + "type" : "string", + "description" : "Provider name. Conditionally visible.", + "example" : "Columbia/Legacy" + } + }, + "description" : "attributes object representing some of the resource's data" + }, + "Providers_Relationships" : { + "type" : "object", + "description" : "relationships object describing relationships between the resource and other resources" + }, + "Providers_Resource" : { + "required" : [ "id", "type" ], + "type" : "object", + "properties" : { + "attributes" : { + "$ref" : "#/components/schemas/Providers_Attributes" + }, + "relationships" : { + "$ref" : "#/components/schemas/Providers_Relationships" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "id" : { + "type" : "string", + "description" : "resource unique identifier", + "example" : "12345" + }, + "type" : { + "type" : "string", + "description" : "resource unique type", + "example" : "tracks" + } + } + }, + "User_Public_Profile_Picks_Multi_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "type" : "array", + "description" : "array of primary resource data", + "items" : { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Resource" + } + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profiles_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + }, { + "$ref" : "#/components/schemas/User_Public_Profile_Picks_Resource" + }, { + "$ref" : "#/components/schemas/Users_Resource" + } ] + } + } + } + }, + "User_Public_Profile_Picks_Item_Relationship_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/Resource_Identifier" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + }, + "included" : { + "type" : "array", + "items" : { + "type" : "object", + "oneOf" : [ { + "$ref" : "#/components/schemas/Tracks_Resource" + }, { + "$ref" : "#/components/schemas/Artists_Resource" + }, { + "$ref" : "#/components/schemas/Albums_Resource" + }, { + "$ref" : "#/components/schemas/Videos_Resource" + }, { + "$ref" : "#/components/schemas/Providers_Resource" + }, { + "$ref" : "#/components/schemas/Playlists_Resource" + } ] + } + } + } + }, + "User_Entitlements_Single_Data_Document" : { + "type" : "object", + "properties" : { + "data" : { + "$ref" : "#/components/schemas/User_Entitlements_Resource" + }, + "links" : { + "$ref" : "#/components/schemas/Links" + } + } + } + }, + "examples" : { + "Unsupported_Media_Type_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"880e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"415\",\n \"code\": \"UNSUPPORTED_MEDIA_TYPE\",\n \"detail\": \"Unsupported request media type: application/json. Expected media type format: application/vnd.api+json\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Bad_Request_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"550e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"400\",\n \"code\": \"INVALID_ENUM_VALUE\",\n \"detail\": \"country code must be in ISO2 format\",\n \"source\": {\n \"parameter\": \"countryCode\"\n },\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n },\n {\n \"id\": \"770e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"400\",\n \"code\": \"VALUE_REGEX_MISMATCH\",\n \"detail\": \"barcode should have a valid EAN-13 or UPC-A format\",\n \"source\": {\n \"parameter\": \"filter[barcodeId]\"\n },\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Internal_Server_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"120e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"500\",\n \"code\": \"INTERNAL_SERVER_ERROR\",\n \"detail\": \"The service encountered an error\",\n \"meta\": {\n \"category\": \"API_ERROR\"\n }\n }\n ]\n}\n" + }, + "Not_Acceptable_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"570e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"406\",\n \"code\": \"NOT_ACCEPTABLE\",\n \"detail\": \"Not acceptable response media type on client: application/xml\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Method_Not_Supported_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"320e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"405\",\n \"code\": \"METHOD_NOT_SUPPORTED\",\n \"detail\": \"The resource doesnt support the requested HTTP method: POST\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Resource_Not_Found_Error_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"770e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"404\",\n \"code\": \"NOT_FOUND\",\n \"detail\": \"Resource for a given 'id' is not found\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + }, + "Unavailable_For_Legal_Reasons_Doc" : { + "value" : "{\n \"errors\": [\n {\n \"id\": \"490e8400-e29b-41d4-a716-446655440000\",\n \"status\": \"451\",\n \"code\": \"UNAVAILABLE_FOR_LEGAL_REASONS_RESPONSE\",\n \"detail\": \"Unavailable due to demand from the right-holders to prohibit access to the resource.\",\n \"meta\": {\n \"category\": \"INVALID_REQUEST_ERROR\"\n }\n }\n ]\n}\n" + } + }, + "securitySchemes" : { + "Authorization_Code_PKCE" : { + "type" : "oauth2", + "description" : "Use this grant flow to access users personalized TIDAL data.", + "flows" : { + "authorizationCode" : { + "authorizationUrl" : "https://login.tidal.com/", + "tokenUrl" : "https://auth.tidal.com/v1/", + "scopes" : { + "user.read" : "Read access to a user's account information, such as country and email address.", + "entitlements.read" : "Read access to a user's entitlements", + "playlists.read" : "Read access to a user's playlists", + "recommendations.read" : "Read access to a user's recommendations", + "public-profile.read" : "Read access to a user's public profile", + "public-profile.write" : "Write access to a user's public profile" + } + } + }, + "x-scopes-required-access-tier" : { + "user.read" : "THIRD_PARTY", + "entitlements.read" : "THIRD_PARTY", + "playlists.read" : "THIRD_PARTY", + "recommendations.read" : "THIRD_PARTY", + "public-profile.read" : "INTERNAL", + "public-profile.write" : "INTERNAL" + } + }, + "Client_Credentials" : { + "type" : "oauth2", + "description" : "Use this grant flow to access non-personalized TIDAL data.", + "flows" : { + "clientCredentials" : { + "tokenUrl" : "https://auth.tidal.com/v1/", + "scopes" : { } + } + } + } + } + } +} \ No newline at end of file diff --git a/Sources/API/Config/openapi-config.yml b/Sources/API/Config/openapi-config.yml new file mode 100644 index 00000000..09556e9d --- /dev/null +++ b/Sources/API/Config/openapi-config.yml @@ -0,0 +1,11 @@ +additionalProperties: + useJsonEncodable: false + responseAs: AsyncAwait + +embeddedTemplateDir: ./openAPI_config/custom_template + +templateDir: ./openAPI_config/custom_template +files: + TidalAPI.mustache: + templateType: API + destinationFilename: Tidal.swift diff --git a/Sources/API/Utils/APIError.swift b/Sources/API/Utils/APIError.swift new file mode 100644 index 00000000..891d1fa2 --- /dev/null +++ b/Sources/API/Utils/APIError.swift @@ -0,0 +1,61 @@ +import Foundation + +public struct APIError: LocalizedError, Equatable { + let fileID: String + let line: UInt + let column: UInt + public let message: String + public let url: String + public var statusCode: Int? + public var subStatus: Int? + + public init( + fileID: StaticString = #fileID, + line: UInt = #line, + column: UInt = #column, + message: String, + url: String, + statusCode: Int? = nil, + subStatus: Int? = nil + ) { + self.fileID = String(describing: fileID) + self.line = line + self.column = column + self.message = message + self.url = url + self.statusCode = statusCode + self.subStatus = subStatus + } + + public var errorDescription: String { + """ + API Error: \(String(describing: statusCode)) + URL: \(url) + SubStatus: \(String(describing: subStatus)) + """ + } +} + +extension APIError { + init( + fileID: StaticString = #fileID, + line: UInt = #line, + column: UInt = #column, + error: any Error, + url: String, + statusCode: Int? = nil, + subStatus: Int? = nil + ) { + var errorMessage = "" + dump(error, to: &errorMessage) + self.init( + fileID: fileID, + line: line, + column: column, + message: errorMessage, + url: url, + statusCode: statusCode, + subStatus: subStatus + ) + } +} diff --git a/Sources/API/Utils/OpenAPIClientAPI+Auth.swift b/Sources/API/Utils/OpenAPIClientAPI+Auth.swift new file mode 100644 index 00000000..dbd8bff1 --- /dev/null +++ b/Sources/API/Utils/OpenAPIClientAPI+Auth.swift @@ -0,0 +1,5 @@ +import Auth + +extension OpenAPIClientAPI { + public static var credentialsProvider: (any CredentialsProvider)? +} diff --git a/Sources/API/Utils/RequestHelper.swift b/Sources/API/Utils/RequestHelper.swift new file mode 100644 index 00000000..6c0c75d4 --- /dev/null +++ b/Sources/API/Utils/RequestHelper.swift @@ -0,0 +1,114 @@ +import Auth +import Common +import Foundation + +enum RequestHelper { + private static var retries: [String: Int?] = [:] + + static func createRequest( + requestBuilder: @escaping () async throws -> RequestBuilder + ) async throws -> T { + guard let credentialsProvider = OpenAPIClientAPI.credentialsProvider else { + throw APIError(message: "NO_CREDENTIALS_PROVIDER", url: "Not available") + } + + let credentials = try await credentialsProvider.getCredentials() + let requestBuilder = try await requestBuilder() + let requestURL = requestBuilder.URLString + guard + let token = credentials.token, + OpenAPIClientAPI.credentialsProvider?.isUserLoggedIn == true + else { + throw APIError( + message: "NO_TOKEN", + url: requestURL + ) + } + + let request = requestBuilder + .addHeader(name: "Authorization", value: "Bearer \(token)") + + do { + let result = try await request.execute().body + // Clear the retry count for the URL on success + retries[requestURL] = nil + return result + } catch let error as ErrorResponse { + return try await handleErrorResult( + error, + urlAttachedToError: requestURL, + requestBuilder: { requestBuilder } + ) + } catch { + throw TidalError(code: error.localizedDescription) + } + } + + static func handleErrorResult( + _ error: ErrorResponse, + urlAttachedToError url: String, + requestBuilder: @escaping () async throws -> RequestBuilder + ) async throws -> T { + func getHttpSubStatus(data: Data?) -> Int? { + guard let data = data else { + return nil + } + + do { + if let parsedObject = try JSONSerialization.jsonObject(with: data, options: .mutableContainers) as? [String: Any], + let subStatus = parsedObject["subStatus"] as? Int { + return subStatus + } + } catch { + return nil + } + return nil + } + + let currentRetryCount = retries[url] ?? 0 // Default to 0 if nil + + guard let provider = OpenAPIClientAPI.credentialsProvider else { + throw APIError(message: "NO_CREDENTIALS_PROVIDER", url: url) + } + + switch error { + case .error(let statusCode, let data, _, _): + if statusCode == 401 { + let subStatus = getHttpSubStatus(data: data) + + do { + _ = try await provider.getCredentials(apiErrorSubStatus: subStatus.flatMap(String.init)) + } catch { + if subStatus != nil { + throw APIError( + message: "Failed to get credentials", + url: url, + statusCode: statusCode, + subStatus: subStatus + ) + } else { + throw APIError(error: error, url: url) + } + } + + if subStatus != nil, OpenAPIClientAPI.credentialsProvider?.isUserLoggedIn == false { + throw APIError( + message: "User is not logged in", + url: url, + statusCode: statusCode, + subStatus: subStatus + ) + } + + // Retry the async operation if the retry count is 0 + if currentRetryCount == 0 { + retries[url] = 1 // Increment retry count to 1 + let result = try await createRequest(requestBuilder: requestBuilder) + return result + } + } + } + + throw APIError(error: error, url: url) // Propagate the error if not handled or retried + } +} From 74f39de2dcb286992fecf54bf131443c71f75630 Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Fri, 18 Oct 2024 18:15:06 +0200 Subject: [PATCH 03/11] removed HelloWorld.swift --- Sources/API/HelloWorld.swift | 11 ----------- 1 file changed, 11 deletions(-) delete mode 100644 Sources/API/HelloWorld.swift diff --git a/Sources/API/HelloWorld.swift b/Sources/API/HelloWorld.swift deleted file mode 100644 index de9e1d5f..00000000 --- a/Sources/API/HelloWorld.swift +++ /dev/null @@ -1,11 +0,0 @@ -import Foundation - -public struct HelloWorld { - public let text = "Hello, World!" - - public init() {} - - func sayHello() -> String { - text - } -} From 019b3a9f2a3acca0fcc7cdeb69c42e546b12cb96 Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Fri, 18 Oct 2024 18:16:41 +0200 Subject: [PATCH 04/11] added Readme stub for API module --- Sources/API/README.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 Sources/API/README.md diff --git a/Sources/API/README.md b/Sources/API/README.md new file mode 100644 index 00000000..cad2bfb8 --- /dev/null +++ b/Sources/API/README.md @@ -0,0 +1,22 @@ +# API +Add here one or two sentences what this library is. + +--- +## Prerequisites +This is a section about things you need to use the software and how to install them. + +--- +## Installation +Add installation instructions here. + +--- +## Usage +Use this space to show useful examples of how this module can be used. Additional screenshots, code examples and demos work well in this space. You may also link to more resources. + +--- +## Contributing +How can others contribute to this? + +--- +## License +Add license information for this open source project. From 234d2ebf01aac4d55bf26d25486917b186402636 Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Fri, 18 Oct 2024 18:33:23 +0200 Subject: [PATCH 05/11] added API generation script --- Sources/API/generate_and_clean.sh | 44 +++++++++++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100755 Sources/API/generate_and_clean.sh diff --git a/Sources/API/generate_and_clean.sh b/Sources/API/generate_and_clean.sh new file mode 100755 index 00000000..c2095fbb --- /dev/null +++ b/Sources/API/generate_and_clean.sh @@ -0,0 +1,44 @@ +#!/bin/bash + +# Define the input and output directories +input_dir="Config/input" +output_dir="Generated" + +# Step 1: Clear the contents of the input directory +rm -rf "$input_dir"/* +mkdir -p "$input_dir" + +# Step 2: Download the JSON files and save them in the input directory +echo "Dowloading API specs from developer.tidal.com" +curl -o "$input_dir/tidal-catalog-v2-openapi-3.0.json" https://developer.tidal.com/apiref/api-specifications/api-public-catalogue-jsonapi/tidal-catalog-v2-openapi-3.0.json +curl -o "$input_dir/tidal-search-v2-openapi-3.0.json" https://developer.tidal.com/apiref/api-specifications/api-public-search-jsonapi/tidal-search-v2-openapi-3.0.json +curl -o "$input_dir/tidal-user-v2-openapi-3.0.json" https://developer.tidal.com/apiref/api-specifications/api-public-user-jsonapi/tidal-user-v2-openapi-3.0.json +curl -o "$input_dir/tidal-user-content-openapi-3.0.json" https://developer.tidal.com/apiref/api-specifications/api-public-user-content/tidal-user-content-openapi-3.0.json + +# Step 3: Clear the contents of the output directory +echo "Clear the contents of the output directory" +rm -rf "$output_dir"/* +mkdir -p "$output_dir" + +# Step 4: Loop through all JSON files in the input folder +for json_file in "$input_dir"/*.json; do + # Run the OpenAPI generator for each JSON file + openapi-generator generate \ + -i "$json_file" \ + -g swift5 \ + -o "$output_dir" \ + -c Config/openapi-config.yml \ + + # Step 5: Remove the unwanted files + rm -f "$output_dir/Package.swift" + rm -f "$output_dir/Cartfile" + rm -f "$output_dir/git_push.sh" + rm -f "$output_dir/project.yml" + rm -f "$output_dir/OpenAPIClient.podspec" + rm -f "$output_dir/.swiftformat" + rm -f "$output_dir/.gitignore" + rm -f "$output_dir/.openapi-generator" + rm -f "$output_dir/.openapi-generator-ignore" + + echo "Generation and cleanup completed successfully for $(basename "$json_file")." +done From 56cde4c81ff8d004bc0b2e21de51951b827e63a1 Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Fri, 18 Oct 2024 18:50:03 +0200 Subject: [PATCH 06/11] adjusted config --- Sources/API/Config/openapi-config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Sources/API/Config/openapi-config.yml b/Sources/API/Config/openapi-config.yml index 09556e9d..cd6b8ef6 100644 --- a/Sources/API/Config/openapi-config.yml +++ b/Sources/API/Config/openapi-config.yml @@ -2,9 +2,9 @@ additionalProperties: useJsonEncodable: false responseAs: AsyncAwait -embeddedTemplateDir: ./openAPI_config/custom_template +embeddedTemplateDir: ./Config/custom_template +templateDir: ./Config/custom_template -templateDir: ./openAPI_config/custom_template files: TidalAPI.mustache: templateType: API From 30da747a27668d2a6e43253da32619372824ce7c Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Fri, 18 Oct 2024 18:50:50 +0200 Subject: [PATCH 07/11] Generated API --- .../API/Generated/.openapi-generator/FILES | 198 ++++++ .../API/Generated/.openapi-generator/VERSION | 1 + .../Classes/OpenAPIs/APIHelper.swift | 121 ++++ .../OpenAPIClient/Classes/OpenAPIs/APIs.swift | 93 +++ .../Classes/OpenAPIs/APIs/AlbumsAPI.swift | 351 +++++++++ .../OpenAPIs/APIs/AlbumsAPITidal.swift | 87 +++ .../Classes/OpenAPIs/APIs/ArtistsAPI.swift | 470 ++++++++++++ .../OpenAPIs/APIs/ArtistsAPITidal.swift | 126 ++++ .../Classes/OpenAPIs/APIs/PlaylistsAPI.swift | 280 ++++++++ .../OpenAPIs/APIs/PlaylistsAPITidal.swift | 75 ++ .../Classes/OpenAPIs/APIs/ProvidersAPI.swift | 114 +++ .../OpenAPIs/APIs/ProvidersAPITidal.swift | 39 + .../OpenAPIs/APIs/SearchResultsAPI.swift | 410 +++++++++++ .../OpenAPIs/APIs/SearchResultsAPITidal.swift | 99 +++ .../Classes/OpenAPIs/APIs/TracksAPI.swift | 408 +++++++++++ .../OpenAPIs/APIs/TracksAPITidal.swift | 99 +++ .../OpenAPIs/APIs/UserEntitlementsAPI.swift | 105 +++ .../APIs/UserEntitlementsAPITidal.swift | 39 + .../APIs/UserPublicProfilePicksAPI.swift | 273 +++++++ .../APIs/UserPublicProfilePicksAPITidal.swift | 75 ++ .../OpenAPIs/APIs/UserPublicProfilesAPI.swift | 385 ++++++++++ .../APIs/UserPublicProfilesAPITidal.swift | 99 +++ .../APIs/UserRecommendationsAPI.swift | 304 ++++++++ .../APIs/UserRecommendationsAPITidal.swift | 87 +++ .../Classes/OpenAPIs/APIs/UsersAPI.swift | 298 ++++++++ .../Classes/OpenAPIs/APIs/UsersAPITidal.swift | 87 +++ .../Classes/OpenAPIs/APIs/VideosAPI.swift | 294 ++++++++ .../OpenAPIs/APIs/VideosAPITidal.swift | 75 ++ .../Classes/OpenAPIs/CodableHelper.swift | 49 ++ .../Classes/OpenAPIs/Configuration.swift | 18 + .../Classes/OpenAPIs/Extensions.swift | 236 ++++++ .../Classes/OpenAPIs/JSONDataEncoding.swift | 56 ++ .../Classes/OpenAPIs/JSONEncodingHelper.swift | 45 ++ .../Classes/OpenAPIs/Models.swift | 129 ++++ .../OpenAPIs/Models/AlbumsAttributes.swift | 103 +++ .../Models/AlbumsItemResourceIdentifier.swift | 42 ++ .../AlbumsItemResourceIdentifierMeta.swift | 38 + .../Models/AlbumsItemsRelationship.swift | 37 + .../AlbumsItemsRelationshipDocument.swift | 40 ++ ...emsRelationshipDocumentIncludedInner.swift | 58 ++ .../Models/AlbumsMultiDataDocument.swift | 41 ++ ...AlbumsMultiDataDocumentIncludedInner.swift | 58 ++ .../Models/AlbumsRelationshipDocument.swift | 41 ++ ...umsRelationshipDocumentIncludedInner.swift | 53 ++ .../OpenAPIs/Models/AlbumsRelationships.swift | 45 ++ .../OpenAPIs/Models/AlbumsResource.swift | 50 ++ .../Models/AlbumsSingleDataDocument.swift | 40 ++ .../OpenAPIs/Models/ArtistsAttributes.swift | 49 ++ .../Models/ArtistsMultiDataDocument.swift | 41 ++ ...rtistsMultiDataDocumentIncludedInner.swift | 63 ++ .../Models/ArtistsRelationshipDocument.swift | 41 ++ ...stsRelationshipDocumentIncludedInner.swift | 58 ++ .../Models/ArtistsRelationships.swift | 53 ++ .../OpenAPIs/Models/ArtistsResource.swift | 50 ++ .../Models/ArtistsSingleDataDocument.swift | 40 ++ .../ArtistsTrackProvidersRelationship.swift | 37 + ...tsTrackProvidersRelationshipDocument.swift | 40 ++ ...istsTrackProvidersResourceIdentifier.swift | 42 ++ ...TrackProvidersResourceIdentifierMeta.swift | 33 + .../Models/CatalogueItemExternalLink.swift | 37 + .../Models/CatalogueItemImageLink.swift | 37 + .../Models/CatalogueItemVideoLink.swift | 37 + .../OpenAPIs/Models/ErrorDocument.swift | 37 + .../Classes/OpenAPIs/Models/ErrorObject.swift | 52 ++ .../OpenAPIs/Models/ErrorObjectSource.swift | 44 ++ .../OpenAPIs/Models/ExternalLinkMeta.swift | 46 ++ .../OpenAPIs/Models/ImageLinkMeta.swift | 39 + .../Classes/OpenAPIs/Models/Links.swift | 39 + .../Models/MultiDataRelationshipDoc.swift | 38 + .../OpenAPIs/Models/PlaylistsAttributes.swift | 84 +++ .../Models/PlaylistsExternalLink.swift | 38 + .../OpenAPIs/Models/PlaylistsImageLink.swift | 38 + .../PlaylistsItemsRelationshipDocument.swift | 41 ++ ...emsRelationshipDocumentIncludedInner.swift | 58 ++ .../Models/PlaylistsMultiDataDocument.swift | 41 ++ ...ylistsMultiDataDocumentIncludedInner.swift | 78 ++ .../PlaylistsOwnersRelationshipDocument.swift | 41 ++ ...ersRelationshipDocumentIncludedInner.swift | 78 ++ .../PlaylistsRelationshipDocument.swift | 41 ++ ...stsRelationshipDocumentIncludedInner.swift | 48 ++ .../Models/PlaylistsRelationships.swift | 37 + .../OpenAPIs/Models/PlaylistsResource.swift | 50 ++ .../Models/PlaylistsSingleDataDocument.swift | 40 ++ .../OpenAPIs/Models/PromptColors.swift | 39 + .../OpenAPIs/Models/ProvidersAttributes.swift | 34 + .../Models/ProvidersMultiDataDocument.swift | 37 + .../ProvidersRelationshipDocument.swift | 41 ++ ...ersRelationshipDocumentIncludedInner.swift | 33 + .../OpenAPIs/Models/ProvidersResource.swift | 51 ++ .../Models/ProvidersSingleDataDocument.swift | 36 + .../OpenAPIs/Models/ResourceIdentifier.swift | 38 + .../Models/SearchResultsAttributes.swift | 39 + .../Models/SearchResultsRelationships.swift | 53 ++ .../Models/SearchResultsResource.swift | 51 ++ .../SearchResultsSingleDataDocument.swift | 40 ++ ...sultsSingleDataDocumentIncludedInner.swift | 63 ++ ...chResultsTopHitsRelationshipDocument.swift | 41 ++ ...itsRelationshipDocumentIncludedInner.swift | 58 ++ .../Models/SingletonDataRelationshipDoc.swift | 37 + .../OpenAPIs/Models/TracksAttributes.swift | 83 +++ .../Models/TracksMultiDataDocument.swift | 41 ++ ...TracksMultiDataDocumentIncludedInner.swift | 63 ++ .../OpenAPIs/Models/TracksRelationships.swift | 49 ++ .../Models/TracksRelationshipsDocument.swift | 41 ++ ...ksRelationshipsDocumentIncludedInner.swift | 53 ++ .../OpenAPIs/Models/TracksResource.swift | 50 ++ .../Models/TracksSingleDataDocument.swift | 40 ++ ...blicProfilePicksRelationshipDocument.swift | 32 + .../Models/UserEntitlementsAttributes.swift | 38 + ...UserEntitlementsRelationshipDocument.swift | 40 ++ ...ntsRelationshipDocumentIncludedInner.swift | 33 + .../Models/UserEntitlementsResource.swift | 51 ++ .../UserEntitlementsSingleDataDocument.swift | 36 + .../UserPublicProfilePicksAttributes.swift | 60 ++ ...ProfilePicksItemRelationshipDocument.swift | 40 ++ ...temRelationshipDocumentIncludedInner.swift | 58 ++ ...rPublicProfilePicksMultiDataDocument.swift | 41 ++ ...ePicksMultiDataDocumentIncludedInner.swift | 73 ++ ...blicProfilePicksRelationshipDocument.swift | 41 ++ ...cksRelationshipDocumentIncludedInner.swift | 53 ++ .../UserPublicProfilePicksRelationships.swift | 37 + .../UserPublicProfilePicksResource.swift | 50 ++ .../Models/UserPublicProfilesAttributes.swift | 57 ++ .../UserPublicProfilesExternalLink.swift | 37 + .../UserPublicProfilesExternalLinkMeta.swift | 51 ++ .../Models/UserPublicProfilesImageLink.swift | 38 + .../UserPublicProfilesMultiDataDocument.swift | 41 ++ ...ofilesMultiDataDocumentIncludedInner.swift | 78 ++ ...erPublicProfilesRelationshipDocument.swift | 40 ++ ...lesRelationshipDocumentIncludedInner.swift | 48 ++ .../UserPublicProfilesRelationships.swift | 45 ++ .../Models/UserPublicProfilesResource.swift | 50 ++ ...UserPublicProfilesSingleDataDocument.swift | 40 ++ ...UserRecommendationsMultiDataDocument.swift | 41 ++ ...ationsMultiDataDocumentIncludedInner.swift | 48 ++ .../UserRecommendationsRelationships.swift | 41 ++ .../Models/UserRecommendationsResource.swift | 51 ++ ...serRecommendationsSingleDataDocument.swift | 40 ++ .../OpenAPIs/Models/UsersAttributes.swift | 59 ++ .../Models/UsersMultiDataDocument.swift | 41 ++ .../UsersMultiDataDocumentIncludedInner.swift | 58 ++ ...sRecommendationsRelationshipDocument.swift | 40 ++ ...onsRelationshipDocumentIncludedInner.swift | 38 + .../Models/UsersRelationshipDocument.swift | 41 ++ ...ersRelationshipDocumentIncludedInner.swift | 48 ++ .../OpenAPIs/Models/UsersRelationships.swift | 41 ++ .../OpenAPIs/Models/UsersResource.swift | 50 ++ .../Models/UsersSingleDataDocument.swift | 40 ++ .../OpenAPIs/Models/VideoLinkMeta.swift | 39 + .../OpenAPIs/Models/VideosAttributes.swift | 89 +++ .../Models/VideosMultiDataDocument.swift | 41 ++ ...VideosMultiDataDocumentIncludedInner.swift | 58 ++ .../OpenAPIs/Models/VideosRelationships.swift | 41 ++ .../Models/VideosRelationshipsDocument.swift | 41 ++ ...osRelationshipsDocumentIncludedInner.swift | 48 ++ .../OpenAPIs/Models/VideosResource.swift | 50 ++ .../Models/VideosSingleDataDocument.swift | 40 ++ .../OpenAPIs/OpenISO8601DateFormatter.swift | 56 ++ .../OpenAPIs/SynchronizedDictionary.swift | 26 + .../OpenAPIs/URLSessionImplementations.swift | 670 ++++++++++++++++++ .../Classes/OpenAPIs/Validation.swift | 161 +++++ Sources/API/Generated/README.md | 174 +++++ Sources/API/Generated/docs/AlbumsAPI.md | 348 +++++++++ .../API/Generated/docs/AlbumsAttributes.md | 23 + .../docs/AlbumsItemResourceIdentifier.md | 12 + .../docs/AlbumsItemResourceIdentifierMeta.md | 11 + .../Generated/docs/AlbumsItemsRelationship.md | 11 + .../docs/AlbumsItemsRelationshipDocument.md | 12 + ...sItemsRelationshipDocumentIncludedInner.md | 14 + .../Generated/docs/AlbumsMultiDataDocument.md | 12 + .../AlbumsMultiDataDocumentIncludedInner.md | 14 + .../docs/AlbumsRelationshipDocument.md | 12 + ...AlbumsRelationshipDocumentIncludedInner.md | 14 + .../API/Generated/docs/AlbumsRelationships.md | 13 + Sources/API/Generated/docs/AlbumsResource.md | 14 + .../docs/AlbumsSingleDataDocument.md | 12 + Sources/API/Generated/docs/ArtistsAPI.md | 460 ++++++++++++ .../API/Generated/docs/ArtistsAttributes.md | 13 + .../docs/ArtistsMultiDataDocument.md | 12 + .../ArtistsMultiDataDocumentIncludedInner.md | 14 + .../docs/ArtistsRelationshipDocument.md | 12 + ...rtistsRelationshipDocumentIncludedInner.md | 14 + .../Generated/docs/ArtistsRelationships.md | 15 + Sources/API/Generated/docs/ArtistsResource.md | 14 + .../docs/ArtistsSingleDataDocument.md | 12 + .../docs/ArtistsTrackProvidersRelationship.md | 11 + ...tistsTrackProvidersRelationshipDocument.md | 12 + ...ArtistsTrackProvidersResourceIdentifier.md | 12 + ...stsTrackProvidersResourceIdentifierMeta.md | 10 + .../docs/CatalogueItemExternalLink.md | 11 + .../Generated/docs/CatalogueItemImageLink.md | 11 + .../Generated/docs/CatalogueItemVideoLink.md | 11 + Sources/API/Generated/docs/ErrorDocument.md | 11 + Sources/API/Generated/docs/ErrorObject.md | 14 + .../API/Generated/docs/ErrorObjectSource.md | 12 + .../API/Generated/docs/ExternalLinkMeta.md | 10 + Sources/API/Generated/docs/ImageLinkMeta.md | 11 + Sources/API/Generated/docs/Links.md | 11 + .../docs/MultiDataRelationshipDoc.md | 11 + Sources/API/Generated/docs/PlaylistsAPI.md | 283 ++++++++ .../API/Generated/docs/PlaylistsAttributes.md | 20 + .../Generated/docs/PlaylistsExternalLink.md | 11 + .../API/Generated/docs/PlaylistsImageLink.md | 11 + .../PlaylistsItemsRelationshipDocument.md | 12 + ...sItemsRelationshipDocumentIncludedInner.md | 14 + .../docs/PlaylistsMultiDataDocument.md | 12 + ...PlaylistsMultiDataDocumentIncludedInner.md | 14 + .../PlaylistsOwnersRelationshipDocument.md | 12 + ...OwnersRelationshipDocumentIncludedInner.md | 14 + .../docs/PlaylistsRelationshipDocument.md | 12 + ...ylistsRelationshipDocumentIncludedInner.md | 14 + .../Generated/docs/PlaylistsRelationships.md | 11 + .../API/Generated/docs/PlaylistsResource.md | 14 + .../docs/PlaylistsSingleDataDocument.md | 12 + Sources/API/Generated/docs/PromptColors.md | 11 + Sources/API/Generated/docs/ProvidersAPI.md | 114 +++ .../API/Generated/docs/ProvidersAttributes.md | 10 + .../docs/ProvidersMultiDataDocument.md | 11 + .../docs/ProvidersRelationshipDocument.md | 12 + ...vidersRelationshipDocumentIncludedInner.md | 14 + .../API/Generated/docs/ProvidersResource.md | 14 + .../docs/ProvidersSingleDataDocument.md | 11 + .../API/Generated/docs/ResourceIdentifier.md | 11 + .../API/Generated/docs/SearchResultsAPI.md | 405 +++++++++++ .../Generated/docs/SearchResultsAttributes.md | 11 + .../docs/SearchResultsRelationships.md | 15 + .../Generated/docs/SearchResultsResource.md | 14 + .../docs/SearchResultsSingleDataDocument.md | 12 + ...hResultsSingleDataDocumentIncludedInner.md | 14 + ...earchResultsTopHitsRelationshipDocument.md | 12 + ...opHitsRelationshipDocumentIncludedInner.md | 14 + .../docs/SingletonDataRelationshipDoc.md | 11 + Sources/API/Generated/docs/TracksAPI.md | 405 +++++++++++ .../API/Generated/docs/TracksAttributes.md | 19 + .../Generated/docs/TracksMultiDataDocument.md | 12 + .../TracksMultiDataDocumentIncludedInner.md | 14 + .../API/Generated/docs/TracksRelationships.md | 14 + .../docs/TracksRelationshipsDocument.md | 12 + ...racksRelationshipsDocumentIncludedInner.md | 14 + Sources/API/Generated/docs/TracksResource.md | 14 + .../docs/TracksSingleDataDocument.md | 12 + ...rPublicProfilePicksRelationshipDocument.md | 10 + .../API/Generated/docs/UserEntitlementsAPI.md | 112 +++ .../docs/UserEntitlementsAttributes.md | 10 + .../UserEntitlementsRelationshipDocument.md | 12 + ...ementsRelationshipDocumentIncludedInner.md | 14 + .../docs/UserEntitlementsResource.md | 14 + .../UserEntitlementsSingleDataDocument.md | 11 + .../docs/UserPublicProfilePicksAPI.md | 281 ++++++++ .../docs/UserPublicProfilePicksAttributes.md | 14 + ...licProfilePicksItemRelationshipDocument.md | 12 + ...ksItemRelationshipDocumentIncludedInner.md | 14 + ...UserPublicProfilePicksMultiDataDocument.md | 12 + ...filePicksMultiDataDocumentIncludedInner.md | 14 + ...rPublicProfilePicksRelationshipDocument.md | 12 + ...ePicksRelationshipDocumentIncludedInner.md | 14 + .../UserPublicProfilePicksRelationships.md | 11 + .../docs/UserPublicProfilePicksResource.md | 14 + .../Generated/docs/UserPublicProfilesAPI.md | 391 ++++++++++ .../docs/UserPublicProfilesAttributes.md | 15 + .../docs/UserPublicProfilesExternalLink.md | 11 + .../UserPublicProfilesExternalLinkMeta.md | 11 + .../docs/UserPublicProfilesImageLink.md | 11 + .../UserPublicProfilesMultiDataDocument.md | 12 + ...cProfilesMultiDataDocumentIncludedInner.md | 14 + .../UserPublicProfilesRelationshipDocument.md | 12 + ...ofilesRelationshipDocumentIncludedInner.md | 14 + .../docs/UserPublicProfilesRelationships.md | 13 + .../docs/UserPublicProfilesResource.md | 14 + .../UserPublicProfilesSingleDataDocument.md | 12 + .../Generated/docs/UserRecommendationsAPI.md | 330 +++++++++ .../UserRecommendationsMultiDataDocument.md | 12 + ...endationsMultiDataDocumentIncludedInner.md | 14 + .../docs/UserRecommendationsRelationships.md | 12 + .../docs/UserRecommendationsResource.md | 14 + .../UserRecommendationsSingleDataDocument.md | 12 + Sources/API/Generated/docs/UsersAPI.md | 326 +++++++++ Sources/API/Generated/docs/UsersAttributes.md | 15 + .../Generated/docs/UsersMultiDataDocument.md | 12 + .../UsersMultiDataDocumentIncludedInner.md | 14 + ...sersRecommendationsRelationshipDocument.md | 12 + ...ationsRelationshipDocumentIncludedInner.md | 14 + .../docs/UsersRelationshipDocument.md | 12 + .../UsersRelationshipDocumentIncludedInner.md | 14 + .../API/Generated/docs/UsersRelationships.md | 12 + Sources/API/Generated/docs/UsersResource.md | 14 + .../Generated/docs/UsersSingleDataDocument.md | 12 + Sources/API/Generated/docs/VideoLinkMeta.md | 11 + Sources/API/Generated/docs/VideosAPI.md | 291 ++++++++ .../API/Generated/docs/VideosAttributes.md | 20 + .../Generated/docs/VideosMultiDataDocument.md | 12 + .../VideosMultiDataDocumentIncludedInner.md | 14 + .../API/Generated/docs/VideosRelationships.md | 12 + .../docs/VideosRelationshipsDocument.md | 12 + ...ideosRelationshipsDocumentIncludedInner.md | 14 + Sources/API/Generated/docs/VideosResource.md | 14 + .../docs/VideosSingleDataDocument.md | 12 + 297 files changed, 17785 insertions(+) create mode 100644 Sources/API/Generated/.openapi-generator/FILES create mode 100644 Sources/API/Generated/.openapi-generator/VERSION create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift create mode 100644 Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift create mode 100644 Sources/API/Generated/README.md create mode 100644 Sources/API/Generated/docs/AlbumsAPI.md create mode 100644 Sources/API/Generated/docs/AlbumsAttributes.md create mode 100644 Sources/API/Generated/docs/AlbumsItemResourceIdentifier.md create mode 100644 Sources/API/Generated/docs/AlbumsItemResourceIdentifierMeta.md create mode 100644 Sources/API/Generated/docs/AlbumsItemsRelationship.md create mode 100644 Sources/API/Generated/docs/AlbumsItemsRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/AlbumsMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/AlbumsRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/AlbumsRelationships.md create mode 100644 Sources/API/Generated/docs/AlbumsResource.md create mode 100644 Sources/API/Generated/docs/AlbumsSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/ArtistsAPI.md create mode 100644 Sources/API/Generated/docs/ArtistsAttributes.md create mode 100644 Sources/API/Generated/docs/ArtistsMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/ArtistsRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/ArtistsRelationships.md create mode 100644 Sources/API/Generated/docs/ArtistsResource.md create mode 100644 Sources/API/Generated/docs/ArtistsSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/ArtistsTrackProvidersRelationship.md create mode 100644 Sources/API/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md create mode 100644 Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md create mode 100644 Sources/API/Generated/docs/CatalogueItemExternalLink.md create mode 100644 Sources/API/Generated/docs/CatalogueItemImageLink.md create mode 100644 Sources/API/Generated/docs/CatalogueItemVideoLink.md create mode 100644 Sources/API/Generated/docs/ErrorDocument.md create mode 100644 Sources/API/Generated/docs/ErrorObject.md create mode 100644 Sources/API/Generated/docs/ErrorObjectSource.md create mode 100644 Sources/API/Generated/docs/ExternalLinkMeta.md create mode 100644 Sources/API/Generated/docs/ImageLinkMeta.md create mode 100644 Sources/API/Generated/docs/Links.md create mode 100644 Sources/API/Generated/docs/MultiDataRelationshipDoc.md create mode 100644 Sources/API/Generated/docs/PlaylistsAPI.md create mode 100644 Sources/API/Generated/docs/PlaylistsAttributes.md create mode 100644 Sources/API/Generated/docs/PlaylistsExternalLink.md create mode 100644 Sources/API/Generated/docs/PlaylistsImageLink.md create mode 100644 Sources/API/Generated/docs/PlaylistsItemsRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/PlaylistsMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/PlaylistsRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/PlaylistsRelationships.md create mode 100644 Sources/API/Generated/docs/PlaylistsResource.md create mode 100644 Sources/API/Generated/docs/PlaylistsSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/PromptColors.md create mode 100644 Sources/API/Generated/docs/ProvidersAPI.md create mode 100644 Sources/API/Generated/docs/ProvidersAttributes.md create mode 100644 Sources/API/Generated/docs/ProvidersMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/ProvidersRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/ProvidersResource.md create mode 100644 Sources/API/Generated/docs/ProvidersSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/ResourceIdentifier.md create mode 100644 Sources/API/Generated/docs/SearchResultsAPI.md create mode 100644 Sources/API/Generated/docs/SearchResultsAttributes.md create mode 100644 Sources/API/Generated/docs/SearchResultsRelationships.md create mode 100644 Sources/API/Generated/docs/SearchResultsResource.md create mode 100644 Sources/API/Generated/docs/SearchResultsSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/SingletonDataRelationshipDoc.md create mode 100644 Sources/API/Generated/docs/TracksAPI.md create mode 100644 Sources/API/Generated/docs/TracksAttributes.md create mode 100644 Sources/API/Generated/docs/TracksMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/TracksMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/TracksRelationships.md create mode 100644 Sources/API/Generated/docs/TracksRelationshipsDocument.md create mode 100644 Sources/API/Generated/docs/TracksRelationshipsDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/TracksResource.md create mode 100644 Sources/API/Generated/docs/TracksSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/UserEntitlementsAPI.md create mode 100644 Sources/API/Generated/docs/UserEntitlementsAttributes.md create mode 100644 Sources/API/Generated/docs/UserEntitlementsRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UserEntitlementsResource.md create mode 100644 Sources/API/Generated/docs/UserEntitlementsSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksAPI.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksAttributes.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksRelationships.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilePicksResource.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesAPI.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesAttributes.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesExternalLink.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesExternalLinkMeta.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesImageLink.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesRelationships.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesResource.md create mode 100644 Sources/API/Generated/docs/UserPublicProfilesSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/UserRecommendationsAPI.md create mode 100644 Sources/API/Generated/docs/UserRecommendationsMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UserRecommendationsRelationships.md create mode 100644 Sources/API/Generated/docs/UserRecommendationsResource.md create mode 100644 Sources/API/Generated/docs/UserRecommendationsSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/UsersAPI.md create mode 100644 Sources/API/Generated/docs/UsersAttributes.md create mode 100644 Sources/API/Generated/docs/UsersMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/UsersMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UsersRecommendationsRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UsersRelationshipDocument.md create mode 100644 Sources/API/Generated/docs/UsersRelationshipDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/UsersRelationships.md create mode 100644 Sources/API/Generated/docs/UsersResource.md create mode 100644 Sources/API/Generated/docs/UsersSingleDataDocument.md create mode 100644 Sources/API/Generated/docs/VideoLinkMeta.md create mode 100644 Sources/API/Generated/docs/VideosAPI.md create mode 100644 Sources/API/Generated/docs/VideosAttributes.md create mode 100644 Sources/API/Generated/docs/VideosMultiDataDocument.md create mode 100644 Sources/API/Generated/docs/VideosMultiDataDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/VideosRelationships.md create mode 100644 Sources/API/Generated/docs/VideosRelationshipsDocument.md create mode 100644 Sources/API/Generated/docs/VideosRelationshipsDocumentIncludedInner.md create mode 100644 Sources/API/Generated/docs/VideosResource.md create mode 100644 Sources/API/Generated/docs/VideosSingleDataDocument.md diff --git a/Sources/API/Generated/.openapi-generator/FILES b/Sources/API/Generated/.openapi-generator/FILES new file mode 100644 index 00000000..739fca71 --- /dev/null +++ b/Sources/API/Generated/.openapi-generator/FILES @@ -0,0 +1,198 @@ +.gitignore +.openapi-generator-ignore +.swiftformat +Cartfile +OpenAPIClient.podspec +OpenAPIClient/Classes/OpenAPIs/APIHelper.swift +OpenAPIClient/Classes/OpenAPIs/APIs.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift +OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift +OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift +OpenAPIClient/Classes/OpenAPIs/Configuration.swift +OpenAPIClient/Classes/OpenAPIs/Extensions.swift +OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift +OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift +OpenAPIClient/Classes/OpenAPIs/Models.swift +OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift +OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift +OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift +OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift +OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift +OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift +OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift +OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift +OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift +OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift +OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift +OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift +OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift +OpenAPIClient/Classes/OpenAPIs/Models/Links.swift +OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift +OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift +OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift +OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift +OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift +OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift +OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift +OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift +OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift +OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift +OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift +OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift +OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift +OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift +OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift +OpenAPIClient/Classes/OpenAPIs/Validation.swift +Package.swift +README.md +docs/AlbumsAttributes.md +docs/AlbumsItemResourceIdentifier.md +docs/AlbumsItemResourceIdentifierMeta.md +docs/AlbumsItemsRelationship.md +docs/AlbumsRelationships.md +docs/AlbumsResource.md +docs/ArtistsAttributes.md +docs/ArtistsRelationships.md +docs/ArtistsResource.md +docs/ArtistsTrackProvidersRelationship.md +docs/ArtistsTrackProvidersResourceIdentifier.md +docs/ArtistsTrackProvidersResourceIdentifierMeta.md +docs/CatalogueItemExternalLink.md +docs/CatalogueItemImageLink.md +docs/CatalogueItemVideoLink.md +docs/ErrorDocument.md +docs/ErrorObject.md +docs/ErrorObjectSource.md +docs/ExternalLinkMeta.md +docs/ImageLinkMeta.md +docs/Links.md +docs/MultiDataRelationshipDoc.md +docs/PlaylistsAttributes.md +docs/PlaylistsExternalLink.md +docs/PlaylistsImageLink.md +docs/PlaylistsRelationshipDocument.md +docs/PlaylistsRelationships.md +docs/PlaylistsResource.md +docs/PromptColors.md +docs/ProvidersAttributes.md +docs/ProvidersResource.md +docs/ResourceIdentifier.md +docs/SingletonDataRelationshipDoc.md +docs/TracksAttributes.md +docs/TracksRelationships.md +docs/TracksResource.md +docs/UpdateUserPublicProfilePicksRelationshipDocument.md +docs/UserEntitlementsAPI.md +docs/UserEntitlementsAttributes.md +docs/UserEntitlementsRelationshipDocument.md +docs/UserEntitlementsRelationshipDocumentIncludedInner.md +docs/UserEntitlementsResource.md +docs/UserEntitlementsSingleDataDocument.md +docs/UserPublicProfilePicksAPI.md +docs/UserPublicProfilePicksAttributes.md +docs/UserPublicProfilePicksItemRelationshipDocument.md +docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md +docs/UserPublicProfilePicksMultiDataDocument.md +docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md +docs/UserPublicProfilePicksRelationshipDocument.md +docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md +docs/UserPublicProfilePicksRelationships.md +docs/UserPublicProfilePicksResource.md +docs/UserPublicProfilesAPI.md +docs/UserPublicProfilesAttributes.md +docs/UserPublicProfilesExternalLink.md +docs/UserPublicProfilesExternalLinkMeta.md +docs/UserPublicProfilesImageLink.md +docs/UserPublicProfilesMultiDataDocument.md +docs/UserPublicProfilesMultiDataDocumentIncludedInner.md +docs/UserPublicProfilesRelationshipDocument.md +docs/UserPublicProfilesRelationshipDocumentIncludedInner.md +docs/UserPublicProfilesRelationships.md +docs/UserPublicProfilesResource.md +docs/UserPublicProfilesSingleDataDocument.md +docs/UserRecommendationsAPI.md +docs/UserRecommendationsMultiDataDocument.md +docs/UserRecommendationsMultiDataDocumentIncludedInner.md +docs/UserRecommendationsRelationships.md +docs/UserRecommendationsResource.md +docs/UserRecommendationsSingleDataDocument.md +docs/UsersAPI.md +docs/UsersAttributes.md +docs/UsersMultiDataDocument.md +docs/UsersMultiDataDocumentIncludedInner.md +docs/UsersRecommendationsRelationshipDocument.md +docs/UsersRecommendationsRelationshipDocumentIncludedInner.md +docs/UsersRelationshipDocument.md +docs/UsersRelationshipDocumentIncludedInner.md +docs/UsersRelationships.md +docs/UsersResource.md +docs/UsersSingleDataDocument.md +docs/VideoLinkMeta.md +docs/VideosAttributes.md +docs/VideosRelationships.md +docs/VideosResource.md +git_push.sh +project.yml diff --git a/Sources/API/Generated/.openapi-generator/VERSION b/Sources/API/Generated/.openapi-generator/VERSION new file mode 100644 index 00000000..4bc5d618 --- /dev/null +++ b/Sources/API/Generated/.openapi-generator/VERSION @@ -0,0 +1 @@ +7.9.0 diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift new file mode 100644 index 00000000..7c975bb6 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift @@ -0,0 +1,121 @@ +// APIHelper.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct APIHelper { + public static func rejectNil(_ source: [String: Any?]) -> [String: Any]? { + let destination = source.reduce(into: [String: Any]()) { result, item in + if let value = item.value { + result[item.key] = value + } + } + + if destination.isEmpty { + return nil + } + return destination + } + + public static func rejectNilHeaders(_ source: [String: Any?]) -> [String: String] { + return source.reduce(into: [String: String]()) { result, item in + if let collection = item.value as? [Any?] { + result[item.key] = collection + .compactMap { value in convertAnyToString(value) } + .joined(separator: ",") + } else if let value: Any = item.value { + result[item.key] = convertAnyToString(value) + } + } + } + + public static func convertBoolToString(_ source: [String: Any]?) -> [String: Any]? { + guard let source = source else { + return nil + } + + return source.reduce(into: [String: Any]()) { result, item in + switch item.value { + case let x as Bool: + result[item.key] = x.description + default: + result[item.key] = item.value + } + } + } + + public static func convertAnyToString(_ value: Any?) -> String? { + guard let value = value else { return nil } + if let value = value as? any RawRepresentable { + return "\(value.rawValue)" + } else { + return "\(value)" + } + } + + public static func mapValueToPathItem(_ source: Any) -> Any { + if let collection = source as? [Any?] { + return collection + .compactMap { value in convertAnyToString(value) } + .joined(separator: ",") + } else if let value = source as? any RawRepresentable { + return "\(value.rawValue)" + } + return source + } + + /// maps all values from source to query parameters + /// + /// explode attribute is respected: collection values might be either joined or split up into separate key value pairs + public static func mapValuesToQueryItems(_ source: [String: (wrappedValue: Any?, isExplode: Bool)]) -> [URLQueryItem]? { + let destination = source.filter { $0.value.wrappedValue != nil }.reduce(into: [URLQueryItem]()) { result, item in + if let collection = item.value.wrappedValue as? [Any?] { + + let collectionValues: [String] = collection.compactMap { value in convertAnyToString(value) } + + if !item.value.isExplode { + result.append(URLQueryItem(name: item.key, value: collectionValues.joined(separator: ","))) + } else { + collectionValues + .forEach { value in + result.append(URLQueryItem(name: item.key, value: value)) + } + } + + } else if let value = item.value.wrappedValue { + result.append(URLQueryItem(name: item.key, value: convertAnyToString(value))) + } + } + + if destination.isEmpty { + return nil + } + return destination.sorted { $0.name < $1.name } + } + + /// maps all values from source to query parameters + /// + /// collection values are always exploded + public static func mapValuesToQueryItems(_ source: [String: Any?]) -> [URLQueryItem]? { + let destination = source.filter { $0.value != nil }.reduce(into: [URLQueryItem]()) { result, item in + if let collection = item.value as? [Any?] { + collection + .compactMap { value in convertAnyToString(value) } + .forEach { value in + result.append(URLQueryItem(name: item.key, value: value)) + } + + } else if let value = item.value { + result.append(URLQueryItem(name: item.key, value: convertAnyToString(value))) + } + } + + if destination.isEmpty { + return nil + } + return destination.sorted { $0.name < $1.name } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift new file mode 100644 index 00000000..be8c1239 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift @@ -0,0 +1,93 @@ +// APIs.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(FoundationNetworking) +import FoundationNetworking +#endif +open class OpenAPIClientAPI { + public static var basePath = "https://openapi.tidal.com/v2" + public static var customHeaders: [String: String] = [:] + public static var credential: URLCredential? + public static var requestBuilderFactory: RequestBuilderFactory = URLSessionRequestBuilderFactory() + public static var apiResponseQueue: DispatchQueue = .main +} + +open class RequestBuilder { + var credential: URLCredential? + var headers: [String: String] + public let parameters: [String: Any]? + public let method: String + public let URLString: String + public let requestTask: RequestTask = RequestTask() + public let requiresAuthentication: Bool + + /// Optional block to obtain a reference to the request's progress instance when available. + public var onProgressReady: ((Progress) -> Void)? + + required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) { + self.method = method + self.URLString = URLString + self.parameters = parameters + self.headers = headers + self.requiresAuthentication = requiresAuthentication + + addHeaders(OpenAPIClientAPI.customHeaders) + } + + open func addHeaders(_ aHeaders: [String: String]) { + for (header, value) in aHeaders { + headers[header] = value + } + } + + @discardableResult + open func execute(_ apiResponseQueue: DispatchQueue = OpenAPIClientAPI.apiResponseQueue, _ completion: @escaping (_ result: Swift.Result, ErrorResponse>) -> Void) -> RequestTask { + return requestTask + } + + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + @discardableResult + open func execute() async throws -> Response { + return try await withTaskCancellationHandler { + try Task.checkCancellation() + return try await withCheckedThrowingContinuation { continuation in + guard !Task.isCancelled else { + continuation.resume(throwing: CancellationError()) + return + } + + self.execute { result in + switch result { + case let .success(response): + continuation.resume(returning: response) + case let .failure(error): + continuation.resume(throwing: error) + } + } + } + } onCancel: { + self.requestTask.cancel() + } + } + + public func addHeader(name: String, value: String) -> Self { + if !value.isEmpty { + headers[name] = value + } + return self + } + + open func addCredential() -> Self { + credential = OpenAPIClientAPI.credential + return self + } +} + +public protocol RequestBuilderFactory { + func getNonDecodableBuilder() -> RequestBuilder.Type + func getBuilder() -> RequestBuilder.Type +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift new file mode 100644 index 00000000..fc1a182e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift @@ -0,0 +1,351 @@ +// +// AlbumsAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class AlbumsAPI { + + /** + Relationship: artists + + - parameter id: (path) TIDAL album id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ArtistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getAlbumArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await getAlbumArtistsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: artists + - GET /albums/{id}/relationships/artists + - Retrieve artist details of the related album. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL album id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getAlbumArtistsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/albums/{id}/relationships/artists" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get single album + + - parameter id: (path) TIDAL album id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums (optional) + - returns: AlbumsSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getAlbumById(id: String, countryCode: String, include: [String]? = nil) async throws -> AlbumsSingleDataDocument { + return try await getAlbumByIdWithRequestBuilder(id: id, countryCode: countryCode, include: include).execute().body + } + + /** + Get single album + - GET /albums/{id} + - Retrieve album details by TIDAL album id. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL album id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums (optional) + - returns: RequestBuilder + */ + internal class func getAlbumByIdWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/albums/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: items + + - parameter id: (path) TIDAL album id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: AlbumsItemsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getAlbumItemsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsItemsRelationshipDocument { + return try await getAlbumItemsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: items + - GET /albums/{id}/relationships/items + - Retrieve album item details. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL album id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getAlbumItemsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/albums/{id}/relationships/items" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: providers + + - parameter id: (path) TIDAL id of the album + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: providers (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ProvidersRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getAlbumProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ProvidersRelationshipDocument { + return try await getAlbumProvidersRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: providers + - GET /albums/{id}/relationships/providers + - This endpoint can be used to retrieve a list of album's related providers. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the album + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: providers (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getAlbumProvidersRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/albums/{id}/relationships/providers" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: similar albums + + - parameter id: (path) TIDAL id of the album + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: similarAlbums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: AlbumsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getAlbumSimilarAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await getAlbumSimilarAlbumsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: similar albums + - GET /albums/{id}/relationships/similarAlbums + - This endpoint can be used to retrieve a list of albums similar to the given album. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the album + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: similarAlbums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getAlbumSimilarAlbumsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/albums/{id}/relationships/similarAlbums" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get multiple albums + + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - parameter filterBarcodeId: (query) Allows to filter the collection of resources based on barcodeId attribute value (optional) + - returns: AlbumsMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getAlbumsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterBarcodeId: [String]? = nil) async throws -> AlbumsMultiDataDocument { + return try await getAlbumsByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId, filterBarcodeId: filterBarcodeId).execute().body + } + + /** + Get multiple albums + - GET /albums + - Retrieve multiple album details. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - parameter filterBarcodeId: (query) Allows to filter the collection of resources based on barcodeId attribute value (optional) + - returns: RequestBuilder + */ + internal class func getAlbumsByFiltersWithRequestBuilder(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterBarcodeId: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/albums" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + "filter[barcodeId]": (wrappedValue: filterBarcodeId?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift new file mode 100644 index 00000000..1396faf1 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift @@ -0,0 +1,87 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `AlbumsAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await AlbumsAPI.getResource() +/// ``` +public enum AlbumsAPITidal { + + + /** + Relationship: artists + + - returns: ArtistsRelationshipDocument + */ + public static func getAlbumArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await RequestHelper.createRequest { + AlbumsAPI.getAlbumArtistsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Get single album + + - returns: AlbumsSingleDataDocument + */ + public static func getAlbumById(id: String, countryCode: String, include: [String]? = nil) async throws -> AlbumsSingleDataDocument { + return try await RequestHelper.createRequest { + AlbumsAPI.getAlbumByIdWithRequestBuilder(id: id, countryCode: countryCode, include: include) + } + } + + + /** + Relationship: items + + - returns: AlbumsItemsRelationshipDocument + */ + public static func getAlbumItemsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsItemsRelationshipDocument { + return try await RequestHelper.createRequest { + AlbumsAPI.getAlbumItemsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: providers + + - returns: ProvidersRelationshipDocument + */ + public static func getAlbumProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ProvidersRelationshipDocument { + return try await RequestHelper.createRequest { + AlbumsAPI.getAlbumProvidersRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: similar albums + + - returns: AlbumsRelationshipDocument + */ + public static func getAlbumSimilarAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await RequestHelper.createRequest { + AlbumsAPI.getAlbumSimilarAlbumsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Get multiple albums + + - returns: AlbumsMultiDataDocument + */ + public static func getAlbumsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterBarcodeId: [String]? = nil) async throws -> AlbumsMultiDataDocument { + return try await RequestHelper.createRequest { + AlbumsAPI.getAlbumsByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId, filterBarcodeId: filterBarcodeId) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift new file mode 100644 index 00000000..58283e02 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift @@ -0,0 +1,470 @@ +// +// ArtistsAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class ArtistsAPI { + + /** + Relationship: albums + + - parameter id: (path) TIDAL artist id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: AlbumsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getArtistAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await getArtistAlbumsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: albums + - GET /artists/{id}/relationships/albums + - Retrieve album details of the related artist. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL artist id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getArtistAlbumsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/artists/{id}/relationships/albums" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get single artist + + - parameter id: (path) TIDAL artist id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio (optional) + - returns: ArtistsSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getArtistById(id: String, countryCode: String, include: [String]? = nil) async throws -> ArtistsSingleDataDocument { + return try await getArtistByIdWithRequestBuilder(id: id, countryCode: countryCode, include: include).execute().body + } + + /** + Get single artist + - GET /artists/{id} + - Retrieve artist details by TIDAL artist id. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL artist id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio (optional) + - returns: RequestBuilder + */ + internal class func getArtistByIdWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/artists/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: radio + + - parameter id: (path) TIDAL id of the artist + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: radio (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ArtistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getArtistRadioRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await getArtistRadioRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: radio + - GET /artists/{id}/relationships/radio + - This endpoint can be used to retrieve a list of radios for the given artist. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the artist + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: radio (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getArtistRadioRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/artists/{id}/relationships/radio" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: similar artists + + - parameter id: (path) TIDAL id of the artist + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: similarArtists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ArtistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getArtistSimilarArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await getArtistSimilarArtistsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: similar artists + - GET /artists/{id}/relationships/similarArtists + - This endpoint can be used to retrieve a list of artists similar to the given artist. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the artist + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: similarArtists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getArtistSimilarArtistsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/artists/{id}/relationships/similarArtists" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: track providers + + - parameter id: (path) TIDAL id of the artist + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: trackProviders (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ArtistsTrackProvidersRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getArtistTrackProvidersRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsTrackProvidersRelationshipDocument { + return try await getArtistTrackProvidersRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: track providers + - GET /artists/{id}/relationships/trackProviders + - Retrieve providers that have released tracks for this artist + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the artist + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: trackProviders (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getArtistTrackProvidersRelationshipWithRequestBuilder(id: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/artists/{id}/relationships/trackProviders" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + * enum for parameter collapseBy + */ + public enum CollapseBy_getArtistTracksRelationship: String, CaseIterable { + case fingerprint = "FINGERPRINT" + case _none = "NONE" + } + + /** + Relationship: tracks + + - parameter id: (path) TIDAL artist id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter collapseBy: (query) Collapse by options for getting artist tracks. Available options: FINGERPRINT, ID. FINGERPRINT option might collapse similar tracks based item fingerprints while collapsing by ID always returns all available items. (optional, default to .fingerprint) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: tracks (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: TracksRelationshipsDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getArtistTracksRelationship(id: String, countryCode: String, collapseBy: CollapseBy_getArtistTracksRelationship? = nil, include: [String]? = nil, pageCursor: String? = nil) async throws -> TracksRelationshipsDocument { + return try await getArtistTracksRelationshipWithRequestBuilder(id: id, countryCode: countryCode, collapseBy: collapseBy, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: tracks + - GET /artists/{id}/relationships/tracks + - Retrieve track details by related artist. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL artist id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter collapseBy: (query) Collapse by options for getting artist tracks. Available options: FINGERPRINT, ID. FINGERPRINT option might collapse similar tracks based item fingerprints while collapsing by ID always returns all available items. (optional, default to .fingerprint) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: tracks (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getArtistTracksRelationshipWithRequestBuilder(id: String, countryCode: String, collapseBy: CollapseBy_getArtistTracksRelationship? = nil, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/artists/{id}/relationships/tracks" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "collapseBy": (wrappedValue: collapseBy?.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: videos + + - parameter id: (path) TIDAL artist id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: videos (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: VideosRelationshipsDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getArtistVideosRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> VideosRelationshipsDocument { + return try await getArtistVideosRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: videos + - GET /artists/{id}/relationships/videos + - Retrieve video details by related artist. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL artist id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: videos (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getArtistVideosRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/artists/{id}/relationships/videos" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get multiple artists + + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - returns: ArtistsMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getArtistsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil) async throws -> ArtistsMultiDataDocument { + return try await getArtistsByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId).execute().body + } + + /** + Get multiple artists + - GET /artists + - Retrieve multiple artist details. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - returns: RequestBuilder + */ + internal class func getArtistsByFiltersWithRequestBuilder(countryCode: String, include: [String]? = nil, filterId: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/artists" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift new file mode 100644 index 00000000..ffd60e0d --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift @@ -0,0 +1,126 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `ArtistsAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await ArtistsAPI.getResource() +/// ``` +public enum ArtistsAPITidal { + + + /** + Relationship: albums + + - returns: AlbumsRelationshipDocument + */ + public static func getArtistAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await RequestHelper.createRequest { + ArtistsAPI.getArtistAlbumsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Get single artist + + - returns: ArtistsSingleDataDocument + */ + public static func getArtistById(id: String, countryCode: String, include: [String]? = nil) async throws -> ArtistsSingleDataDocument { + return try await RequestHelper.createRequest { + ArtistsAPI.getArtistByIdWithRequestBuilder(id: id, countryCode: countryCode, include: include) + } + } + + + /** + Relationship: radio + + - returns: ArtistsRelationshipDocument + */ + public static func getArtistRadioRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await RequestHelper.createRequest { + ArtistsAPI.getArtistRadioRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: similar artists + + - returns: ArtistsRelationshipDocument + */ + public static func getArtistSimilarArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await RequestHelper.createRequest { + ArtistsAPI.getArtistSimilarArtistsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: track providers + + - returns: ArtistsTrackProvidersRelationshipDocument + */ + public static func getArtistTrackProvidersRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsTrackProvidersRelationshipDocument { + return try await RequestHelper.createRequest { + ArtistsAPI.getArtistTrackProvidersRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor) + } + } + + + /** + * enum for parameter collapseBy + */ + public enum CollapseBy_getArtistTracksRelationship: String, CaseIterable { + case fingerprint = "FINGERPRINT" + case _none = "NONE" + + func toArtistsAPIEnum() -> ArtistsAPI.CollapseBy_getArtistTracksRelationship { + switch self { + case .fingerprint: return .fingerprint + case ._none: return ._none + } + } + } + + /** + Relationship: tracks + + - returns: TracksRelationshipsDocument + */ + public static func getArtistTracksRelationship(id: String, countryCode: String, collapseBy: ArtistsAPITidal.CollapseBy_getArtistTracksRelationship? = nil, include: [String]? = nil, pageCursor: String? = nil) async throws -> TracksRelationshipsDocument { + return try await RequestHelper.createRequest { + ArtistsAPI.getArtistTracksRelationshipWithRequestBuilder(id: id, countryCode: countryCode, collapseBy: collapseBy?.toArtistsAPIEnum(), include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: videos + + - returns: VideosRelationshipsDocument + */ + public static func getArtistVideosRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> VideosRelationshipsDocument { + return try await RequestHelper.createRequest { + ArtistsAPI.getArtistVideosRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Get multiple artists + + - returns: ArtistsMultiDataDocument + */ + public static func getArtistsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil) async throws -> ArtistsMultiDataDocument { + return try await RequestHelper.createRequest { + ArtistsAPI.getArtistsByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift new file mode 100644 index 00000000..c112abde --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift @@ -0,0 +1,280 @@ +// +// PlaylistsAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class PlaylistsAPI { + + /** + Get current user's playlists + + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items, owners (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: PlaylistsMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getMyPlaylists(include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsMultiDataDocument { + return try await getMyPlaylistsWithRequestBuilder(include: include, pageCursor: pageCursor).execute().body + } + + /** + Get current user's playlists + - GET /playlists/me + - Get my playlists + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items, owners (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getMyPlaylistsWithRequestBuilder(include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + let localVariablePath = "/playlists/me" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get single playlist + + - parameter countryCode: (query) Country code (ISO 3166-1 alpha-2) + - parameter id: (path) TIDAL playlist id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items, owners (optional) + - returns: PlaylistsSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getPlaylistById(countryCode: String, id: String, include: [String]? = nil) async throws -> PlaylistsSingleDataDocument { + return try await getPlaylistByIdWithRequestBuilder(countryCode: countryCode, id: id, include: include).execute().body + } + + /** + Get single playlist + - GET /playlists/{id} + - Get playlist by id + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter countryCode: (query) Country code (ISO 3166-1 alpha-2) + - parameter id: (path) TIDAL playlist id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items, owners (optional) + - returns: RequestBuilder + */ + internal class func getPlaylistByIdWithRequestBuilder(countryCode: String, id: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/playlists/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: items + + - parameter id: (path) TIDAL playlist id + - parameter countryCode: (query) Country code (ISO 3166-1 alpha-2) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: PlaylistsItemsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getPlaylistItemsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsItemsRelationshipDocument { + return try await getPlaylistItemsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: items + - GET /playlists/{id}/relationships/items + - Get playlist items + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL playlist id + - parameter countryCode: (query) Country code (ISO 3166-1 alpha-2) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getPlaylistItemsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/playlists/{id}/relationships/items" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: owner + + - parameter id: (path) TIDAL playlist id + - parameter countryCode: (query) Country code (ISO 3166-1 alpha-2) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: owners (optional) + - returns: PlaylistsOwnersRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getPlaylistOwnersRelationship(id: String, countryCode: String, include: [String]? = nil) async throws -> PlaylistsOwnersRelationshipDocument { + return try await getPlaylistOwnersRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include).execute().body + } + + /** + Relationship: owner + - GET /playlists/{id}/relationships/owners + - Get playlist owner + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL playlist id + - parameter countryCode: (query) Country code (ISO 3166-1 alpha-2) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: owners (optional) + - returns: RequestBuilder + */ + internal class func getPlaylistOwnersRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/playlists/{id}/relationships/owners" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get multiple playlists + + - parameter countryCode: (query) Country code (ISO 3166-1 alpha-2) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items, owners (optional) + - parameter filterId: (query) public.usercontent.getPlaylists.ids.descr (optional) + - returns: PlaylistsMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getPlaylistsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil) async throws -> PlaylistsMultiDataDocument { + return try await getPlaylistsByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId).execute().body + } + + /** + Get multiple playlists + - GET /playlists + - Get user playlists + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter countryCode: (query) Country code (ISO 3166-1 alpha-2) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: items, owners (optional) + - parameter filterId: (query) public.usercontent.getPlaylists.ids.descr (optional) + - returns: RequestBuilder + */ + internal class func getPlaylistsByFiltersWithRequestBuilder(countryCode: String, include: [String]? = nil, filterId: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/playlists" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift new file mode 100644 index 00000000..8eb96273 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift @@ -0,0 +1,75 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `PlaylistsAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await PlaylistsAPI.getResource() +/// ``` +public enum PlaylistsAPITidal { + + + /** + Get current user's playlists + + - returns: PlaylistsMultiDataDocument + */ + public static func getMyPlaylists(include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsMultiDataDocument { + return try await RequestHelper.createRequest { + PlaylistsAPI.getMyPlaylistsWithRequestBuilder(include: include, pageCursor: pageCursor) + } + } + + + /** + Get single playlist + + - returns: PlaylistsSingleDataDocument + */ + public static func getPlaylistById(countryCode: String, id: String, include: [String]? = nil) async throws -> PlaylistsSingleDataDocument { + return try await RequestHelper.createRequest { + PlaylistsAPI.getPlaylistByIdWithRequestBuilder(countryCode: countryCode, id: id, include: include) + } + } + + + /** + Relationship: items + + - returns: PlaylistsItemsRelationshipDocument + */ + public static func getPlaylistItemsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsItemsRelationshipDocument { + return try await RequestHelper.createRequest { + PlaylistsAPI.getPlaylistItemsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: owner + + - returns: PlaylistsOwnersRelationshipDocument + */ + public static func getPlaylistOwnersRelationship(id: String, countryCode: String, include: [String]? = nil) async throws -> PlaylistsOwnersRelationshipDocument { + return try await RequestHelper.createRequest { + PlaylistsAPI.getPlaylistOwnersRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include) + } + } + + + /** + Get multiple playlists + + - returns: PlaylistsMultiDataDocument + */ + public static func getPlaylistsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil) async throws -> PlaylistsMultiDataDocument { + return try await RequestHelper.createRequest { + PlaylistsAPI.getPlaylistsByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift new file mode 100644 index 00000000..6cf24cc5 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift @@ -0,0 +1,114 @@ +// +// ProvidersAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class ProvidersAPI { + + /** + Get single provider + + - parameter id: (path) TIDAL provider id + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - returns: ProvidersSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getProviderById(id: String, include: [String]? = nil) async throws -> ProvidersSingleDataDocument { + return try await getProviderByIdWithRequestBuilder(id: id, include: include).execute().body + } + + /** + Get single provider + - GET /providers/{id} + - Retrieve provider details by TIDAL provider id. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL provider id + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - returns: RequestBuilder + */ + internal class func getProviderByIdWithRequestBuilder(id: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/providers/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get multiple providers + + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - parameter filterId: (query) provider id (optional) + - returns: ProvidersMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getProvidersByFilters(include: [String]? = nil, filterId: [String]? = nil) async throws -> ProvidersMultiDataDocument { + return try await getProvidersByFiltersWithRequestBuilder(include: include, filterId: filterId).execute().body + } + + /** + Get multiple providers + - GET /providers + - Retrieve multiple provider details. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - parameter filterId: (query) provider id (optional) + - returns: RequestBuilder + */ + internal class func getProvidersByFiltersWithRequestBuilder(include: [String]? = nil, filterId: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/providers" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift new file mode 100644 index 00000000..c1afffdf --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift @@ -0,0 +1,39 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `ProvidersAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await ProvidersAPI.getResource() +/// ``` +public enum ProvidersAPITidal { + + + /** + Get single provider + + - returns: ProvidersSingleDataDocument + */ + public static func getProviderById(id: String, include: [String]? = nil) async throws -> ProvidersSingleDataDocument { + return try await RequestHelper.createRequest { + ProvidersAPI.getProviderByIdWithRequestBuilder(id: id, include: include) + } + } + + + /** + Get multiple providers + + - returns: ProvidersMultiDataDocument + */ + public static func getProvidersByFilters(include: [String]? = nil, filterId: [String]? = nil) async throws -> ProvidersMultiDataDocument { + return try await RequestHelper.createRequest { + ProvidersAPI.getProvidersByFiltersWithRequestBuilder(include: include, filterId: filterId) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift new file mode 100644 index 00000000..fbf997c0 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift @@ -0,0 +1,410 @@ +// +// SearchResultsAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class SearchResultsAPI { + + /** + Relationship: albums + + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: AlbumsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getSearchResultsAlbumsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await getSearchResultsAlbumsRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: albums + - GET /searchresults/{query}/relationships/albums + - Search for albums by a query. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getSearchResultsAlbumsRelationshipWithRequestBuilder(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/searchresults/{query}/relationships/albums" + let queryPreEscape = "\(APIHelper.mapValueToPathItem(query))" + let queryPostEscape = queryPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{query}", with: queryPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: artists + + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ArtistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getSearchResultsArtistsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await getSearchResultsArtistsRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: artists + - GET /searchresults/{query}/relationships/artists + - Search for artists by a query. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getSearchResultsArtistsRelationshipWithRequestBuilder(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/searchresults/{query}/relationships/artists" + let queryPreEscape = "\(APIHelper.mapValueToPathItem(query))" + let queryPostEscape = queryPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{query}", with: queryPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Search for music metadata by a query + + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, tracks, videos, playlists, topHits (optional) + - returns: SearchResultsSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getSearchResultsByQuery(query: String, countryCode: String, include: [String]? = nil) async throws -> SearchResultsSingleDataDocument { + return try await getSearchResultsByQueryWithRequestBuilder(query: query, countryCode: countryCode, include: include).execute().body + } + + /** + Search for music metadata by a query + - GET /searchresults/{query} + - Search for music: albums, artists, tracks, etc. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, tracks, videos, playlists, topHits (optional) + - returns: RequestBuilder + */ + internal class func getSearchResultsByQueryWithRequestBuilder(query: String, countryCode: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/searchresults/{query}" + let queryPreEscape = "\(APIHelper.mapValueToPathItem(query))" + let queryPostEscape = queryPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{query}", with: queryPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: playlists + + - parameter query: (path) Searh query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: playlists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: PlaylistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getSearchResultsPlaylistsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await getSearchResultsPlaylistsRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: playlists + - GET /searchresults/{query}/relationships/playlists + - Search for playlists by a query. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter query: (path) Searh query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: playlists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getSearchResultsPlaylistsRelationshipWithRequestBuilder(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/searchresults/{query}/relationships/playlists" + let queryPreEscape = "\(APIHelper.mapValueToPathItem(query))" + let queryPostEscape = queryPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{query}", with: queryPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: topHits + + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: topHits (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: SearchResultsTopHitsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getSearchResultsTopHitsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> SearchResultsTopHitsRelationshipDocument { + return try await getSearchResultsTopHitsRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: topHits + - GET /searchresults/{query}/relationships/topHits + - Search for top hits by a query: artists, albums, tracks, videos. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: topHits (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getSearchResultsTopHitsRelationshipWithRequestBuilder(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/searchresults/{query}/relationships/topHits" + let queryPreEscape = "\(APIHelper.mapValueToPathItem(query))" + let queryPostEscape = queryPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{query}", with: queryPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: tracks + + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: tracks (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: TracksRelationshipsDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getSearchResultsTracksRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> TracksRelationshipsDocument { + return try await getSearchResultsTracksRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: tracks + - GET /searchresults/{query}/relationships/tracks + - Search for tracks by a query. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: tracks (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getSearchResultsTracksRelationshipWithRequestBuilder(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/searchresults/{query}/relationships/tracks" + let queryPreEscape = "\(APIHelper.mapValueToPathItem(query))" + let queryPostEscape = queryPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{query}", with: queryPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: videos + + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: videos (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: VideosRelationshipsDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getSearchResultsVideosRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> VideosRelationshipsDocument { + return try await getSearchResultsVideosRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: videos + - GET /searchresults/{query}/relationships/videos + - Search for videos by a query. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter query: (path) Search query + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: videos (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getSearchResultsVideosRelationshipWithRequestBuilder(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/searchresults/{query}/relationships/videos" + let queryPreEscape = "\(APIHelper.mapValueToPathItem(query))" + let queryPostEscape = queryPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{query}", with: queryPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift new file mode 100644 index 00000000..1bb033dc --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift @@ -0,0 +1,99 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `SearchResultsAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await SearchResultsAPI.getResource() +/// ``` +public enum SearchResultsAPITidal { + + + /** + Relationship: albums + + - returns: AlbumsRelationshipDocument + */ + public static func getSearchResultsAlbumsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await RequestHelper.createRequest { + SearchResultsAPI.getSearchResultsAlbumsRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: artists + + - returns: ArtistsRelationshipDocument + */ + public static func getSearchResultsArtistsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await RequestHelper.createRequest { + SearchResultsAPI.getSearchResultsArtistsRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Search for music metadata by a query + + - returns: SearchResultsSingleDataDocument + */ + public static func getSearchResultsByQuery(query: String, countryCode: String, include: [String]? = nil) async throws -> SearchResultsSingleDataDocument { + return try await RequestHelper.createRequest { + SearchResultsAPI.getSearchResultsByQueryWithRequestBuilder(query: query, countryCode: countryCode, include: include) + } + } + + + /** + Relationship: playlists + + - returns: PlaylistsRelationshipDocument + */ + public static func getSearchResultsPlaylistsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await RequestHelper.createRequest { + SearchResultsAPI.getSearchResultsPlaylistsRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: topHits + + - returns: SearchResultsTopHitsRelationshipDocument + */ + public static func getSearchResultsTopHitsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> SearchResultsTopHitsRelationshipDocument { + return try await RequestHelper.createRequest { + SearchResultsAPI.getSearchResultsTopHitsRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: tracks + + - returns: TracksRelationshipsDocument + */ + public static func getSearchResultsTracksRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> TracksRelationshipsDocument { + return try await RequestHelper.createRequest { + SearchResultsAPI.getSearchResultsTracksRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: videos + + - returns: VideosRelationshipsDocument + */ + public static func getSearchResultsVideosRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> VideosRelationshipsDocument { + return try await RequestHelper.createRequest { + SearchResultsAPI.getSearchResultsVideosRelationshipWithRequestBuilder(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift new file mode 100644 index 00000000..a67ceff9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift @@ -0,0 +1,408 @@ +// +// TracksAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class TracksAPI { + + /** + Relationship: albums + + - parameter id: (path) TIDAL track id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: AlbumsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getTrackAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await getTrackAlbumsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: albums + - GET /tracks/{id}/relationships/albums + - Retrieve album details of the related track. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL track id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getTrackAlbumsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/tracks/{id}/relationships/albums" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: artists + + - parameter id: (path) TIDAL track id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ArtistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getTrackArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await getTrackArtistsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: artists + - GET /tracks/{id}/relationships/artists + - Retrieve artist details of the related track. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL track id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getTrackArtistsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/tracks/{id}/relationships/artists" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get single track + + - parameter id: (path) TIDAL track id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio (optional) + - returns: TracksSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getTrackById(id: String, countryCode: String, include: [String]? = nil) async throws -> TracksSingleDataDocument { + return try await getTrackByIdWithRequestBuilder(id: id, countryCode: countryCode, include: include).execute().body + } + + /** + Get single track + - GET /tracks/{id} + - Retrieve track details by TIDAL track id. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL track id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio (optional) + - returns: RequestBuilder + */ + internal class func getTrackByIdWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/tracks/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: providers + + - parameter id: (path) TIDAL id of the track + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: providers (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ProvidersRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getTrackProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ProvidersRelationshipDocument { + return try await getTrackProvidersRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: providers + - GET /tracks/{id}/relationships/providers + - This endpoint can be used to retrieve a list of track's related providers. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the track + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: providers (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getTrackProvidersRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/tracks/{id}/relationships/providers" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: radio + + - parameter id: (path) TIDAL id of the track + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: radio (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: TracksRelationshipsDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getTrackRadioRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> TracksRelationshipsDocument { + return try await getTrackRadioRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: radio + - GET /tracks/{id}/relationships/radio + - This endpoint can be used to retrieve a list of radios for the given track. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the track + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: radio (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getTrackRadioRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/tracks/{id}/relationships/radio" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: similar tracks + + - parameter id: (path) TIDAL id of the track + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: similarTracks (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: TracksRelationshipsDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getTrackSimilarTracksRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> TracksRelationshipsDocument { + return try await getTrackSimilarTracksRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: similar tracks + - GET /tracks/{id}/relationships/similarTracks + - This endpoint can be used to retrieve a list of tracks similar to the given track. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the track + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: similarTracks (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getTrackSimilarTracksRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/tracks/{id}/relationships/similarTracks" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get multiple tracks + + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - parameter filterIsrc: (query) Allows to filter the collection of resources based on isrc attribute value (optional) + - returns: TracksMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getTracksByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterIsrc: [String]? = nil) async throws -> TracksMultiDataDocument { + return try await getTracksByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId, filterIsrc: filterIsrc).execute().body + } + + /** + Get multiple tracks + - GET /tracks + - Retrieve multiple track details. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - parameter filterIsrc: (query) Allows to filter the collection of resources based on isrc attribute value (optional) + - returns: RequestBuilder + */ + internal class func getTracksByFiltersWithRequestBuilder(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterIsrc: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/tracks" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + "filter[isrc]": (wrappedValue: filterIsrc?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift new file mode 100644 index 00000000..ef86cba8 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift @@ -0,0 +1,99 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `TracksAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await TracksAPI.getResource() +/// ``` +public enum TracksAPITidal { + + + /** + Relationship: albums + + - returns: AlbumsRelationshipDocument + */ + public static func getTrackAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await RequestHelper.createRequest { + TracksAPI.getTrackAlbumsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: artists + + - returns: ArtistsRelationshipDocument + */ + public static func getTrackArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await RequestHelper.createRequest { + TracksAPI.getTrackArtistsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Get single track + + - returns: TracksSingleDataDocument + */ + public static func getTrackById(id: String, countryCode: String, include: [String]? = nil) async throws -> TracksSingleDataDocument { + return try await RequestHelper.createRequest { + TracksAPI.getTrackByIdWithRequestBuilder(id: id, countryCode: countryCode, include: include) + } + } + + + /** + Relationship: providers + + - returns: ProvidersRelationshipDocument + */ + public static func getTrackProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ProvidersRelationshipDocument { + return try await RequestHelper.createRequest { + TracksAPI.getTrackProvidersRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: radio + + - returns: TracksRelationshipsDocument + */ + public static func getTrackRadioRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> TracksRelationshipsDocument { + return try await RequestHelper.createRequest { + TracksAPI.getTrackRadioRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: similar tracks + + - returns: TracksRelationshipsDocument + */ + public static func getTrackSimilarTracksRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> TracksRelationshipsDocument { + return try await RequestHelper.createRequest { + TracksAPI.getTrackSimilarTracksRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Get multiple tracks + + - returns: TracksMultiDataDocument + */ + public static func getTracksByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterIsrc: [String]? = nil) async throws -> TracksMultiDataDocument { + return try await RequestHelper.createRequest { + TracksAPI.getTracksByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId, filterIsrc: filterIsrc) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift new file mode 100644 index 00000000..61d7f6a3 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift @@ -0,0 +1,105 @@ +// +// UserEntitlementsAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class UserEntitlementsAPI { + + /** + Get the current users entitlements + + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - returns: UserEntitlementsSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getMyUserEntitlements(include: [String]? = nil) async throws -> UserEntitlementsSingleDataDocument { + return try await getMyUserEntitlementsWithRequestBuilder(include: include).execute().body + } + + /** + Get the current users entitlements + - GET /userEntitlements/me + - Get the current users entitlements + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - returns: RequestBuilder + */ + internal class func getMyUserEntitlementsWithRequestBuilder(include: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/userEntitlements/me" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get user entitlements for user + + - parameter id: (path) User entitlements id + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - returns: UserEntitlementsSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserEntitlementsById(id: String, include: [String]? = nil) async throws -> UserEntitlementsSingleDataDocument { + return try await getUserEntitlementsByIdWithRequestBuilder(id: id, include: include).execute().body + } + + /** + Get user entitlements for user + - GET /userEntitlements/{id} + - Get user entitlements for user + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User entitlements id + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - returns: RequestBuilder + */ + internal class func getUserEntitlementsByIdWithRequestBuilder(id: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/userEntitlements/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift new file mode 100644 index 00000000..5af6ccb1 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift @@ -0,0 +1,39 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `UserEntitlementsAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await UserEntitlementsAPI.getResource() +/// ``` +public enum UserEntitlementsAPITidal { + + + /** + Get the current users entitlements + + - returns: UserEntitlementsSingleDataDocument + */ + public static func getMyUserEntitlements(include: [String]? = nil) async throws -> UserEntitlementsSingleDataDocument { + return try await RequestHelper.createRequest { + UserEntitlementsAPI.getMyUserEntitlementsWithRequestBuilder(include: include) + } + } + + + /** + Get user entitlements for user + + - returns: UserEntitlementsSingleDataDocument + */ + public static func getUserEntitlementsById(id: String, include: [String]? = nil) async throws -> UserEntitlementsSingleDataDocument { + return try await RequestHelper.createRequest { + UserEntitlementsAPI.getUserEntitlementsByIdWithRequestBuilder(id: id, include: include) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift new file mode 100644 index 00000000..4fc7cf37 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift @@ -0,0 +1,273 @@ +// +// UserPublicProfilePicksAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class UserPublicProfilePicksAPI { + + /** + Get my picks + + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile (optional) + - returns: UserPublicProfilePicksMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getMyUserPublicProfilePicks(locale: String, include: [String]? = nil) async throws -> UserPublicProfilePicksMultiDataDocument { + return try await getMyUserPublicProfilePicksWithRequestBuilder(locale: locale, include: include).execute().body + } + + /** + Get my picks + - GET /userPublicProfilePicks/me + - Retrieves picks for the logged-in user. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile (optional) + - returns: RequestBuilder + */ + internal class func getMyUserPublicProfilePicksWithRequestBuilder(locale: String, include: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/userPublicProfilePicks/me" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "locale": (wrappedValue: locale.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: item (read) + + - parameter id: (path) TIDAL pick id + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: item (optional) + - returns: UserPublicProfilePicksItemRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfilePickItemRelationship(id: String, locale: String, include: [String]? = nil) async throws -> UserPublicProfilePicksItemRelationshipDocument { + return try await getUserPublicProfilePickItemRelationshipWithRequestBuilder(id: id, locale: locale, include: include).execute().body + } + + /** + Relationship: item (read) + - GET /userPublicProfilePicks/{id}/relationships/item + - Retrieves a picks item relationship + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL pick id + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: item (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfilePickItemRelationshipWithRequestBuilder(id: String, locale: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/userPublicProfilePicks/{id}/relationships/item" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "locale": (wrappedValue: locale.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: user public profile + + - parameter id: (path) TIDAL pick id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: userPublicProfile (optional) + - returns: UserPublicProfilesRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfilePickUserPublicProfileRelationship(id: String, include: [String]? = nil) async throws -> UserPublicProfilesRelationshipDocument { + return try await getUserPublicProfilePickUserPublicProfileRelationshipWithRequestBuilder(id: id, include: include).execute().body + } + + /** + Relationship: user public profile + - GET /userPublicProfilePicks/{id}/relationships/userPublicProfile + - Retrieves a picks owner public profile + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL pick id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: userPublicProfile (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfilePickUserPublicProfileRelationshipWithRequestBuilder(id: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/userPublicProfilePicks/{id}/relationships/userPublicProfile" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get picks + + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - parameter filterUserPublicProfileId: (query) Allows to filter the collection of resources based on userPublicProfile.id attribute value (optional) + - returns: UserPublicProfilePicksMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfilePicksByFilters(locale: String, include: [String]? = nil, filterId: [String]? = nil, filterUserPublicProfileId: [String]? = nil) async throws -> UserPublicProfilePicksMultiDataDocument { + return try await getUserPublicProfilePicksByFiltersWithRequestBuilder(locale: locale, include: include, filterId: filterId, filterUserPublicProfileId: filterUserPublicProfileId).execute().body + } + + /** + Get picks + - GET /userPublicProfilePicks + - Retrieves a filtered collection of user's public picks. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - parameter filterUserPublicProfileId: (query) Allows to filter the collection of resources based on userPublicProfile.id attribute value (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfilePicksByFiltersWithRequestBuilder(locale: String, include: [String]? = nil, filterId: [String]? = nil, filterUserPublicProfileId: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/userPublicProfilePicks" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "locale": (wrappedValue: locale.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + "filter[userPublicProfile.id]": (wrappedValue: filterUserPublicProfileId?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: item (update) + + - parameter id: (path) TIDAL pick id + - parameter updateUserPublicProfilePicksRelationshipDocument: (body) + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - returns: AnyCodable + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func setUserPublicProfilePickItemRelationship(id: String, updateUserPublicProfilePicksRelationshipDocument: UpdateUserPublicProfilePicksRelationshipDocument, include: [String]? = nil) async throws -> AnyCodable { + return try await setUserPublicProfilePickItemRelationshipWithRequestBuilder(id: id, updateUserPublicProfilePicksRelationshipDocument: updateUserPublicProfilePicksRelationshipDocument, include: include).execute().body + } + + /** + Relationship: item (update) + - PATCH /userPublicProfilePicks/{id}/relationships/item + - Updates a picks item relationship, e.g. sets a 'track', 'album' or 'artist' reference. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL pick id + - parameter updateUserPublicProfilePicksRelationshipDocument: (body) + - parameter include: (query) Allows the client to customize which related resources should be returned (optional) + - returns: RequestBuilder + */ + internal class func setUserPublicProfilePickItemRelationshipWithRequestBuilder(id: String, updateUserPublicProfilePicksRelationshipDocument: UpdateUserPublicProfilePicksRelationshipDocument, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/userPublicProfilePicks/{id}/relationships/item" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters = JSONEncodingHelper.encodingParameters(forEncodableObject: updateUserPublicProfilePicksRelationshipDocument) + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + "Content-Type": "application/vnd.api+json", + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "PATCH", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift new file mode 100644 index 00000000..843bbf61 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift @@ -0,0 +1,75 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `UserPublicProfilePicksAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await UserPublicProfilePicksAPI.getResource() +/// ``` +public enum UserPublicProfilePicksAPITidal { + + + /** + Get my picks + + - returns: UserPublicProfilePicksMultiDataDocument + */ + public static func getMyUserPublicProfilePicks(locale: String, include: [String]? = nil) async throws -> UserPublicProfilePicksMultiDataDocument { + return try await RequestHelper.createRequest { + UserPublicProfilePicksAPI.getMyUserPublicProfilePicksWithRequestBuilder(locale: locale, include: include) + } + } + + + /** + Relationship: item (read) + + - returns: UserPublicProfilePicksItemRelationshipDocument + */ + public static func getUserPublicProfilePickItemRelationship(id: String, locale: String, include: [String]? = nil) async throws -> UserPublicProfilePicksItemRelationshipDocument { + return try await RequestHelper.createRequest { + UserPublicProfilePicksAPI.getUserPublicProfilePickItemRelationshipWithRequestBuilder(id: id, locale: locale, include: include) + } + } + + + /** + Relationship: user public profile + + - returns: UserPublicProfilesRelationshipDocument + */ + public static func getUserPublicProfilePickUserPublicProfileRelationship(id: String, include: [String]? = nil) async throws -> UserPublicProfilesRelationshipDocument { + return try await RequestHelper.createRequest { + UserPublicProfilePicksAPI.getUserPublicProfilePickUserPublicProfileRelationshipWithRequestBuilder(id: id, include: include) + } + } + + + /** + Get picks + + - returns: UserPublicProfilePicksMultiDataDocument + */ + public static func getUserPublicProfilePicksByFilters(locale: String, include: [String]? = nil, filterId: [String]? = nil, filterUserPublicProfileId: [String]? = nil) async throws -> UserPublicProfilePicksMultiDataDocument { + return try await RequestHelper.createRequest { + UserPublicProfilePicksAPI.getUserPublicProfilePicksByFiltersWithRequestBuilder(locale: locale, include: include, filterId: filterId, filterUserPublicProfileId: filterUserPublicProfileId) + } + } + + + /** + Relationship: item (update) + + - returns: AnyCodable + */ + public static func setUserPublicProfilePickItemRelationship(id: String, updateUserPublicProfilePicksRelationshipDocument: UpdateUserPublicProfilePicksRelationshipDocument, include: [String]? = nil) async throws -> AnyCodable { + return try await RequestHelper.createRequest { + UserPublicProfilePicksAPI.setUserPublicProfilePickItemRelationshipWithRequestBuilder(id: id, updateUserPublicProfilePicksRelationshipDocument: updateUserPublicProfilePicksRelationshipDocument, include: include) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift new file mode 100644 index 00000000..243c7d31 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift @@ -0,0 +1,385 @@ +// +// UserPublicProfilesAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class UserPublicProfilesAPI { + + /** + Get my user profile + + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) + - returns: UserPublicProfilesSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getMyUserPublicProfile(locale: String, include: [String]? = nil) async throws -> UserPublicProfilesSingleDataDocument { + return try await getMyUserPublicProfileWithRequestBuilder(locale: locale, include: include).execute().body + } + + /** + Get my user profile + - GET /userPublicProfiles/me + - Retrieve the logged-in user's public profile details. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) + - returns: RequestBuilder + */ + internal class func getMyUserPublicProfileWithRequestBuilder(locale: String, include: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/userPublicProfiles/me" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "locale": (wrappedValue: locale.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get user public profile by id + + - parameter id: (path) TIDAL user id + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) + - returns: UserPublicProfilesSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfileById(id: String, locale: String, include: [String]? = nil) async throws -> UserPublicProfilesSingleDataDocument { + return try await getUserPublicProfileByIdWithRequestBuilder(id: id, locale: locale, include: include).execute().body + } + + /** + Get user public profile by id + - GET /userPublicProfiles/{id} + - Retrieve user public profile details by TIDAL user id. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL user id + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfileByIdWithRequestBuilder(id: String, locale: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/userPublicProfiles/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "locale": (wrappedValue: locale.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: followers + + - parameter id: (path) TIDAL user id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: followers (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: UsersRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfileFollowersRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> UsersRelationshipDocument { + return try await getUserPublicProfileFollowersRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: followers + - GET /userPublicProfiles/{id}/relationships/followers + - Retrieve user's public followers + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL user id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: followers (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfileFollowersRelationshipWithRequestBuilder(id: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/userPublicProfiles/{id}/relationships/followers" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: following + + - parameter id: (path) TIDAL user id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: following (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: UsersRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfileFollowingRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> UsersRelationshipDocument { + return try await getUserPublicProfileFollowingRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: following + - GET /userPublicProfiles/{id}/relationships/following + - Retrieve user's public followings + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL user id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: following (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfileFollowingRelationshipWithRequestBuilder(id: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/userPublicProfiles/{id}/relationships/following" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: picks + + - parameter id: (path) TIDAL user id + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPicks (optional) + - returns: UserPublicProfilePicksRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfilePublicPicksRelationship(id: String, locale: String, include: [String]? = nil) async throws -> UserPublicProfilePicksRelationshipDocument { + return try await getUserPublicProfilePublicPicksRelationshipWithRequestBuilder(id: id, locale: locale, include: include).execute().body + } + + /** + Relationship: picks + - GET /userPublicProfiles/{id}/relationships/publicPicks + - Retrieve user's public picks. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL user id + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPicks (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfilePublicPicksRelationshipWithRequestBuilder(id: String, locale: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/userPublicProfiles/{id}/relationships/publicPicks" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "locale": (wrappedValue: locale.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: playlists + + - parameter id: (path) TIDAL user id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPlaylists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: PlaylistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfilePublicPlaylistsRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await getUserPublicProfilePublicPlaylistsRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: playlists + - GET /userPublicProfiles/{id}/relationships/publicPlaylists + - Retrieves user's public playlists. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL user id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPlaylists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfilePublicPlaylistsRelationshipWithRequestBuilder(id: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/userPublicProfiles/{id}/relationships/publicPlaylists" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get user public profiles + + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) + - parameter filterId: (query) TIDAL user id (optional) + - returns: UserPublicProfilesMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfilesByFilters(locale: String, include: [String]? = nil, filterId: [String]? = nil) async throws -> UserPublicProfilesMultiDataDocument { + return try await getUserPublicProfilesByFiltersWithRequestBuilder(locale: locale, include: include, filterId: filterId).execute().body + } + + /** + Get user public profiles + - GET /userPublicProfiles + - Reads user public profile details by TIDAL user ids. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) + - parameter filterId: (query) TIDAL user id (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfilesByFiltersWithRequestBuilder(locale: String, include: [String]? = nil, filterId: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/userPublicProfiles" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "locale": (wrappedValue: locale.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift new file mode 100644 index 00000000..eb83b9d9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift @@ -0,0 +1,99 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `UserPublicProfilesAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await UserPublicProfilesAPI.getResource() +/// ``` +public enum UserPublicProfilesAPITidal { + + + /** + Get my user profile + + - returns: UserPublicProfilesSingleDataDocument + */ + public static func getMyUserPublicProfile(locale: String, include: [String]? = nil) async throws -> UserPublicProfilesSingleDataDocument { + return try await RequestHelper.createRequest { + UserPublicProfilesAPI.getMyUserPublicProfileWithRequestBuilder(locale: locale, include: include) + } + } + + + /** + Get user public profile by id + + - returns: UserPublicProfilesSingleDataDocument + */ + public static func getUserPublicProfileById(id: String, locale: String, include: [String]? = nil) async throws -> UserPublicProfilesSingleDataDocument { + return try await RequestHelper.createRequest { + UserPublicProfilesAPI.getUserPublicProfileByIdWithRequestBuilder(id: id, locale: locale, include: include) + } + } + + + /** + Relationship: followers + + - returns: UsersRelationshipDocument + */ + public static func getUserPublicProfileFollowersRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> UsersRelationshipDocument { + return try await RequestHelper.createRequest { + UserPublicProfilesAPI.getUserPublicProfileFollowersRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: following + + - returns: UsersRelationshipDocument + */ + public static func getUserPublicProfileFollowingRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> UsersRelationshipDocument { + return try await RequestHelper.createRequest { + UserPublicProfilesAPI.getUserPublicProfileFollowingRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: picks + + - returns: UserPublicProfilePicksRelationshipDocument + */ + public static func getUserPublicProfilePublicPicksRelationship(id: String, locale: String, include: [String]? = nil) async throws -> UserPublicProfilePicksRelationshipDocument { + return try await RequestHelper.createRequest { + UserPublicProfilesAPI.getUserPublicProfilePublicPicksRelationshipWithRequestBuilder(id: id, locale: locale, include: include) + } + } + + + /** + Relationship: playlists + + - returns: PlaylistsRelationshipDocument + */ + public static func getUserPublicProfilePublicPlaylistsRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await RequestHelper.createRequest { + UserPublicProfilesAPI.getUserPublicProfilePublicPlaylistsRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor) + } + } + + + /** + Get user public profiles + + - returns: UserPublicProfilesMultiDataDocument + */ + public static func getUserPublicProfilesByFilters(locale: String, include: [String]? = nil, filterId: [String]? = nil) async throws -> UserPublicProfilesMultiDataDocument { + return try await RequestHelper.createRequest { + UserPublicProfilesAPI.getUserPublicProfilesByFiltersWithRequestBuilder(locale: locale, include: include, filterId: filterId) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift new file mode 100644 index 00000000..2c34208d --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift @@ -0,0 +1,304 @@ +// +// UserRecommendationsAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class UserRecommendationsAPI { + + /** + Get the current users recommendations + + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) + - returns: UserRecommendationsSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getMyUserRecommendations(include: [String]? = nil) async throws -> UserRecommendationsSingleDataDocument { + return try await getMyUserRecommendationsWithRequestBuilder(include: include).execute().body + } + + /** + Get the current users recommendations + - GET /userRecommendations/me + - Get the current users recommendations + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) + - returns: RequestBuilder + */ + internal class func getMyUserRecommendationsWithRequestBuilder(include: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/userRecommendations/me" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get recommendations for users in batch + + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) + - parameter filterId: (query) User recommendations id (optional) + - returns: UserRecommendationsMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserRecommendationsByFilters(include: [String]? = nil, filterId: [String]? = nil) async throws -> UserRecommendationsMultiDataDocument { + return try await getUserRecommendationsByFiltersWithRequestBuilder(include: include, filterId: filterId).execute().body + } + + /** + Get recommendations for users in batch + - GET /userRecommendations + - Get recommendations for users in batch + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) + - parameter filterId: (query) User recommendations id (optional) + - returns: RequestBuilder + */ + internal class func getUserRecommendationsByFiltersWithRequestBuilder(include: [String]? = nil, filterId: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/userRecommendations" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get user recommendations for user + + - parameter id: (path) User recommendations id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) + - returns: UserRecommendationsSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserRecommendationsById(id: String, include: [String]? = nil) async throws -> UserRecommendationsSingleDataDocument { + return try await getUserRecommendationsByIdWithRequestBuilder(id: id, include: include).execute().body + } + + /** + Get user recommendations for user + - GET /userRecommendations/{id} + - Get user recommendations for user + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User recommendations id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) + - returns: RequestBuilder + */ + internal class func getUserRecommendationsByIdWithRequestBuilder(id: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/userRecommendations/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: discovery mixes + + - parameter id: (path) User recommendations id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: discoveryMixes (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: PlaylistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserRecommendationsDiscoveryMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await getUserRecommendationsDiscoveryMixesRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: discovery mixes + - GET /userRecommendations/{id}/relationships/discoveryMixes + - Get discovery mixes relationship + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User recommendations id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: discoveryMixes (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getUserRecommendationsDiscoveryMixesRelationshipWithRequestBuilder(id: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/userRecommendations/{id}/relationships/discoveryMixes" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: my mixes + + - parameter id: (path) User recommendations id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: myMixes (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: PlaylistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserRecommendationsMyMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await getUserRecommendationsMyMixesRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: my mixes + - GET /userRecommendations/{id}/relationships/myMixes + - Get my mixes relationship + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User recommendations id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: myMixes (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getUserRecommendationsMyMixesRelationshipWithRequestBuilder(id: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/userRecommendations/{id}/relationships/myMixes" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: new arrivals mixes + + - parameter id: (path) User recommendations id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: newArrivalMixes (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: PlaylistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserRecommendationsNewArrivalMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await getUserRecommendationsNewArrivalMixesRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: new arrivals mixes + - GET /userRecommendations/{id}/relationships/newArrivalMixes + - Get new arrival mixes relationship + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User recommendations id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: newArrivalMixes (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getUserRecommendationsNewArrivalMixesRelationshipWithRequestBuilder(id: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/userRecommendations/{id}/relationships/newArrivalMixes" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift new file mode 100644 index 00000000..ab178a12 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift @@ -0,0 +1,87 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `UserRecommendationsAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await UserRecommendationsAPI.getResource() +/// ``` +public enum UserRecommendationsAPITidal { + + + /** + Get the current users recommendations + + - returns: UserRecommendationsSingleDataDocument + */ + public static func getMyUserRecommendations(include: [String]? = nil) async throws -> UserRecommendationsSingleDataDocument { + return try await RequestHelper.createRequest { + UserRecommendationsAPI.getMyUserRecommendationsWithRequestBuilder(include: include) + } + } + + + /** + Get recommendations for users in batch + + - returns: UserRecommendationsMultiDataDocument + */ + public static func getUserRecommendationsByFilters(include: [String]? = nil, filterId: [String]? = nil) async throws -> UserRecommendationsMultiDataDocument { + return try await RequestHelper.createRequest { + UserRecommendationsAPI.getUserRecommendationsByFiltersWithRequestBuilder(include: include, filterId: filterId) + } + } + + + /** + Get user recommendations for user + + - returns: UserRecommendationsSingleDataDocument + */ + public static func getUserRecommendationsById(id: String, include: [String]? = nil) async throws -> UserRecommendationsSingleDataDocument { + return try await RequestHelper.createRequest { + UserRecommendationsAPI.getUserRecommendationsByIdWithRequestBuilder(id: id, include: include) + } + } + + + /** + Relationship: discovery mixes + + - returns: PlaylistsRelationshipDocument + */ + public static func getUserRecommendationsDiscoveryMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await RequestHelper.createRequest { + UserRecommendationsAPI.getUserRecommendationsDiscoveryMixesRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: my mixes + + - returns: PlaylistsRelationshipDocument + */ + public static func getUserRecommendationsMyMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await RequestHelper.createRequest { + UserRecommendationsAPI.getUserRecommendationsMyMixesRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: new arrivals mixes + + - returns: PlaylistsRelationshipDocument + */ + public static func getUserRecommendationsNewArrivalMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> PlaylistsRelationshipDocument { + return try await RequestHelper.createRequest { + UserRecommendationsAPI.getUserRecommendationsNewArrivalMixesRelationshipWithRequestBuilder(id: id, include: include, pageCursor: pageCursor) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift new file mode 100644 index 00000000..70e24733 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift @@ -0,0 +1,298 @@ +// +// UsersAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class UsersAPI { + + /** + Get the current user + + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) + - returns: UsersSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getMyUser(include: [String]? = nil) async throws -> UsersSingleDataDocument { + return try await getMyUserWithRequestBuilder(include: include).execute().body + } + + /** + Get the current user + - GET /users/me + - Get the current user + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) + - returns: RequestBuilder + */ + internal class func getMyUserWithRequestBuilder(include: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/users/me" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get a single user by id + + - parameter id: (path) User Id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) + - returns: UsersSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserById(id: String, include: [String]? = nil) async throws -> UsersSingleDataDocument { + return try await getUserByIdWithRequestBuilder(id: id, include: include).execute().body + } + + /** + Get a single user by id + - GET /users/{id} + - Get a single user by id + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User Id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) + - returns: RequestBuilder + */ + internal class func getUserByIdWithRequestBuilder(id: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/users/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: entitlements + + - parameter id: (path) User Id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: entitlements (optional) + - returns: UserEntitlementsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserEntitlementsRelationship(id: String, include: [String]? = nil) async throws -> UserEntitlementsRelationshipDocument { + return try await getUserEntitlementsRelationshipWithRequestBuilder(id: id, include: include).execute().body + } + + /** + Relationship: entitlements + - GET /users/{id}/relationships/entitlements + - Get user entitlements relationship + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User Id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: entitlements (optional) + - returns: RequestBuilder + */ + internal class func getUserEntitlementsRelationshipWithRequestBuilder(id: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/users/{id}/relationships/entitlements" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: public profile + + - parameter id: (path) User Id + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicProfile (optional) + - returns: UserPublicProfilesRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserPublicProfileRelationship(id: String, locale: String, include: [String]? = nil) async throws -> UserPublicProfilesRelationshipDocument { + return try await getUserPublicProfileRelationshipWithRequestBuilder(id: id, locale: locale, include: include).execute().body + } + + /** + Relationship: public profile + - GET /users/{id}/relationships/publicProfile + - Get user public profile + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User Id + - parameter locale: (query) Locale language tag (IETF BCP 47 Language Tag) + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: publicProfile (optional) + - returns: RequestBuilder + */ + internal class func getUserPublicProfileRelationshipWithRequestBuilder(id: String, locale: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/users/{id}/relationships/publicProfile" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "locale": (wrappedValue: locale.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: user recommendations + + - parameter id: (path) User Id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: recommendations (optional) + - returns: UsersRecommendationsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUserRecommendationsRelationship(id: String, include: [String]? = nil) async throws -> UsersRecommendationsRelationshipDocument { + return try await getUserRecommendationsRelationshipWithRequestBuilder(id: id, include: include).execute().body + } + + /** + Relationship: user recommendations + - GET /users/{id}/relationships/recommendations + - Get user recommendations + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) User Id + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: recommendations (optional) + - returns: RequestBuilder + */ + internal class func getUserRecommendationsRelationshipWithRequestBuilder(id: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/users/{id}/relationships/recommendations" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get multiple users by id + + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - returns: UsersMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getUsersByFilters(include: [String]? = nil, filterId: [String]? = nil) async throws -> UsersMultiDataDocument { + return try await getUsersByFiltersWithRequestBuilder(include: include, filterId: filterId).execute().body + } + + /** + Get multiple users by id + - GET /users + - Get multiple users by id + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - returns: RequestBuilder + */ + internal class func getUsersByFiltersWithRequestBuilder(include: [String]? = nil, filterId: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/users" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift new file mode 100644 index 00000000..d6b10d5f --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift @@ -0,0 +1,87 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `UsersAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await UsersAPI.getResource() +/// ``` +public enum UsersAPITidal { + + + /** + Get the current user + + - returns: UsersSingleDataDocument + */ + public static func getMyUser(include: [String]? = nil) async throws -> UsersSingleDataDocument { + return try await RequestHelper.createRequest { + UsersAPI.getMyUserWithRequestBuilder(include: include) + } + } + + + /** + Get a single user by id + + - returns: UsersSingleDataDocument + */ + public static func getUserById(id: String, include: [String]? = nil) async throws -> UsersSingleDataDocument { + return try await RequestHelper.createRequest { + UsersAPI.getUserByIdWithRequestBuilder(id: id, include: include) + } + } + + + /** + Relationship: entitlements + + - returns: UserEntitlementsRelationshipDocument + */ + public static func getUserEntitlementsRelationship(id: String, include: [String]? = nil) async throws -> UserEntitlementsRelationshipDocument { + return try await RequestHelper.createRequest { + UsersAPI.getUserEntitlementsRelationshipWithRequestBuilder(id: id, include: include) + } + } + + + /** + Relationship: public profile + + - returns: UserPublicProfilesRelationshipDocument + */ + public static func getUserPublicProfileRelationship(id: String, locale: String, include: [String]? = nil) async throws -> UserPublicProfilesRelationshipDocument { + return try await RequestHelper.createRequest { + UsersAPI.getUserPublicProfileRelationshipWithRequestBuilder(id: id, locale: locale, include: include) + } + } + + + /** + Relationship: user recommendations + + - returns: UsersRecommendationsRelationshipDocument + */ + public static func getUserRecommendationsRelationship(id: String, include: [String]? = nil) async throws -> UsersRecommendationsRelationshipDocument { + return try await RequestHelper.createRequest { + UsersAPI.getUserRecommendationsRelationshipWithRequestBuilder(id: id, include: include) + } + } + + + /** + Get multiple users by id + + - returns: UsersMultiDataDocument + */ + public static func getUsersByFilters(include: [String]? = nil, filterId: [String]? = nil) async throws -> UsersMultiDataDocument { + return try await RequestHelper.createRequest { + UsersAPI.getUsersByFiltersWithRequestBuilder(include: include, filterId: filterId) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift new file mode 100644 index 00000000..59875244 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift @@ -0,0 +1,294 @@ +// +// VideosAPI.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +internal class VideosAPI { + + /** + Relationship: albums + + - parameter id: (path) TIDAL video id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: AlbumsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getVideoAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await getVideoAlbumsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: albums + - GET /videos/{id}/relationships/albums + - Retrieve album details of the related video. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL video id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: albums (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getVideoAlbumsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/videos/{id}/relationships/albums" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: artists + + - parameter id: (path) TIDAL video id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ArtistsRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getVideoArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await getVideoArtistsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: artists + - GET /videos/{id}/relationships/artists + - Retrieve artist details of the related video. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL video id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getVideoArtistsRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/videos/{id}/relationships/artists" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get single video + + - parameter id: (path) TIDAL video id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, providers (optional) + - returns: VideosSingleDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getVideoById(id: String, countryCode: String, include: [String]? = nil) async throws -> VideosSingleDataDocument { + return try await getVideoByIdWithRequestBuilder(id: id, countryCode: countryCode, include: include).execute().body + } + + /** + Get single video + - GET /videos/{id} + - Retrieve video details by TIDAL video id. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL video id + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, providers (optional) + - returns: RequestBuilder + */ + internal class func getVideoByIdWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil) -> RequestBuilder { + var localVariablePath = "/videos/{id}" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Relationship: providers + + - parameter id: (path) TIDAL id of the video + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: providers (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: ProvidersRelationshipDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getVideoProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ProvidersRelationshipDocument { + return try await getVideoProvidersRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor).execute().body + } + + /** + Relationship: providers + - GET /videos/{id}/relationships/providers + - This endpoint can be used to retrieve a list of video's related providers. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter id: (path) TIDAL id of the video + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: providers (optional) + - parameter pageCursor: (query) Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + - returns: RequestBuilder + */ + internal class func getVideoProvidersRelationshipWithRequestBuilder(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) -> RequestBuilder { + var localVariablePath = "/videos/{id}/relationships/providers" + let idPreEscape = "\(APIHelper.mapValueToPathItem(id))" + let idPostEscape = idPreEscape.addingPercentEncoding(withAllowedCharacters: .urlPathAllowed) ?? "" + localVariablePath = localVariablePath.replacingOccurrences(of: "{id}", with: idPostEscape, options: .literal, range: nil) + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "page[cursor]": (wrappedValue: pageCursor?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } + + /** + Get multiple videos + + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, providers (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - parameter filterIsrc: (query) Allows to filter the collection of resources based on isrc attribute value (optional) + - returns: VideosMultiDataDocument + */ + @available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *) + internal class func getVideosByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterIsrc: [String]? = nil) async throws -> VideosMultiDataDocument { + return try await getVideosByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId, filterIsrc: filterIsrc).execute().body + } + + /** + Get multiple videos + - GET /videos + - Retrieve multiple video details. + - OAuth: + - type: oauth2 + - name: Authorization_Code_PKCE + - OAuth: + - type: oauth2 + - name: Client_Credentials + - responseHeaders: [X-RateLimit-Remaining(Int), X-RateLimit-Burst-Capacity(Int), X-RateLimit-Replenish-Rate(Int), X-RateLimit-Requested-Tokens(Int)] + - parameter countryCode: (query) ISO 3166-1 alpha-2 country code + - parameter include: (query) Allows the client to customize which related resources should be returned. Available options: artists, albums, providers (optional) + - parameter filterId: (query) Allows to filter the collection of resources based on id attribute value (optional) + - parameter filterIsrc: (query) Allows to filter the collection of resources based on isrc attribute value (optional) + - returns: RequestBuilder + */ + internal class func getVideosByFiltersWithRequestBuilder(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterIsrc: [String]? = nil) -> RequestBuilder { + let localVariablePath = "/videos" + let localVariableURLString = OpenAPIClientAPI.basePath + localVariablePath + let localVariableParameters: [String: Any]? = nil + + var localVariableUrlComponents = URLComponents(string: localVariableURLString) + localVariableUrlComponents?.queryItems = APIHelper.mapValuesToQueryItems([ + "countryCode": (wrappedValue: countryCode.encodeToJSON(), isExplode: true), + "include": (wrappedValue: include?.encodeToJSON(), isExplode: true), + "filter[id]": (wrappedValue: filterId?.encodeToJSON(), isExplode: true), + "filter[isrc]": (wrappedValue: filterIsrc?.encodeToJSON(), isExplode: true), + ]) + + let localVariableNillableHeaders: [String: Any?] = [ + : + ] + + let localVariableHeaderParameters = APIHelper.rejectNilHeaders(localVariableNillableHeaders) + + let localVariableRequestBuilder: RequestBuilder.Type = OpenAPIClientAPI.requestBuilderFactory.getBuilder() + + return localVariableRequestBuilder.init(method: "GET", URLString: (localVariableUrlComponents?.string ?? localVariableURLString), parameters: localVariableParameters, headers: localVariableHeaderParameters, requiresAuthentication: true) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift new file mode 100644 index 00000000..23386861 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift @@ -0,0 +1,75 @@ +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/// This is a wrapper around `VideosAPI` that uses the injected credentialsprovider +/// from `OpenAPIClientAPI.credentialsProvider` to provide a convenience API. +/// +/// Usage example: +/// ```swift +/// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared +/// let dataDocument = try await VideosAPI.getResource() +/// ``` +public enum VideosAPITidal { + + + /** + Relationship: albums + + - returns: AlbumsRelationshipDocument + */ + public static func getVideoAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> AlbumsRelationshipDocument { + return try await RequestHelper.createRequest { + VideosAPI.getVideoAlbumsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Relationship: artists + + - returns: ArtistsRelationshipDocument + */ + public static func getVideoArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ArtistsRelationshipDocument { + return try await RequestHelper.createRequest { + VideosAPI.getVideoArtistsRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Get single video + + - returns: VideosSingleDataDocument + */ + public static func getVideoById(id: String, countryCode: String, include: [String]? = nil) async throws -> VideosSingleDataDocument { + return try await RequestHelper.createRequest { + VideosAPI.getVideoByIdWithRequestBuilder(id: id, countryCode: countryCode, include: include) + } + } + + + /** + Relationship: providers + + - returns: ProvidersRelationshipDocument + */ + public static func getVideoProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil) async throws -> ProvidersRelationshipDocument { + return try await RequestHelper.createRequest { + VideosAPI.getVideoProvidersRelationshipWithRequestBuilder(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) + } + } + + + /** + Get multiple videos + + - returns: VideosMultiDataDocument + */ + public static func getVideosByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterIsrc: [String]? = nil) async throws -> VideosMultiDataDocument { + return try await RequestHelper.createRequest { + VideosAPI.getVideosByFiltersWithRequestBuilder(countryCode: countryCode, include: include, filterId: filterId, filterIsrc: filterIsrc) + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift new file mode 100644 index 00000000..09c82e53 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift @@ -0,0 +1,49 @@ +// +// CodableHelper.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +open class CodableHelper { + private static var customDateFormatter: DateFormatter? + private static var defaultDateFormatter: DateFormatter = OpenISO8601DateFormatter() + + private static var customJSONDecoder: JSONDecoder? + private static var defaultJSONDecoder: JSONDecoder = { + let decoder = JSONDecoder() + decoder.dateDecodingStrategy = .formatted(CodableHelper.dateFormatter) + return decoder + }() + + private static var customJSONEncoder: JSONEncoder? + private static var defaultJSONEncoder: JSONEncoder = { + let encoder = JSONEncoder() + encoder.dateEncodingStrategy = .formatted(CodableHelper.dateFormatter) + encoder.outputFormatting = .prettyPrinted + return encoder + }() + + public static var dateFormatter: DateFormatter { + get { return customDateFormatter ?? defaultDateFormatter } + set { customDateFormatter = newValue } + } + public static var jsonDecoder: JSONDecoder { + get { return customJSONDecoder ?? defaultJSONDecoder } + set { customJSONDecoder = newValue } + } + public static var jsonEncoder: JSONEncoder { + get { return customJSONEncoder ?? defaultJSONEncoder } + set { customJSONEncoder = newValue } + } + + open class func decode(_ type: T.Type, from data: Data) -> Swift.Result where T: Decodable { + return Swift.Result { try jsonDecoder.decode(type, from: data) } + } + + open class func encode(_ value: T) -> Swift.Result where T: Encodable { + return Swift.Result { try jsonEncoder.encode(value) } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift new file mode 100644 index 00000000..0457d990 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift @@ -0,0 +1,18 @@ +// Configuration.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(FoundationNetworking) +import FoundationNetworking +#endif + +open class Configuration { + + /// Configures the range of HTTP status codes that will result in a successful response + /// + /// If a HTTP status code is outside of this range the response will be interpreted as failed. + public static var successfulStatusCodeRange: Range = 200..<300 +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift new file mode 100644 index 00000000..286c5001 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift @@ -0,0 +1,236 @@ +// Extensions.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(FoundationNetworking) +import FoundationNetworking +#endif +#if canImport(AnyCodable) +import AnyCodable +#endif + +extension Bool: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension Float: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension Int: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension Int32: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension Int64: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension Double: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension Decimal: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension String: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension URL: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension UUID: JSONEncodable { + func encodeToJSON() -> Any { self } +} + +extension RawRepresentable where RawValue: JSONEncodable { + func encodeToJSON() -> Any { return self.rawValue } +} + +private func encodeIfPossible(_ object: T) -> Any { + if let encodableObject = object as? JSONEncodable { + return encodableObject.encodeToJSON() + } else { + return object + } +} + +extension Array: JSONEncodable { + func encodeToJSON() -> Any { + return self.map(encodeIfPossible) + } +} + +extension Set: JSONEncodable { + func encodeToJSON() -> Any { + return Array(self).encodeToJSON() + } +} + +extension Dictionary: JSONEncodable { + func encodeToJSON() -> Any { + var dictionary = [AnyHashable: Any]() + for (key, value) in self { + dictionary[key] = encodeIfPossible(value) + } + return dictionary + } +} + +extension Data: JSONEncodable { + func encodeToJSON() -> Any { + return self.base64EncodedString(options: Data.Base64EncodingOptions()) + } +} + +extension Date: JSONEncodable { + func encodeToJSON() -> Any { + return CodableHelper.dateFormatter.string(from: self) + } +} + +extension JSONEncodable where Self: Encodable { + func encodeToJSON() -> Any { + guard let data = try? CodableHelper.jsonEncoder.encode(self) else { + fatalError("Could not encode to json: \(self)") + } + return data.encodeToJSON() + } +} + +extension String: CodingKey { + + public var stringValue: String { + return self + } + + public init?(stringValue: String) { + self.init(stringLiteral: stringValue) + } + + public var intValue: Int? { + return nil + } + + public init?(intValue: Int) { + return nil + } + +} + +extension KeyedEncodingContainerProtocol { + + public mutating func encodeArray(_ values: [T], forKey key: Self.Key) throws where T: Encodable { + var arrayContainer = nestedUnkeyedContainer(forKey: key) + try arrayContainer.encode(contentsOf: values) + } + + public mutating func encodeArrayIfPresent(_ values: [T]?, forKey key: Self.Key) throws where T: Encodable { + if let values = values { + try encodeArray(values, forKey: key) + } + } + + public mutating func encodeMap(_ pairs: [Self.Key: T]) throws where T: Encodable { + for (key, value) in pairs { + try encode(value, forKey: key) + } + } + + public mutating func encodeMapIfPresent(_ pairs: [Self.Key: T]?) throws where T: Encodable { + if let pairs = pairs { + try encodeMap(pairs) + } + } + + public mutating func encode(_ value: Decimal, forKey key: Self.Key) throws { + let decimalNumber = NSDecimalNumber(decimal: value) + let numberFormatter = NumberFormatter() + numberFormatter.numberStyle = .decimal + numberFormatter.locale = Locale(identifier: "en_US") + let formattedString = numberFormatter.string(from: decimalNumber) ?? "\(value)" + try encode(formattedString, forKey: key) + } + + public mutating func encodeIfPresent(_ value: Decimal?, forKey key: Self.Key) throws { + if let value = value { + try encode(value, forKey: key) + } + } +} + +extension KeyedDecodingContainerProtocol { + + public func decodeArray(_ type: T.Type, forKey key: Self.Key) throws -> [T] where T: Decodable { + var tmpArray = [T]() + + var nestedContainer = try nestedUnkeyedContainer(forKey: key) + while !nestedContainer.isAtEnd { + let arrayValue = try nestedContainer.decode(T.self) + tmpArray.append(arrayValue) + } + + return tmpArray + } + + public func decodeArrayIfPresent(_ type: T.Type, forKey key: Self.Key) throws -> [T]? where T: Decodable { + var tmpArray: [T]? + + if contains(key) { + tmpArray = try decodeArray(T.self, forKey: key) + } + + return tmpArray + } + + public func decodeMap(_ type: T.Type, excludedKeys: Set) throws -> [Self.Key: T] where T: Decodable { + var map: [Self.Key: T] = [:] + + for key in allKeys { + if !excludedKeys.contains(key) { + let value = try decode(T.self, forKey: key) + map[key] = value + } + } + + return map + } + + public func decode(_ type: Decimal.Type, forKey key: Self.Key) throws -> Decimal { + let stringValue = try decode(String.self, forKey: key) + guard let decimalValue = Decimal(string: stringValue) else { + let context = DecodingError.Context(codingPath: [key], debugDescription: "The key \(key) couldn't be converted to a Decimal value") + throw DecodingError.typeMismatch(type, context) + } + + return decimalValue + } + + public func decodeIfPresent(_ type: Decimal.Type, forKey key: Self.Key) throws -> Decimal? { + guard let stringValue = try decodeIfPresent(String.self, forKey: key) else { + return nil + } + guard let decimalValue = Decimal(string: stringValue) else { + let context = DecodingError.Context(codingPath: [key], debugDescription: "The key \(key) couldn't be converted to a Decimal value") + throw DecodingError.typeMismatch(type, context) + } + + return decimalValue + } + +} + +extension HTTPURLResponse { + var isStatusCodeSuccessful: Bool { + return Configuration.successfulStatusCodeRange.contains(statusCode) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift new file mode 100644 index 00000000..cb3121a4 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift @@ -0,0 +1,56 @@ +// +// JSONDataEncoding.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(FoundationNetworking) +import FoundationNetworking +#endif + +public struct JSONDataEncoding { + + // MARK: Properties + + private static let jsonDataKey = "jsonData" + + // MARK: Encoding + + /// Creates a URL request by encoding parameters and applying them onto an existing request. + /// + /// - parameter urlRequest: The request to have parameters applied. + /// - parameter parameters: The parameters to apply. This should have a single key/value + /// pair with "jsonData" as the key and a Data object as the value. + /// + /// - throws: An `Error` if the encoding process encounters an error. + /// + /// - returns: The encoded request. + public func encode(_ urlRequest: URLRequest, with parameters: [String: Any]?) -> URLRequest { + var urlRequest = urlRequest + + guard let jsonData = parameters?[JSONDataEncoding.jsonDataKey] as? Data, !jsonData.isEmpty else { + return urlRequest + } + + if urlRequest.value(forHTTPHeaderField: "Content-Type") == nil { + urlRequest.setValue("application/json", forHTTPHeaderField: "Content-Type") + } + + urlRequest.httpBody = jsonData + + return urlRequest + } + + public static func encodingParameters(jsonData: Data?) -> [String: Any]? { + var returnedParams: [String: Any]? + if let jsonData = jsonData, !jsonData.isEmpty { + var params: [String: Any] = [:] + params[jsonDataKey] = jsonData + returnedParams = params + } + return returnedParams + } + +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift new file mode 100644 index 00000000..02f78ffb --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift @@ -0,0 +1,45 @@ +// +// JSONEncodingHelper.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +open class JSONEncodingHelper { + + open class func encodingParameters(forEncodableObject encodableObj: T?) -> [String: Any]? { + var params: [String: Any]? + + // Encode the Encodable object + if let encodableObj = encodableObj { + let encodeResult = CodableHelper.encode(encodableObj) + do { + let data = try encodeResult.get() + params = JSONDataEncoding.encodingParameters(jsonData: data) + } catch { + print(error.localizedDescription) + } + } + + return params + } + + open class func encodingParameters(forEncodableObject encodableObj: Any?) -> [String: Any]? { + var params: [String: Any]? + + if let encodableObj = encodableObj { + do { + let data = try JSONSerialization.data(withJSONObject: encodableObj, options: .prettyPrinted) + params = JSONDataEncoding.encodingParameters(jsonData: data) + } catch { + print(error.localizedDescription) + return nil + } + } + + return params + } + +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift new file mode 100644 index 00000000..4af15692 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift @@ -0,0 +1,129 @@ +// Models.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(FoundationNetworking) +import FoundationNetworking +#endif + +protocol JSONEncodable { + func encodeToJSON() -> Any +} + +/// An enum where the last case value can be used as a default catch-all. +protocol CaseIterableDefaultsLast: Decodable & CaseIterable & RawRepresentable +where RawValue: Decodable, AllCases: BidirectionalCollection {} + +extension CaseIterableDefaultsLast { + /// Initializes an enum such that if a known raw value is found, then it is decoded. + /// Otherwise the last case is used. + /// - Parameter decoder: A decoder. + public init(from decoder: Decoder) throws { + if let value = try Self(rawValue: decoder.singleValueContainer().decode(RawValue.self)) { + self = value + } else if let lastValue = Self.allCases.last { + self = lastValue + } else { + throw DecodingError.valueNotFound( + Self.Type.self, + .init(codingPath: decoder.codingPath, debugDescription: "CaseIterableDefaultsLast") + ) + } + } +} + +/// A flexible type that can be encoded (`.encodeNull` or `.encodeValue`) +/// or not encoded (`.encodeNothing`). Intended for request payloads. +public enum NullEncodable: Hashable { + case encodeNothing + case encodeNull + case encodeValue(Wrapped) +} + +extension NullEncodable: Codable where Wrapped: Codable { + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(Wrapped.self) { + self = .encodeValue(value) + } else if container.decodeNil() { + self = .encodeNull + } else { + self = .encodeNothing + } + } + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .encodeNothing: return + case .encodeNull: try container.encodeNil() + case .encodeValue(let wrapped): try container.encode(wrapped) + } + } +} + +public enum ErrorResponse: Error { + case error(Int, Data?, URLResponse?, Error) +} + +public enum DownloadException: Error { + case responseDataMissing + case responseFailed + case requestMissing + case requestMissingPath + case requestMissingURL +} + +public enum DecodableRequestBuilderError: Error { + case emptyDataResponse + case nilHTTPResponse + case unsuccessfulHTTPStatusCode + case jsonDecoding(DecodingError) + case generalError(Error) +} + +open class Response { + public let statusCode: Int + public let header: [String: String] + public let body: T + public let bodyData: Data? + + public init(statusCode: Int, header: [String: String], body: T, bodyData: Data?) { + self.statusCode = statusCode + self.header = header + self.body = body + self.bodyData = bodyData + } + + public convenience init(response: HTTPURLResponse, body: T, bodyData: Data?) { + let rawHeader = response.allHeaderFields + var responseHeader = [String: String]() + for (key, value) in rawHeader { + if let key = key.base as? String, let value = value as? String { + responseHeader[key] = value + } + } + self.init(statusCode: response.statusCode, header: responseHeader, body: body, bodyData: bodyData) + } +} + +public final class RequestTask: @unchecked Sendable { + private let lock = NSRecursiveLock() + private var task: URLSessionDataTaskProtocol? + + internal func set(task: URLSessionDataTaskProtocol) { + lock.lock() + defer { lock.unlock() } + self.task = task + } + + public func cancel() { + lock.lock() + defer { lock.unlock() } + task?.cancel() + task = nil + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift new file mode 100644 index 00000000..ba127d12 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift @@ -0,0 +1,103 @@ +// +// AlbumsAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct AlbumsAttributes: Codable, Hashable { + + public enum Availability: String, Codable, CaseIterable { + case stream = "STREAM" + case dj = "DJ" + case stem = "STEM" + } + /** Original title */ + public var title: String + /** Barcode id (EAN-13 or UPC-A) */ + public var barcodeId: String + /** Number of volumes */ + public var numberOfVolumes: Int + /** Number of album items */ + public var numberOfItems: Int + /** Duration (ISO-8601) */ + public var duration: String + /** Indicates whether an album consist of any explicit content */ + public var explicit: Bool + /** Release date (ISO-8601) */ + public var releaseDate: Date? + /** Copyright information */ + public var copyright: String? + /** Album popularity (ranged in 0.00 ... 1.00). Conditionally visible */ + public var popularity: Double + /** Defines an album availability e.g. for streaming, DJs, stems */ + public var availability: [Availability]? + public var mediaTags: [String] + /** Represents available links to, and metadata about, an album cover images */ + public var imageLinks: [CatalogueItemImageLink]? + /** Represents available links to, and metadata about, an album cover videos */ + public var videoLinks: [CatalogueItemVideoLink]? + /** Represents available links to something that is related to an album resource, but external to the TIDAL API */ + public var externalLinks: [CatalogueItemExternalLink]? + + public init(title: String, barcodeId: String, numberOfVolumes: Int, numberOfItems: Int, duration: String, explicit: Bool, releaseDate: Date? = nil, copyright: String? = nil, popularity: Double, availability: [Availability]? = nil, mediaTags: [String], imageLinks: [CatalogueItemImageLink]? = nil, videoLinks: [CatalogueItemVideoLink]? = nil, externalLinks: [CatalogueItemExternalLink]? = nil) { + self.title = title + self.barcodeId = barcodeId + self.numberOfVolumes = numberOfVolumes + self.numberOfItems = numberOfItems + self.duration = duration + self.explicit = explicit + self.releaseDate = releaseDate + self.copyright = copyright + self.popularity = popularity + self.availability = availability + self.mediaTags = mediaTags + self.imageLinks = imageLinks + self.videoLinks = videoLinks + self.externalLinks = externalLinks + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case title + case barcodeId + case numberOfVolumes + case numberOfItems + case duration + case explicit + case releaseDate + case copyright + case popularity + case availability + case mediaTags + case imageLinks + case videoLinks + case externalLinks + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(title, forKey: .title) + try container.encode(barcodeId, forKey: .barcodeId) + try container.encode(numberOfVolumes, forKey: .numberOfVolumes) + try container.encode(numberOfItems, forKey: .numberOfItems) + try container.encode(duration, forKey: .duration) + try container.encode(explicit, forKey: .explicit) + try container.encodeIfPresent(releaseDate, forKey: .releaseDate) + try container.encodeIfPresent(copyright, forKey: .copyright) + try container.encode(popularity, forKey: .popularity) + try container.encodeIfPresent(availability, forKey: .availability) + try container.encode(mediaTags, forKey: .mediaTags) + try container.encodeIfPresent(imageLinks, forKey: .imageLinks) + try container.encodeIfPresent(videoLinks, forKey: .videoLinks) + try container.encodeIfPresent(externalLinks, forKey: .externalLinks) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift new file mode 100644 index 00000000..9ff33deb --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift @@ -0,0 +1,42 @@ +// +// AlbumsItemResourceIdentifier.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct AlbumsItemResourceIdentifier: Codable, Hashable { + + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + public var meta: AlbumsItemResourceIdentifierMeta? + + public init(id: String, type: String, meta: AlbumsItemResourceIdentifierMeta? = nil) { + self.id = id + self.type = type + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case id + case type + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + try container.encodeIfPresent(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift new file mode 100644 index 00000000..2abce93f --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift @@ -0,0 +1,38 @@ +// +// AlbumsItemResourceIdentifierMeta.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct AlbumsItemResourceIdentifierMeta: Codable, Hashable { + + /** volume number */ + public var volumeNumber: Int + /** track number */ + public var trackNumber: Int + + public init(volumeNumber: Int, trackNumber: Int) { + self.volumeNumber = volumeNumber + self.trackNumber = trackNumber + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case volumeNumber + case trackNumber + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(volumeNumber, forKey: .volumeNumber) + try container.encode(trackNumber, forKey: .trackNumber) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift new file mode 100644 index 00000000..b94d1438 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift @@ -0,0 +1,37 @@ +// +// AlbumsItemsRelationship.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** Album items (tracks/videos) relationship */ +public struct AlbumsItemsRelationship: Codable, Hashable { + + public var data: [[AlbumsItemResourceIdentifier]]? + public var links: Links? + + public init(data: [[AlbumsItemResourceIdentifier]]? = nil, links: Links? = nil) { + self.data = data + self.links = links + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift new file mode 100644 index 00000000..ccfab95d --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift @@ -0,0 +1,40 @@ +// +// AlbumsItemsRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct AlbumsItemsRelationshipDocument: Codable, Hashable { + + public var data: [[AlbumsItemResourceIdentifier]]? + public var links: Links? + public var included: [AlbumsItemsRelationshipDocumentIncludedInner]? + + public init(data: [[AlbumsItemResourceIdentifier]]? = nil, links: Links? = nil, included: [AlbumsItemsRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..8b0be81e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift @@ -0,0 +1,58 @@ +// +// AlbumsItemsRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum AlbumsItemsRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of AlbumsItemsRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift new file mode 100644 index 00000000..9616f65e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// AlbumsMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct AlbumsMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [AlbumsResource]? + public var links: Links? + public var included: [AlbumsMultiDataDocumentIncludedInner]? + + public init(data: [AlbumsResource]? = nil, links: Links? = nil, included: [AlbumsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..0f7e6000 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift @@ -0,0 +1,58 @@ +// +// AlbumsMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum AlbumsMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of AlbumsMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift new file mode 100644 index 00000000..eac240b0 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// AlbumsRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct AlbumsRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [AlbumsRelationshipDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [AlbumsRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..87508a56 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift @@ -0,0 +1,53 @@ +// +// AlbumsRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum AlbumsRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of AlbumsRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift new file mode 100644 index 00000000..18ef02cc --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift @@ -0,0 +1,45 @@ +// +// AlbumsRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct AlbumsRelationships: Codable, Hashable { + + public var artists: MultiDataRelationshipDoc + public var items: AlbumsItemsRelationship + public var similarAlbums: MultiDataRelationshipDoc + public var providers: MultiDataRelationshipDoc + + public init(artists: MultiDataRelationshipDoc, items: AlbumsItemsRelationship, similarAlbums: MultiDataRelationshipDoc, providers: MultiDataRelationshipDoc) { + self.artists = artists + self.items = items + self.similarAlbums = similarAlbums + self.providers = providers + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case artists + case items + case similarAlbums + case providers + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(artists, forKey: .artists) + try container.encode(items, forKey: .items) + try container.encode(similarAlbums, forKey: .similarAlbums) + try container.encode(providers, forKey: .providers) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift new file mode 100644 index 00000000..73ffa39e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift @@ -0,0 +1,50 @@ +// +// AlbumsResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct AlbumsResource: Codable, Hashable { + + public var attributes: AlbumsAttributes? + public var relationships: AlbumsRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: AlbumsAttributes? = nil, relationships: AlbumsRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift new file mode 100644 index 00000000..20ef276e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// AlbumsSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct AlbumsSingleDataDocument: Codable, Hashable { + + public var data: AlbumsResource? + public var links: Links? + public var included: [AlbumsMultiDataDocumentIncludedInner]? + + public init(data: AlbumsResource? = nil, links: Links? = nil, included: [AlbumsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift new file mode 100644 index 00000000..876ddb6e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift @@ -0,0 +1,49 @@ +// +// ArtistsAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct ArtistsAttributes: Codable, Hashable { + + /** Artist name */ + public var name: String + /** Artist popularity (ranged in 0.00 ... 1.00). Conditionally visible */ + public var popularity: Double + /** Represents available links to, and metadata about, an artist images */ + public var imageLinks: [CatalogueItemImageLink]? + /** Represents available links to something that is related to an artist resource, but external to the TIDAL API */ + public var externalLinks: [CatalogueItemExternalLink]? + + public init(name: String, popularity: Double, imageLinks: [CatalogueItemImageLink]? = nil, externalLinks: [CatalogueItemExternalLink]? = nil) { + self.name = name + self.popularity = popularity + self.imageLinks = imageLinks + self.externalLinks = externalLinks + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case name + case popularity + case imageLinks + case externalLinks + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(name, forKey: .name) + try container.encode(popularity, forKey: .popularity) + try container.encodeIfPresent(imageLinks, forKey: .imageLinks) + try container.encodeIfPresent(externalLinks, forKey: .externalLinks) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift new file mode 100644 index 00000000..7e51a63c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// ArtistsMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ArtistsMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [ArtistsResource]? + public var links: Links? + public var included: [ArtistsMultiDataDocumentIncludedInner]? + + public init(data: [ArtistsResource]? = nil, links: Links? = nil, included: [ArtistsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..c0bd625c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift @@ -0,0 +1,63 @@ +// +// ArtistsMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum ArtistsMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of ArtistsMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift new file mode 100644 index 00000000..5ac44e84 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// ArtistsRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ArtistsRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [ArtistsRelationshipDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [ArtistsRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..13e3d605 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift @@ -0,0 +1,58 @@ +// +// ArtistsRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum ArtistsRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of ArtistsRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift new file mode 100644 index 00000000..a01a1d9c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift @@ -0,0 +1,53 @@ +// +// ArtistsRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct ArtistsRelationships: Codable, Hashable { + + public var albums: MultiDataRelationshipDoc + public var tracks: MultiDataRelationshipDoc + public var videos: MultiDataRelationshipDoc + public var similarArtists: MultiDataRelationshipDoc + public var trackProviders: ArtistsTrackProvidersRelationship + public var radio: MultiDataRelationshipDoc + + public init(albums: MultiDataRelationshipDoc, tracks: MultiDataRelationshipDoc, videos: MultiDataRelationshipDoc, similarArtists: MultiDataRelationshipDoc, trackProviders: ArtistsTrackProvidersRelationship, radio: MultiDataRelationshipDoc) { + self.albums = albums + self.tracks = tracks + self.videos = videos + self.similarArtists = similarArtists + self.trackProviders = trackProviders + self.radio = radio + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case albums + case tracks + case videos + case similarArtists + case trackProviders + case radio + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(albums, forKey: .albums) + try container.encode(tracks, forKey: .tracks) + try container.encode(videos, forKey: .videos) + try container.encode(similarArtists, forKey: .similarArtists) + try container.encode(trackProviders, forKey: .trackProviders) + try container.encode(radio, forKey: .radio) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift new file mode 100644 index 00000000..99b9fc11 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift @@ -0,0 +1,50 @@ +// +// ArtistsResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ArtistsResource: Codable, Hashable { + + public var attributes: ArtistsAttributes? + public var relationships: ArtistsRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: ArtistsAttributes? = nil, relationships: ArtistsRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift new file mode 100644 index 00000000..480c6b63 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// ArtistsSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ArtistsSingleDataDocument: Codable, Hashable { + + public var data: ArtistsResource? + public var links: Links? + public var included: [ArtistsMultiDataDocumentIncludedInner]? + + public init(data: ArtistsResource? = nil, links: Links? = nil, included: [ArtistsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift new file mode 100644 index 00000000..b094fbf0 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift @@ -0,0 +1,37 @@ +// +// ArtistsTrackProvidersRelationship.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** Providers that have released tracks for this artist */ +public struct ArtistsTrackProvidersRelationship: Codable, Hashable { + + public var data: [[ArtistsTrackProvidersResourceIdentifier]]? + public var links: Links? + + public init(data: [[ArtistsTrackProvidersResourceIdentifier]]? = nil, links: Links? = nil) { + self.data = data + self.links = links + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift new file mode 100644 index 00000000..34c89390 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift @@ -0,0 +1,40 @@ +// +// ArtistsTrackProvidersRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ArtistsTrackProvidersRelationshipDocument: Codable, Hashable { + + public var data: [[ArtistsTrackProvidersResourceIdentifier]]? + public var links: Links? + public var included: [ProvidersRelationshipDocumentIncludedInner]? + + public init(data: [[ArtistsTrackProvidersResourceIdentifier]]? = nil, links: Links? = nil, included: [ProvidersRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift new file mode 100644 index 00000000..0dd68bc1 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift @@ -0,0 +1,42 @@ +// +// ArtistsTrackProvidersResourceIdentifier.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ArtistsTrackProvidersResourceIdentifier: Codable, Hashable { + + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + public var meta: ArtistsTrackProvidersResourceIdentifierMeta? + + public init(id: String, type: String, meta: ArtistsTrackProvidersResourceIdentifierMeta? = nil) { + self.id = id + self.type = type + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case id + case type + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + try container.encodeIfPresent(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift new file mode 100644 index 00000000..1221e8f8 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift @@ -0,0 +1,33 @@ +// +// ArtistsTrackProvidersResourceIdentifierMeta.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ArtistsTrackProvidersResourceIdentifierMeta: Codable, Hashable { + + /** total number of tracks released together with the provider */ + public var numberOfTracks: Int64 + + public init(numberOfTracks: Int64) { + self.numberOfTracks = numberOfTracks + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case numberOfTracks + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(numberOfTracks, forKey: .numberOfTracks) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift new file mode 100644 index 00000000..c41a6653 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift @@ -0,0 +1,37 @@ +// +// CatalogueItemExternalLink.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct CatalogueItemExternalLink: Codable, Hashable { + + /** link to something that is related to a resource */ + public var href: String + public var meta: ExternalLinkMeta + + public init(href: String, meta: ExternalLinkMeta) { + self.href = href + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case href + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(href, forKey: .href) + try container.encode(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift new file mode 100644 index 00000000..f2ce74bb --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift @@ -0,0 +1,37 @@ +// +// CatalogueItemImageLink.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct CatalogueItemImageLink: Codable, Hashable { + + /** link to an image */ + public var href: String + public var meta: ImageLinkMeta + + public init(href: String, meta: ImageLinkMeta) { + self.href = href + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case href + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(href, forKey: .href) + try container.encode(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift new file mode 100644 index 00000000..c5aca805 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift @@ -0,0 +1,37 @@ +// +// CatalogueItemVideoLink.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct CatalogueItemVideoLink: Codable, Hashable { + + /** link to a video */ + public var href: String + public var meta: VideoLinkMeta + + public init(href: String, meta: VideoLinkMeta) { + self.href = href + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case href + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(href, forKey: .href) + try container.encode(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift new file mode 100644 index 00000000..ad084622 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift @@ -0,0 +1,37 @@ +// +// ErrorDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ErrorDocument: Codable, Hashable { + + /** array of error objects */ + public var errors: [ErrorObject]? + public var links: Links? + + public init(errors: [ErrorObject]? = nil, links: Links? = nil) { + self.errors = errors + self.links = links + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case errors + case links + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(errors, forKey: .errors) + try container.encodeIfPresent(links, forKey: .links) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift new file mode 100644 index 00000000..bce8d5c9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift @@ -0,0 +1,52 @@ +// +// ErrorObject.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ErrorObject: Codable, Hashable { + + /** unique identifier for this particular occurrence of the problem */ + public var id: String? + /** HTTP status code applicable to this problem */ + public var status: String? + /** application-specific error code */ + public var code: String? + /** human-readable explanation specific to this occurrence of the problem */ + public var detail: String? + public var source: ErrorObjectSource? + + public init(id: String? = nil, status: String? = nil, code: String? = nil, detail: String? = nil, source: ErrorObjectSource? = nil) { + self.id = id + self.status = status + self.code = code + self.detail = detail + self.source = source + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case id + case status + case code + case detail + case source + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(id, forKey: .id) + try container.encodeIfPresent(status, forKey: .status) + try container.encodeIfPresent(code, forKey: .code) + try container.encodeIfPresent(detail, forKey: .detail) + try container.encodeIfPresent(source, forKey: .source) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift new file mode 100644 index 00000000..d820ffb9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift @@ -0,0 +1,44 @@ +// +// ErrorObjectSource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** object containing references to the primary source of the error */ +public struct ErrorObjectSource: Codable, Hashable { + + /** a JSON Pointer [RFC6901] to the value in the request document that caused the error */ + public var pointer: String? + /** string indicating which URI query parameter caused the error. */ + public var parameter: String? + /** string indicating the name of a single request header which caused the error */ + public var header: String? + + public init(pointer: String? = nil, parameter: String? = nil, header: String? = nil) { + self.pointer = pointer + self.parameter = parameter + self.header = header + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case pointer + case parameter + case header + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(pointer, forKey: .pointer) + try container.encodeIfPresent(parameter, forKey: .parameter) + try container.encodeIfPresent(header, forKey: .header) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift new file mode 100644 index 00000000..f9f6af4c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift @@ -0,0 +1,46 @@ +// +// ExternalLinkMeta.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** metadata about an external link */ +public struct ExternalLinkMeta: Codable, Hashable { + + public enum ModelType: String, Codable, CaseIterable { + case tidalSharing = "TIDAL_SHARING" + case tidalAutoplayAndroid = "TIDAL_AUTOPLAY_ANDROID" + case tidalAutoplayIos = "TIDAL_AUTOPLAY_IOS" + case tidalAutoplayWeb = "TIDAL_AUTOPLAY_WEB" + case twitter = "TWITTER" + case facebook = "FACEBOOK" + case instagram = "INSTAGRAM" + case tiktok = "TIKTOK" + case snapchat = "SNAPCHAT" + case homepage = "HOMEPAGE" + } + /** external link type */ + public var type: ModelType + + public init(type: ModelType) { + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift new file mode 100644 index 00000000..9c332211 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift @@ -0,0 +1,39 @@ +// +// ImageLinkMeta.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** metadata about an image */ +public struct ImageLinkMeta: Codable, Hashable { + + /** image width (in pixels) */ + public var width: Int + /** image height (in pixels) */ + public var height: Int + + public init(width: Int, height: Int) { + self.width = width + self.height = height + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case width + case height + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(width, forKey: .width) + try container.encode(height, forKey: .height) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift new file mode 100644 index 00000000..704242cc --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift @@ -0,0 +1,39 @@ +// +// Links.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** links object */ +public struct Links: Codable, Hashable { + + /** the link that generated the current response document */ + public var _self: String + /** the next page of data (pagination) */ + public var next: String? + + public init(_self: String, next: String? = nil) { + self._self = _self + self.next = next + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case _self = "self" + case next + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(_self, forKey: ._self) + try container.encodeIfPresent(next, forKey: .next) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift new file mode 100644 index 00000000..c8db2b18 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift @@ -0,0 +1,38 @@ +// +// MultiDataRelationshipDoc.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** Playlist owners relationship */ +public struct MultiDataRelationshipDoc: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil) { + self.data = data + self.links = links + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift new file mode 100644 index 00000000..7da57c55 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift @@ -0,0 +1,84 @@ +// +// PlaylistsAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct PlaylistsAttributes: Codable, Hashable { + + /** Playlist name */ + public var name: String + /** Playlist description */ + public var description: String? + /** Indicates if the playlist has a duration and set number of tracks */ + public var bounded: Bool + /** Duration of the playlist expressed in accordance with ISO 8601 */ + public var duration: String? + /** Number of items in the playlist */ + public var numberOfItems: Int? + /** Sharing links to the playlist */ + public var externalLinks: [PlaylistsExternalLink] + /** Datetime of playlist creation (ISO 8601) */ + public var createdAt: Date + /** Datetime of last modification of the playlist (ISO 8601) */ + public var lastModifiedAt: Date + /** Privacy setting of the playlist */ + public var privacy: String + /** The type of the playlist */ + public var playlistType: String + /** Images associated with the playlist */ + public var imageLinks: [PlaylistsImageLink] + + public init(name: String, description: String? = nil, bounded: Bool, duration: String? = nil, numberOfItems: Int? = nil, externalLinks: [PlaylistsExternalLink], createdAt: Date, lastModifiedAt: Date, privacy: String, playlistType: String, imageLinks: [PlaylistsImageLink]) { + self.name = name + self.description = description + self.bounded = bounded + self.duration = duration + self.numberOfItems = numberOfItems + self.externalLinks = externalLinks + self.createdAt = createdAt + self.lastModifiedAt = lastModifiedAt + self.privacy = privacy + self.playlistType = playlistType + self.imageLinks = imageLinks + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case name + case description + case bounded + case duration + case numberOfItems + case externalLinks + case createdAt + case lastModifiedAt + case privacy + case playlistType + case imageLinks + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(name, forKey: .name) + try container.encodeIfPresent(description, forKey: .description) + try container.encode(bounded, forKey: .bounded) + try container.encodeIfPresent(duration, forKey: .duration) + try container.encodeIfPresent(numberOfItems, forKey: .numberOfItems) + try container.encode(externalLinks, forKey: .externalLinks) + try container.encode(createdAt, forKey: .createdAt) + try container.encode(lastModifiedAt, forKey: .lastModifiedAt) + try container.encode(privacy, forKey: .privacy) + try container.encode(playlistType, forKey: .playlistType) + try container.encode(imageLinks, forKey: .imageLinks) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift new file mode 100644 index 00000000..2f5e71b5 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift @@ -0,0 +1,38 @@ +// +// PlaylistsExternalLink.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** Sharing links to the playlist */ +public struct PlaylistsExternalLink: Codable, Hashable { + + /** link to something that is related to a resource */ + public var href: String + public var meta: ExternalLinkMeta + + public init(href: String, meta: ExternalLinkMeta) { + self.href = href + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case href + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(href, forKey: .href) + try container.encode(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift new file mode 100644 index 00000000..d4ae59d7 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift @@ -0,0 +1,38 @@ +// +// PlaylistsImageLink.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** Images associated with the playlist */ +public struct PlaylistsImageLink: Codable, Hashable { + + /** link to an image */ + public var href: String + public var meta: ImageLinkMeta? + + public init(href: String, meta: ImageLinkMeta? = nil) { + self.href = href + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case href + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(href, forKey: .href) + try container.encodeIfPresent(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift new file mode 100644 index 00000000..caae10bb --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// PlaylistsItemsRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct PlaylistsItemsRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [PlaylistsItemsRelationshipDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [PlaylistsItemsRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..e21b1159 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift @@ -0,0 +1,58 @@ +// +// PlaylistsItemsRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum PlaylistsItemsRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of PlaylistsItemsRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift new file mode 100644 index 00000000..ff91c890 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// PlaylistsMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct PlaylistsMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [PlaylistsResource]? + public var links: Links? + public var included: [PlaylistsMultiDataDocumentIncludedInner]? + + public init(data: [PlaylistsResource]? = nil, links: Links? = nil, included: [PlaylistsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..f20d7859 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift @@ -0,0 +1,78 @@ +// +// PlaylistsMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum PlaylistsMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeUserEntitlementsResource(UserEntitlementsResource) + case typeUserPublicProfilesResource(UserPublicProfilesResource) + case typeUserRecommendationsResource(UserRecommendationsResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUserEntitlementsResource(let value): + try container.encode(value) + case .typeUserPublicProfilesResource(let value): + try container.encode(value) + case .typeUserRecommendationsResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UserEntitlementsResource.self) { + self = .typeUserEntitlementsResource(value) + } else if let value = try? container.decode(UserPublicProfilesResource.self) { + self = .typeUserPublicProfilesResource(value) + } else if let value = try? container.decode(UserRecommendationsResource.self) { + self = .typeUserRecommendationsResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of PlaylistsMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift new file mode 100644 index 00000000..8325f2d3 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// PlaylistsOwnersRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct PlaylistsOwnersRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [PlaylistsOwnersRelationshipDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [PlaylistsOwnersRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..33ae96dc --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift @@ -0,0 +1,78 @@ +// +// PlaylistsOwnersRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum PlaylistsOwnersRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeUserEntitlementsResource(UserEntitlementsResource) + case typeUserPublicProfilesResource(UserPublicProfilesResource) + case typeUserRecommendationsResource(UserRecommendationsResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUserEntitlementsResource(let value): + try container.encode(value) + case .typeUserPublicProfilesResource(let value): + try container.encode(value) + case .typeUserRecommendationsResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UserEntitlementsResource.self) { + self = .typeUserEntitlementsResource(value) + } else if let value = try? container.decode(UserPublicProfilesResource.self) { + self = .typeUserPublicProfilesResource(value) + } else if let value = try? container.decode(UserRecommendationsResource.self) { + self = .typeUserRecommendationsResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of PlaylistsOwnersRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift new file mode 100644 index 00000000..d304e6ed --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// PlaylistsRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct PlaylistsRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [UserRecommendationsMultiDataDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [UserRecommendationsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..5e6d29bb --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift @@ -0,0 +1,48 @@ +// +// PlaylistsRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum PlaylistsRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typePlaylistsResource(PlaylistsResource) + case typeTracksResource(TracksResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of PlaylistsRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift new file mode 100644 index 00000000..28448725 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift @@ -0,0 +1,37 @@ +// +// PlaylistsRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct PlaylistsRelationships: Codable, Hashable { + + public var items: MultiDataRelationshipDoc + public var owners: MultiDataRelationshipDoc + + public init(items: MultiDataRelationshipDoc, owners: MultiDataRelationshipDoc) { + self.items = items + self.owners = owners + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case items + case owners + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(items, forKey: .items) + try container.encode(owners, forKey: .owners) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift new file mode 100644 index 00000000..9e4bf456 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift @@ -0,0 +1,50 @@ +// +// PlaylistsResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct PlaylistsResource: Codable, Hashable { + + public var attributes: PlaylistsAttributes? + public var relationships: PlaylistsRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: PlaylistsAttributes? = nil, relationships: PlaylistsRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift new file mode 100644 index 00000000..39057b84 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// PlaylistsSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct PlaylistsSingleDataDocument: Codable, Hashable { + + public var data: PlaylistsResource? + public var links: Links? + public var included: [PlaylistsMultiDataDocumentIncludedInner]? + + public init(data: PlaylistsResource? = nil, links: Links? = nil, included: [PlaylistsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift new file mode 100644 index 00000000..a9cffd05 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift @@ -0,0 +1,39 @@ +// +// PromptColors.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** Primary and Secondary color to visually render the pick */ +public struct PromptColors: Codable, Hashable { + + /** Primary color to visually render the pick */ + public var primary: String + /** Secondary color to visually render the pick */ + public var secondary: String + + public init(primary: String, secondary: String) { + self.primary = primary + self.secondary = secondary + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case primary + case secondary + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(primary, forKey: .primary) + try container.encode(secondary, forKey: .secondary) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift new file mode 100644 index 00000000..272badc4 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift @@ -0,0 +1,34 @@ +// +// ProvidersAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct ProvidersAttributes: Codable, Hashable { + + /** Provider name. Conditionally visible. */ + public var name: String + + public init(name: String) { + self.name = name + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case name + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(name, forKey: .name) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift new file mode 100644 index 00000000..d36b4f39 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift @@ -0,0 +1,37 @@ +// +// ProvidersMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ProvidersMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [ProvidersResource]? + public var links: Links? + + public init(data: [ProvidersResource]? = nil, links: Links? = nil) { + self.data = data + self.links = links + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift new file mode 100644 index 00000000..c667c2f9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// ProvidersRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ProvidersRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [ProvidersRelationshipDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [ProvidersRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..57b633e0 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift @@ -0,0 +1,33 @@ +// +// ProvidersRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum ProvidersRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeProvidersResource(ProvidersResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeProvidersResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of ProvidersRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift new file mode 100644 index 00000000..648677ed --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift @@ -0,0 +1,51 @@ +// +// ProvidersResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ProvidersResource: Codable, Hashable { + + public var attributes: ProvidersAttributes? + /** relationships object describing relationships between the resource and other resources */ + public var relationships: AnyCodable? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: ProvidersAttributes? = nil, relationships: AnyCodable? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift new file mode 100644 index 00000000..f2424086 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift @@ -0,0 +1,36 @@ +// +// ProvidersSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ProvidersSingleDataDocument: Codable, Hashable { + + public var data: ProvidersResource? + public var links: Links? + + public init(data: ProvidersResource? = nil, links: Links? = nil) { + self.data = data + self.links = links + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift new file mode 100644 index 00000000..273abc6e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift @@ -0,0 +1,38 @@ +// +// ResourceIdentifier.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct ResourceIdentifier: Codable, Hashable { + + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(id: String, type: String) { + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift new file mode 100644 index 00000000..35f46d21 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift @@ -0,0 +1,39 @@ +// +// SearchResultsAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct SearchResultsAttributes: Codable, Hashable { + + /** search request unique tracking number */ + public var trackingId: String + /** 'did you mean' prompt */ + public var didYouMean: String? + + public init(trackingId: String, didYouMean: String? = nil) { + self.trackingId = trackingId + self.didYouMean = didYouMean + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case trackingId + case didYouMean + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(trackingId, forKey: .trackingId) + try container.encodeIfPresent(didYouMean, forKey: .didYouMean) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift new file mode 100644 index 00000000..11b2d421 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift @@ -0,0 +1,53 @@ +// +// SearchResultsRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct SearchResultsRelationships: Codable, Hashable { + + public var albums: MultiDataRelationshipDoc + public var artists: MultiDataRelationshipDoc + public var tracks: MultiDataRelationshipDoc + public var videos: MultiDataRelationshipDoc + public var playlists: MultiDataRelationshipDoc + public var topHits: MultiDataRelationshipDoc + + public init(albums: MultiDataRelationshipDoc, artists: MultiDataRelationshipDoc, tracks: MultiDataRelationshipDoc, videos: MultiDataRelationshipDoc, playlists: MultiDataRelationshipDoc, topHits: MultiDataRelationshipDoc) { + self.albums = albums + self.artists = artists + self.tracks = tracks + self.videos = videos + self.playlists = playlists + self.topHits = topHits + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case albums + case artists + case tracks + case videos + case playlists + case topHits + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(albums, forKey: .albums) + try container.encode(artists, forKey: .artists) + try container.encode(tracks, forKey: .tracks) + try container.encode(videos, forKey: .videos) + try container.encode(playlists, forKey: .playlists) + try container.encode(topHits, forKey: .topHits) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift new file mode 100644 index 00000000..1081d109 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift @@ -0,0 +1,51 @@ +// +// SearchResultsResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** primary resource data */ +public struct SearchResultsResource: Codable, Hashable { + + public var attributes: SearchResultsAttributes? + public var relationships: SearchResultsRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: SearchResultsAttributes? = nil, relationships: SearchResultsRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift new file mode 100644 index 00000000..98ca14d6 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// SearchResultsSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct SearchResultsSingleDataDocument: Codable, Hashable { + + public var data: SearchResultsResource? + public var links: Links? + public var included: [SearchResultsSingleDataDocumentIncludedInner]? + + public init(data: SearchResultsResource? = nil, links: Links? = nil, included: [SearchResultsSingleDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift new file mode 100644 index 00000000..0a61b270 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift @@ -0,0 +1,63 @@ +// +// SearchResultsSingleDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum SearchResultsSingleDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of SearchResultsSingleDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift new file mode 100644 index 00000000..a6c2258c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// SearchResultsTopHitsRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct SearchResultsTopHitsRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [SearchResultsTopHitsRelationshipDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [SearchResultsTopHitsRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..44ec11f9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift @@ -0,0 +1,58 @@ +// +// SearchResultsTopHitsRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum SearchResultsTopHitsRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeTracksResource(TracksResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of SearchResultsTopHitsRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift new file mode 100644 index 00000000..ee54aa2c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift @@ -0,0 +1,37 @@ +// +// SingletonDataRelationshipDoc.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** Pick's owning user public profile relationship */ +public struct SingletonDataRelationshipDoc: Codable, Hashable { + + public var data: ResourceIdentifier? + public var links: Links? + + public init(data: ResourceIdentifier? = nil, links: Links? = nil) { + self.data = data + self.links = links + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift new file mode 100644 index 00000000..87688817 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift @@ -0,0 +1,83 @@ +// +// TracksAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct TracksAttributes: Codable, Hashable { + + public enum Availability: String, Codable, CaseIterable { + case stream = "STREAM" + case dj = "DJ" + case stem = "STEM" + } + /** Album item's title */ + public var title: String + /** Version of the album's item; complements title */ + public var version: String? + /** ISRC code */ + public var isrc: String + /** Duration expressed in accordance with ISO 8601 */ + public var duration: String + /** Copyright information */ + public var copyright: String? + /** Indicates whether a catalog item consist of any explicit content */ + public var explicit: Bool + /** Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible */ + public var popularity: Double + /** Defines a catalog item availability e.g. for streaming, DJs, stems */ + public var availability: [Availability]? + public var mediaTags: [String] + /** Represents available links to something that is related to a catalog item, but external to the TIDAL API */ + public var externalLinks: [CatalogueItemExternalLink]? + + public init(title: String, version: String? = nil, isrc: String, duration: String, copyright: String? = nil, explicit: Bool, popularity: Double, availability: [Availability]? = nil, mediaTags: [String], externalLinks: [CatalogueItemExternalLink]? = nil) { + self.title = title + self.version = version + self.isrc = isrc + self.duration = duration + self.copyright = copyright + self.explicit = explicit + self.popularity = popularity + self.availability = availability + self.mediaTags = mediaTags + self.externalLinks = externalLinks + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case title + case version + case isrc + case duration + case copyright + case explicit + case popularity + case availability + case mediaTags + case externalLinks + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(title, forKey: .title) + try container.encodeIfPresent(version, forKey: .version) + try container.encode(isrc, forKey: .isrc) + try container.encode(duration, forKey: .duration) + try container.encodeIfPresent(copyright, forKey: .copyright) + try container.encode(explicit, forKey: .explicit) + try container.encode(popularity, forKey: .popularity) + try container.encodeIfPresent(availability, forKey: .availability) + try container.encode(mediaTags, forKey: .mediaTags) + try container.encodeIfPresent(externalLinks, forKey: .externalLinks) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift new file mode 100644 index 00000000..731ca037 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// TracksMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct TracksMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [TracksResource]? + public var links: Links? + public var included: [TracksMultiDataDocumentIncludedInner]? + + public init(data: [TracksResource]? = nil, links: Links? = nil, included: [TracksMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..5f15dba2 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift @@ -0,0 +1,63 @@ +// +// TracksMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum TracksMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of TracksMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift new file mode 100644 index 00000000..32f71869 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift @@ -0,0 +1,49 @@ +// +// TracksRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct TracksRelationships: Codable, Hashable { + + public var albums: MultiDataRelationshipDoc + public var artists: MultiDataRelationshipDoc + public var providers: MultiDataRelationshipDoc + public var similarTracks: MultiDataRelationshipDoc + public var radio: MultiDataRelationshipDoc + + public init(albums: MultiDataRelationshipDoc, artists: MultiDataRelationshipDoc, providers: MultiDataRelationshipDoc, similarTracks: MultiDataRelationshipDoc, radio: MultiDataRelationshipDoc) { + self.albums = albums + self.artists = artists + self.providers = providers + self.similarTracks = similarTracks + self.radio = radio + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case albums + case artists + case providers + case similarTracks + case radio + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(albums, forKey: .albums) + try container.encode(artists, forKey: .artists) + try container.encode(providers, forKey: .providers) + try container.encode(similarTracks, forKey: .similarTracks) + try container.encode(radio, forKey: .radio) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift new file mode 100644 index 00000000..a24d8029 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift @@ -0,0 +1,41 @@ +// +// TracksRelationshipsDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct TracksRelationshipsDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [TracksRelationshipsDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [TracksRelationshipsDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift new file mode 100644 index 00000000..a2a81559 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift @@ -0,0 +1,53 @@ +// +// TracksRelationshipsDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum TracksRelationshipsDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of TracksRelationshipsDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift new file mode 100644 index 00000000..94f5690c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift @@ -0,0 +1,50 @@ +// +// TracksResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct TracksResource: Codable, Hashable { + + public var attributes: TracksAttributes? + public var relationships: TracksRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: TracksAttributes? = nil, relationships: TracksRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift new file mode 100644 index 00000000..02c23221 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// TracksSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct TracksSingleDataDocument: Codable, Hashable { + + public var data: TracksResource? + public var links: Links? + public var included: [TracksMultiDataDocumentIncludedInner]? + + public init(data: TracksResource? = nil, links: Links? = nil, included: [TracksMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift new file mode 100644 index 00000000..b2e6d5e0 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift @@ -0,0 +1,32 @@ +// +// UpdateUserPublicProfilePicksRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UpdateUserPublicProfilePicksRelationshipDocument: Codable, Hashable { + + public var data: ResourceIdentifier? + + public init(data: ResourceIdentifier? = nil) { + self.data = data + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift new file mode 100644 index 00000000..e7601701 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift @@ -0,0 +1,38 @@ +// +// UserEntitlementsAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct UserEntitlementsAttributes: Codable, Hashable { + + public enum Entitlements: String, Codable, CaseIterable { + case music = "MUSIC" + case dj = "DJ" + } + /** entitlements for user */ + public var entitlements: [Entitlements] + + public init(entitlements: [Entitlements]) { + self.entitlements = entitlements + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case entitlements + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(entitlements, forKey: .entitlements) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift new file mode 100644 index 00000000..d6659e3c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift @@ -0,0 +1,40 @@ +// +// UserEntitlementsRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserEntitlementsRelationshipDocument: Codable, Hashable { + + public var data: ResourceIdentifier? + public var links: Links? + public var included: [UserEntitlementsRelationshipDocumentIncludedInner]? + + public init(data: ResourceIdentifier? = nil, links: Links? = nil, included: [UserEntitlementsRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..68d25318 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift @@ -0,0 +1,33 @@ +// +// UserEntitlementsRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UserEntitlementsRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeUserEntitlementsResource(UserEntitlementsResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeUserEntitlementsResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(UserEntitlementsResource.self) { + self = .typeUserEntitlementsResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UserEntitlementsRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift new file mode 100644 index 00000000..262cc6b8 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift @@ -0,0 +1,51 @@ +// +// UserEntitlementsResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserEntitlementsResource: Codable, Hashable { + + public var attributes: UserEntitlementsAttributes? + /** relationships object describing relationships between the resource and other resources */ + public var relationships: AnyCodable? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: UserEntitlementsAttributes? = nil, relationships: AnyCodable? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift new file mode 100644 index 00000000..e8f4c618 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift @@ -0,0 +1,36 @@ +// +// UserEntitlementsSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserEntitlementsSingleDataDocument: Codable, Hashable { + + public var data: UserEntitlementsResource? + public var links: Links? + + public init(data: UserEntitlementsResource? = nil, links: Links? = nil) { + self.data = data + self.links = links + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift new file mode 100644 index 00000000..ae90ac6f --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift @@ -0,0 +1,60 @@ +// +// UserPublicProfilePicksAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct UserPublicProfilePicksAttributes: Codable, Hashable { + + public enum SupportedContentType: String, Codable, CaseIterable { + case tracks = "TRACKS" + case videos = "VIDEOS" + case albums = "ALBUMS" + case artists = "ARTISTS" + case providers = "PROVIDERS" + } + /** Pick title */ + public var title: String + /** Description of pick */ + public var description: String + /** CatalogueResourceType for supported item for the pick */ + public var supportedContentType: SupportedContentType + public var colors: PromptColors + /** Date of last modification of the pick (ISO 8601) */ + public var lastModifiedAt: Date? + + public init(title: String, description: String, supportedContentType: SupportedContentType, colors: PromptColors, lastModifiedAt: Date? = nil) { + self.title = title + self.description = description + self.supportedContentType = supportedContentType + self.colors = colors + self.lastModifiedAt = lastModifiedAt + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case title + case description + case supportedContentType + case colors + case lastModifiedAt + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(title, forKey: .title) + try container.encode(description, forKey: .description) + try container.encode(supportedContentType, forKey: .supportedContentType) + try container.encode(colors, forKey: .colors) + try container.encodeIfPresent(lastModifiedAt, forKey: .lastModifiedAt) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift new file mode 100644 index 00000000..14d935a0 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift @@ -0,0 +1,40 @@ +// +// UserPublicProfilePicksItemRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilePicksItemRelationshipDocument: Codable, Hashable { + + public var data: ResourceIdentifier? + public var links: Links? + public var included: [UserPublicProfilePicksItemRelationshipDocumentIncludedInner]? + + public init(data: ResourceIdentifier? = nil, links: Links? = nil, included: [UserPublicProfilePicksItemRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..9e17e0f0 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift @@ -0,0 +1,58 @@ +// +// UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UserPublicProfilePicksItemRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UserPublicProfilePicksItemRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift new file mode 100644 index 00000000..17a52153 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// UserPublicProfilePicksMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilePicksMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [UserPublicProfilePicksResource]? + public var links: Links? + public var included: [UserPublicProfilePicksMultiDataDocumentIncludedInner]? + + public init(data: [UserPublicProfilePicksResource]? = nil, links: Links? = nil, included: [UserPublicProfilePicksMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..bd53be51 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift @@ -0,0 +1,73 @@ +// +// UserPublicProfilePicksMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UserPublicProfilePicksMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeUserPublicProfilePicksResource(UserPublicProfilePicksResource) + case typeUserPublicProfilesResource(UserPublicProfilesResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUserPublicProfilePicksResource(let value): + try container.encode(value) + case .typeUserPublicProfilesResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UserPublicProfilePicksResource.self) { + self = .typeUserPublicProfilePicksResource(value) + } else if let value = try? container.decode(UserPublicProfilesResource.self) { + self = .typeUserPublicProfilesResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UserPublicProfilePicksMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift new file mode 100644 index 00000000..d69db522 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// UserPublicProfilePicksRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilePicksRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [UserPublicProfilePicksRelationshipDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [UserPublicProfilePicksRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..3d0bc9f9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift @@ -0,0 +1,53 @@ +// +// UserPublicProfilePicksRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UserPublicProfilePicksRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typeTracksResource(TracksResource) + case typeUserPublicProfilePicksResource(UserPublicProfilePicksResource) + case typeUserPublicProfilesResource(UserPublicProfilesResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUserPublicProfilePicksResource(let value): + try container.encode(value) + case .typeUserPublicProfilesResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UserPublicProfilePicksResource.self) { + self = .typeUserPublicProfilePicksResource(value) + } else if let value = try? container.decode(UserPublicProfilesResource.self) { + self = .typeUserPublicProfilesResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UserPublicProfilePicksRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift new file mode 100644 index 00000000..aae14baf --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift @@ -0,0 +1,37 @@ +// +// UserPublicProfilePicksRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct UserPublicProfilePicksRelationships: Codable, Hashable { + + public var item: SingletonDataRelationshipDoc + public var userPublicProfile: SingletonDataRelationshipDoc + + public init(item: SingletonDataRelationshipDoc, userPublicProfile: SingletonDataRelationshipDoc) { + self.item = item + self.userPublicProfile = userPublicProfile + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case item + case userPublicProfile + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(item, forKey: .item) + try container.encode(userPublicProfile, forKey: .userPublicProfile) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift new file mode 100644 index 00000000..3ca559bb --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift @@ -0,0 +1,50 @@ +// +// UserPublicProfilePicksResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilePicksResource: Codable, Hashable { + + public var attributes: UserPublicProfilePicksAttributes? + public var relationships: UserPublicProfilePicksRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: UserPublicProfilePicksAttributes? = nil, relationships: UserPublicProfilePicksRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift new file mode 100644 index 00000000..7bd0ab11 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift @@ -0,0 +1,57 @@ +// +// UserPublicProfilesAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct UserPublicProfilesAttributes: Codable, Hashable { + + /** Public Name of the user profile */ + public var profileName: String? + public var picture: UserPublicProfilesImageLink? + public var color: [String] + /** ExternalLinks for the user's profile */ + public var externalLinks: [UserPublicProfilesExternalLink]? + /** Number of followers for the user */ + public var numberOfFollowers: Int? + /** Number of users the user follows */ + public var numberOfFollows: Int? + + public init(profileName: String? = nil, picture: UserPublicProfilesImageLink? = nil, color: [String], externalLinks: [UserPublicProfilesExternalLink]? = nil, numberOfFollowers: Int? = nil, numberOfFollows: Int? = nil) { + self.profileName = profileName + self.picture = picture + self.color = color + self.externalLinks = externalLinks + self.numberOfFollowers = numberOfFollowers + self.numberOfFollows = numberOfFollows + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case profileName + case picture + case color + case externalLinks + case numberOfFollowers + case numberOfFollows + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(profileName, forKey: .profileName) + try container.encodeIfPresent(picture, forKey: .picture) + try container.encode(color, forKey: .color) + try container.encodeIfPresent(externalLinks, forKey: .externalLinks) + try container.encodeIfPresent(numberOfFollowers, forKey: .numberOfFollowers) + try container.encodeIfPresent(numberOfFollows, forKey: .numberOfFollows) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift new file mode 100644 index 00000000..ca2799a6 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift @@ -0,0 +1,37 @@ +// +// UserPublicProfilesExternalLink.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilesExternalLink: Codable, Hashable { + + /** link to something that is related to a resource */ + public var href: String + public var meta: UserPublicProfilesExternalLinkMeta + + public init(href: String, meta: UserPublicProfilesExternalLinkMeta) { + self.href = href + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case href + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(href, forKey: .href) + try container.encode(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift new file mode 100644 index 00000000..d5964d38 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift @@ -0,0 +1,51 @@ +// +// UserPublicProfilesExternalLinkMeta.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** metadata about an external link */ +public struct UserPublicProfilesExternalLinkMeta: Codable, Hashable { + + public enum ModelType: String, Codable, CaseIterable { + case tidalSharing = "TIDAL_SHARING" + case tidalAutoplayAndroid = "TIDAL_AUTOPLAY_ANDROID" + case tidalAutoplayIos = "TIDAL_AUTOPLAY_IOS" + case tidalAutoplayWeb = "TIDAL_AUTOPLAY_WEB" + case twitter = "TWITTER" + case facebook = "FACEBOOK" + case instagram = "INSTAGRAM" + case tiktok = "TIKTOK" + case snapchat = "SNAPCHAT" + case homepage = "HOMEPAGE" + } + /** external link type */ + public var type: ModelType + /** external link handle */ + public var handle: String + + public init(type: ModelType, handle: String) { + self.type = type + self.handle = handle + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case type + case handle + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(type, forKey: .type) + try container.encode(handle, forKey: .handle) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift new file mode 100644 index 00000000..e7d47eb3 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift @@ -0,0 +1,38 @@ +// +// UserPublicProfilesImageLink.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** ImageLink to the users image */ +public struct UserPublicProfilesImageLink: Codable, Hashable { + + /** link to an image */ + public var href: String + public var meta: ImageLinkMeta? + + public init(href: String, meta: ImageLinkMeta? = nil) { + self.href = href + self.meta = meta + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case href + case meta + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(href, forKey: .href) + try container.encodeIfPresent(meta, forKey: .meta) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift new file mode 100644 index 00000000..00fd8af3 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// UserPublicProfilesMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilesMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [UserPublicProfilesResource]? + public var links: Links? + public var included: [UserPublicProfilesMultiDataDocumentIncludedInner]? + + public init(data: [UserPublicProfilesResource]? = nil, links: Links? = nil, included: [UserPublicProfilesMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..0cf9b398 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift @@ -0,0 +1,78 @@ +// +// UserPublicProfilesMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UserPublicProfilesMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeTracksResource(TracksResource) + case typeUserEntitlementsResource(UserEntitlementsResource) + case typeUserPublicProfilePicksResource(UserPublicProfilePicksResource) + case typeUserPublicProfilesResource(UserPublicProfilesResource) + case typeUserRecommendationsResource(UserRecommendationsResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUserEntitlementsResource(let value): + try container.encode(value) + case .typeUserPublicProfilePicksResource(let value): + try container.encode(value) + case .typeUserPublicProfilesResource(let value): + try container.encode(value) + case .typeUserRecommendationsResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UserEntitlementsResource.self) { + self = .typeUserEntitlementsResource(value) + } else if let value = try? container.decode(UserPublicProfilePicksResource.self) { + self = .typeUserPublicProfilePicksResource(value) + } else if let value = try? container.decode(UserPublicProfilesResource.self) { + self = .typeUserPublicProfilesResource(value) + } else if let value = try? container.decode(UserRecommendationsResource.self) { + self = .typeUserRecommendationsResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UserPublicProfilesMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift new file mode 100644 index 00000000..9bde6a76 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift @@ -0,0 +1,40 @@ +// +// UserPublicProfilesRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilesRelationshipDocument: Codable, Hashable { + + public var data: ResourceIdentifier? + public var links: Links? + public var included: [UserPublicProfilesRelationshipDocumentIncludedInner]? + + public init(data: ResourceIdentifier? = nil, links: Links? = nil, included: [UserPublicProfilesRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..47d42d42 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift @@ -0,0 +1,48 @@ +// +// UserPublicProfilesRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UserPublicProfilesRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typePlaylistsResource(PlaylistsResource) + case typeUserPublicProfilePicksResource(UserPublicProfilePicksResource) + case typeUserPublicProfilesResource(UserPublicProfilesResource) + case typeUsersResource(UsersResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeUserPublicProfilePicksResource(let value): + try container.encode(value) + case .typeUserPublicProfilesResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(UserPublicProfilePicksResource.self) { + self = .typeUserPublicProfilePicksResource(value) + } else if let value = try? container.decode(UserPublicProfilesResource.self) { + self = .typeUserPublicProfilesResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UserPublicProfilesRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift new file mode 100644 index 00000000..4f719bd9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift @@ -0,0 +1,45 @@ +// +// UserPublicProfilesRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct UserPublicProfilesRelationships: Codable, Hashable { + + public var followers: MultiDataRelationshipDoc + public var following: MultiDataRelationshipDoc + public var publicPlaylists: MultiDataRelationshipDoc + public var publicPicks: MultiDataRelationshipDoc + + public init(followers: MultiDataRelationshipDoc, following: MultiDataRelationshipDoc, publicPlaylists: MultiDataRelationshipDoc, publicPicks: MultiDataRelationshipDoc) { + self.followers = followers + self.following = following + self.publicPlaylists = publicPlaylists + self.publicPicks = publicPicks + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case followers + case following + case publicPlaylists + case publicPicks + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(followers, forKey: .followers) + try container.encode(following, forKey: .following) + try container.encode(publicPlaylists, forKey: .publicPlaylists) + try container.encode(publicPicks, forKey: .publicPicks) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift new file mode 100644 index 00000000..efe04e98 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift @@ -0,0 +1,50 @@ +// +// UserPublicProfilesResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilesResource: Codable, Hashable { + + public var attributes: UserPublicProfilesAttributes? + public var relationships: UserPublicProfilesRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: UserPublicProfilesAttributes? = nil, relationships: UserPublicProfilesRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift new file mode 100644 index 00000000..098f6c7e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// UserPublicProfilesSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserPublicProfilesSingleDataDocument: Codable, Hashable { + + public var data: UserPublicProfilesResource? + public var links: Links? + public var included: [UserPublicProfilesMultiDataDocumentIncludedInner]? + + public init(data: UserPublicProfilesResource? = nil, links: Links? = nil, included: [UserPublicProfilesMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift new file mode 100644 index 00000000..ac3287a9 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// UserRecommendationsMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserRecommendationsMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [UserRecommendationsResource]? + public var links: Links? + public var included: [UserRecommendationsMultiDataDocumentIncludedInner]? + + public init(data: [UserRecommendationsResource]? = nil, links: Links? = nil, included: [UserRecommendationsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..275f8040 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift @@ -0,0 +1,48 @@ +// +// UserRecommendationsMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UserRecommendationsMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typePlaylistsResource(PlaylistsResource) + case typeTracksResource(TracksResource) + case typeUsersResource(UsersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UserRecommendationsMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift new file mode 100644 index 00000000..38212e8c --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift @@ -0,0 +1,41 @@ +// +// UserRecommendationsRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct UserRecommendationsRelationships: Codable, Hashable { + + public var myMixes: MultiDataRelationshipDoc + public var discoveryMixes: MultiDataRelationshipDoc + public var newArrivalMixes: MultiDataRelationshipDoc + + public init(myMixes: MultiDataRelationshipDoc, discoveryMixes: MultiDataRelationshipDoc, newArrivalMixes: MultiDataRelationshipDoc) { + self.myMixes = myMixes + self.discoveryMixes = discoveryMixes + self.newArrivalMixes = newArrivalMixes + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case myMixes + case discoveryMixes + case newArrivalMixes + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(myMixes, forKey: .myMixes) + try container.encode(discoveryMixes, forKey: .discoveryMixes) + try container.encode(newArrivalMixes, forKey: .newArrivalMixes) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift new file mode 100644 index 00000000..22b41310 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift @@ -0,0 +1,51 @@ +// +// UserRecommendationsResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserRecommendationsResource: Codable, Hashable { + + /** attributes object representing some of the resource's data */ + public var attributes: AnyCodable? + public var relationships: UserRecommendationsRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: AnyCodable? = nil, relationships: UserRecommendationsRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift new file mode 100644 index 00000000..f7556754 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// UserRecommendationsSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UserRecommendationsSingleDataDocument: Codable, Hashable { + + public var data: UserRecommendationsResource? + public var links: Links? + public var included: [UserRecommendationsMultiDataDocumentIncludedInner]? + + public init(data: UserRecommendationsResource? = nil, links: Links? = nil, included: [UserRecommendationsMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift new file mode 100644 index 00000000..ca7a7c60 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift @@ -0,0 +1,59 @@ +// +// UsersAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct UsersAttributes: Codable, Hashable { + + /** user name */ + public var username: String + /** ISO 3166-1 alpha-2 country code */ + public var country: String + /** email address */ + public var email: String? + /** Is the email verified */ + public var emailVerified: Bool? + /** Users first name */ + public var firstName: String? + /** Users last name */ + public var lastName: String? + + public init(username: String, country: String, email: String? = nil, emailVerified: Bool? = nil, firstName: String? = nil, lastName: String? = nil) { + self.username = username + self.country = country + self.email = email + self.emailVerified = emailVerified + self.firstName = firstName + self.lastName = lastName + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case username + case country + case email + case emailVerified + case firstName + case lastName + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(username, forKey: .username) + try container.encode(country, forKey: .country) + try container.encodeIfPresent(email, forKey: .email) + try container.encodeIfPresent(emailVerified, forKey: .emailVerified) + try container.encodeIfPresent(firstName, forKey: .firstName) + try container.encodeIfPresent(lastName, forKey: .lastName) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift new file mode 100644 index 00000000..2e7e4383 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// UsersMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UsersMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [UsersResource]? + public var links: Links? + public var included: [UsersMultiDataDocumentIncludedInner]? + + public init(data: [UsersResource]? = nil, links: Links? = nil, included: [UsersMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..75e76dff --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift @@ -0,0 +1,58 @@ +// +// UsersMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UsersMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typePlaylistsResource(PlaylistsResource) + case typeUserEntitlementsResource(UserEntitlementsResource) + case typeUserPublicProfilePicksResource(UserPublicProfilePicksResource) + case typeUserPublicProfilesResource(UserPublicProfilesResource) + case typeUserRecommendationsResource(UserRecommendationsResource) + case typeUsersResource(UsersResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeUserEntitlementsResource(let value): + try container.encode(value) + case .typeUserPublicProfilePicksResource(let value): + try container.encode(value) + case .typeUserPublicProfilesResource(let value): + try container.encode(value) + case .typeUserRecommendationsResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(UserEntitlementsResource.self) { + self = .typeUserEntitlementsResource(value) + } else if let value = try? container.decode(UserPublicProfilePicksResource.self) { + self = .typeUserPublicProfilePicksResource(value) + } else if let value = try? container.decode(UserPublicProfilesResource.self) { + self = .typeUserPublicProfilesResource(value) + } else if let value = try? container.decode(UserRecommendationsResource.self) { + self = .typeUserRecommendationsResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UsersMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift new file mode 100644 index 00000000..697ea324 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift @@ -0,0 +1,40 @@ +// +// UsersRecommendationsRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UsersRecommendationsRelationshipDocument: Codable, Hashable { + + public var data: ResourceIdentifier? + public var links: Links? + public var included: [UsersRecommendationsRelationshipDocumentIncludedInner]? + + public init(data: ResourceIdentifier? = nil, links: Links? = nil, included: [UsersRecommendationsRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..1e1f9e6e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift @@ -0,0 +1,38 @@ +// +// UsersRecommendationsRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UsersRecommendationsRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typePlaylistsResource(PlaylistsResource) + case typeUserRecommendationsResource(UserRecommendationsResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeUserRecommendationsResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(UserRecommendationsResource.self) { + self = .typeUserRecommendationsResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UsersRecommendationsRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift new file mode 100644 index 00000000..8b98cf15 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift @@ -0,0 +1,41 @@ +// +// UsersRelationshipDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UsersRelationshipDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [UsersRelationshipDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [UsersRelationshipDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift new file mode 100644 index 00000000..4a1a9cce --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift @@ -0,0 +1,48 @@ +// +// UsersRelationshipDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum UsersRelationshipDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeUserEntitlementsResource(UserEntitlementsResource) + case typeUserPublicProfilesResource(UserPublicProfilesResource) + case typeUserRecommendationsResource(UserRecommendationsResource) + case typeUsersResource(UsersResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeUserEntitlementsResource(let value): + try container.encode(value) + case .typeUserPublicProfilesResource(let value): + try container.encode(value) + case .typeUserRecommendationsResource(let value): + try container.encode(value) + case .typeUsersResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(UserEntitlementsResource.self) { + self = .typeUserEntitlementsResource(value) + } else if let value = try? container.decode(UserPublicProfilesResource.self) { + self = .typeUserPublicProfilesResource(value) + } else if let value = try? container.decode(UserRecommendationsResource.self) { + self = .typeUserRecommendationsResource(value) + } else if let value = try? container.decode(UsersResource.self) { + self = .typeUsersResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of UsersRelationshipDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift new file mode 100644 index 00000000..68fc12ef --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift @@ -0,0 +1,41 @@ +// +// UsersRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct UsersRelationships: Codable, Hashable { + + public var entitlements: SingletonDataRelationshipDoc + public var publicProfile: SingletonDataRelationshipDoc + public var recommendations: SingletonDataRelationshipDoc + + public init(entitlements: SingletonDataRelationshipDoc, publicProfile: SingletonDataRelationshipDoc, recommendations: SingletonDataRelationshipDoc) { + self.entitlements = entitlements + self.publicProfile = publicProfile + self.recommendations = recommendations + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case entitlements + case publicProfile + case recommendations + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(entitlements, forKey: .entitlements) + try container.encode(publicProfile, forKey: .publicProfile) + try container.encode(recommendations, forKey: .recommendations) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift new file mode 100644 index 00000000..0cfea0d1 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift @@ -0,0 +1,50 @@ +// +// UsersResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UsersResource: Codable, Hashable { + + public var attributes: UsersAttributes? + public var relationships: UsersRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: UsersAttributes? = nil, relationships: UsersRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift new file mode 100644 index 00000000..2cee1bbc --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// UsersSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct UsersSingleDataDocument: Codable, Hashable { + + public var data: UsersResource? + public var links: Links? + public var included: [UsersMultiDataDocumentIncludedInner]? + + public init(data: UsersResource? = nil, links: Links? = nil, included: [UsersMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift new file mode 100644 index 00000000..f5ea0912 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift @@ -0,0 +1,39 @@ +// +// VideoLinkMeta.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** metadata about a video */ +public struct VideoLinkMeta: Codable, Hashable { + + /** video width (in pixels) */ + public var width: Int + /** video height (in pixels) */ + public var height: Int + + public init(width: Int, height: Int) { + self.width = width + self.height = height + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case width + case height + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(width, forKey: .width) + try container.encode(height, forKey: .height) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift new file mode 100644 index 00000000..b3f85ccc --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift @@ -0,0 +1,89 @@ +// +// VideosAttributes.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** attributes object representing some of the resource's data */ +public struct VideosAttributes: Codable, Hashable { + + public enum Availability: String, Codable, CaseIterable { + case stream = "STREAM" + case dj = "DJ" + case stem = "STEM" + } + /** Album item's title */ + public var title: String + /** Version of the album's item; complements title */ + public var version: String? + /** ISRC code */ + public var isrc: String + /** Duration expressed in accordance with ISO 8601 */ + public var duration: String + /** Copyright information */ + public var copyright: String? + /** Release date (ISO-8601) */ + public var releaseDate: Date? + /** Indicates whether a catalog item consist of any explicit content */ + public var explicit: Bool + /** Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible */ + public var popularity: Double + /** Defines a catalog item availability e.g. for streaming, DJs, stems */ + public var availability: [Availability]? + /** Represents available links to, and metadata about, an album item images */ + public var imageLinks: [CatalogueItemImageLink]? + /** Represents available links to something that is related to a catalog item, but external to the TIDAL API */ + public var externalLinks: [CatalogueItemExternalLink]? + + public init(title: String, version: String? = nil, isrc: String, duration: String, copyright: String? = nil, releaseDate: Date? = nil, explicit: Bool, popularity: Double, availability: [Availability]? = nil, imageLinks: [CatalogueItemImageLink]? = nil, externalLinks: [CatalogueItemExternalLink]? = nil) { + self.title = title + self.version = version + self.isrc = isrc + self.duration = duration + self.copyright = copyright + self.releaseDate = releaseDate + self.explicit = explicit + self.popularity = popularity + self.availability = availability + self.imageLinks = imageLinks + self.externalLinks = externalLinks + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case title + case version + case isrc + case duration + case copyright + case releaseDate + case explicit + case popularity + case availability + case imageLinks + case externalLinks + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(title, forKey: .title) + try container.encodeIfPresent(version, forKey: .version) + try container.encode(isrc, forKey: .isrc) + try container.encode(duration, forKey: .duration) + try container.encodeIfPresent(copyright, forKey: .copyright) + try container.encodeIfPresent(releaseDate, forKey: .releaseDate) + try container.encode(explicit, forKey: .explicit) + try container.encode(popularity, forKey: .popularity) + try container.encodeIfPresent(availability, forKey: .availability) + try container.encodeIfPresent(imageLinks, forKey: .imageLinks) + try container.encodeIfPresent(externalLinks, forKey: .externalLinks) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift new file mode 100644 index 00000000..a350240f --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift @@ -0,0 +1,41 @@ +// +// VideosMultiDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct VideosMultiDataDocument: Codable, Hashable { + + /** array of primary resource data */ + public var data: [VideosResource]? + public var links: Links? + public var included: [VideosMultiDataDocumentIncludedInner]? + + public init(data: [VideosResource]? = nil, links: Links? = nil, included: [VideosMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift new file mode 100644 index 00000000..ef4bb734 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift @@ -0,0 +1,58 @@ +// +// VideosMultiDataDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum VideosMultiDataDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typePlaylistsResource(PlaylistsResource) + case typeProvidersResource(ProvidersResource) + case typeTracksResource(TracksResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typePlaylistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeTracksResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(PlaylistsResource.self) { + self = .typePlaylistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(TracksResource.self) { + self = .typeTracksResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of VideosMultiDataDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift new file mode 100644 index 00000000..00ec9be5 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift @@ -0,0 +1,41 @@ +// +// VideosRelationships.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +/** relationships object describing relationships between the resource and other resources */ +public struct VideosRelationships: Codable, Hashable { + + public var albums: MultiDataRelationshipDoc + public var artists: MultiDataRelationshipDoc + public var providers: MultiDataRelationshipDoc + + public init(albums: MultiDataRelationshipDoc, artists: MultiDataRelationshipDoc, providers: MultiDataRelationshipDoc) { + self.albums = albums + self.artists = artists + self.providers = providers + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case albums + case artists + case providers + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encode(albums, forKey: .albums) + try container.encode(artists, forKey: .artists) + try container.encode(providers, forKey: .providers) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift new file mode 100644 index 00000000..da8bfc14 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift @@ -0,0 +1,41 @@ +// +// VideosRelationshipsDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct VideosRelationshipsDocument: Codable, Hashable { + + /** array of relationship resource linkages */ + public var data: [ResourceIdentifier]? + public var links: Links? + public var included: [VideosRelationshipsDocumentIncludedInner]? + + public init(data: [ResourceIdentifier]? = nil, links: Links? = nil, included: [VideosRelationshipsDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift new file mode 100644 index 00000000..37542735 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift @@ -0,0 +1,48 @@ +// +// VideosRelationshipsDocumentIncludedInner.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public enum VideosRelationshipsDocumentIncludedInner: Codable, JSONEncodable, Hashable { + case typeAlbumsResource(AlbumsResource) + case typeArtistsResource(ArtistsResource) + case typeProvidersResource(ProvidersResource) + case typeVideosResource(VideosResource) + + public func encode(to encoder: Encoder) throws { + var container = encoder.singleValueContainer() + switch self { + case .typeAlbumsResource(let value): + try container.encode(value) + case .typeArtistsResource(let value): + try container.encode(value) + case .typeProvidersResource(let value): + try container.encode(value) + case .typeVideosResource(let value): + try container.encode(value) + } + } + + public init(from decoder: Decoder) throws { + let container = try decoder.singleValueContainer() + if let value = try? container.decode(AlbumsResource.self) { + self = .typeAlbumsResource(value) + } else if let value = try? container.decode(ArtistsResource.self) { + self = .typeArtistsResource(value) + } else if let value = try? container.decode(ProvidersResource.self) { + self = .typeProvidersResource(value) + } else if let value = try? container.decode(VideosResource.self) { + self = .typeVideosResource(value) + } else { + throw DecodingError.typeMismatch(Self.Type.self, .init(codingPath: decoder.codingPath, debugDescription: "Unable to decode instance of VideosRelationshipsDocumentIncludedInner")) + } + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift new file mode 100644 index 00000000..a1eef54e --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift @@ -0,0 +1,50 @@ +// +// VideosResource.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct VideosResource: Codable, Hashable { + + public var attributes: VideosAttributes? + public var relationships: VideosRelationships? + public var links: Links? + /** resource unique identifier */ + public var id: String + /** resource unique type */ + public var type: String + + public init(attributes: VideosAttributes? = nil, relationships: VideosRelationships? = nil, links: Links? = nil, id: String, type: String) { + self.attributes = attributes + self.relationships = relationships + self.links = links + self.id = id + self.type = type + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case attributes + case relationships + case links + case id + case type + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(attributes, forKey: .attributes) + try container.encodeIfPresent(relationships, forKey: .relationships) + try container.encodeIfPresent(links, forKey: .links) + try container.encode(id, forKey: .id) + try container.encode(type, forKey: .type) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift new file mode 100644 index 00000000..44165d63 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift @@ -0,0 +1,40 @@ +// +// VideosSingleDataDocument.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if canImport(AnyCodable) +import AnyCodable +#endif + +public struct VideosSingleDataDocument: Codable, Hashable { + + public var data: VideosResource? + public var links: Links? + public var included: [VideosMultiDataDocumentIncludedInner]? + + public init(data: VideosResource? = nil, links: Links? = nil, included: [VideosMultiDataDocumentIncludedInner]? = nil) { + self.data = data + self.links = links + self.included = included + } + + public enum CodingKeys: String, CodingKey, CaseIterable { + case data + case links + case included + } + + // Encodable protocol methods + + public func encode(to encoder: Encoder) throws { + var container = encoder.container(keyedBy: CodingKeys.self) + try container.encodeIfPresent(data, forKey: .data) + try container.encodeIfPresent(links, forKey: .links) + try container.encodeIfPresent(included, forKey: .included) + } +} + diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift new file mode 100644 index 00000000..cc328880 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift @@ -0,0 +1,56 @@ +// +// OpenISO8601DateFormatter.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +// https://stackoverflow.com/a/50281094/976628 +public class OpenISO8601DateFormatter: DateFormatter { + static let withoutSeconds: DateFormatter = { + let formatter = DateFormatter() + formatter.calendar = Calendar(identifier: .iso8601) + formatter.locale = Locale(identifier: "en_US_POSIX") + formatter.timeZone = TimeZone(secondsFromGMT: 0) + formatter.dateFormat = "yyyy-MM-dd'T'HH:mm:ssZZZZZ" + return formatter + }() + + static let withoutTime: DateFormatter = { + let formatter = DateFormatter() + formatter.calendar = Calendar(identifier: .iso8601) + formatter.locale = Locale(identifier: "en_US_POSIX") + formatter.timeZone = TimeZone(secondsFromGMT: 0) + formatter.dateFormat = "yyyy-MM-dd" + return formatter + }() + + private func setup() { + calendar = Calendar(identifier: .iso8601) + locale = Locale(identifier: "en_US_POSIX") + timeZone = TimeZone(secondsFromGMT: 0) + dateFormat = "yyyy-MM-dd'T'HH:mm:ss.SSSZZZZZ" + } + + override init() { + super.init() + setup() + } + + required init?(coder aDecoder: NSCoder) { + super.init(coder: aDecoder) + setup() + } + + override public func date(from string: String) -> Date? { + if let result = super.date(from: string) { + return result + } else if let result = OpenISO8601DateFormatter.withoutSeconds.date(from: string) { + return result + } + + return OpenISO8601DateFormatter.withoutTime.date(from: string) + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift new file mode 100644 index 00000000..fbaa6242 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift @@ -0,0 +1,26 @@ +// SynchronizedDictionary.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +internal struct SynchronizedDictionary { + + private var dictionary = [K: V]() + private let lock = NSRecursiveLock() + + internal subscript(key: K) -> V? { + get { + lock.lock() + defer { lock.unlock() } + return self.dictionary[key] + } + set { + lock.lock() + defer { lock.unlock() } + self.dictionary[key] = newValue + } + } +} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift new file mode 100644 index 00000000..cbbb21f4 --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift @@ -0,0 +1,670 @@ +// URLSessionImplementations.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation +#if !os(macOS) +import MobileCoreServices +#endif +#if canImport(UniformTypeIdentifiers) +import UniformTypeIdentifiers +#endif + +// Protocol defined for a session data task. This allows mocking out the URLSessionProtocol below since +// you may not want to create or return a real URLSessionDataTask. +public protocol URLSessionDataTaskProtocol { + func resume() + + var taskIdentifier: Int { get } + + var progress: Progress { get } + + func cancel() +} + +// Protocol allowing implementations to alter what is returned or to test their implementations. +public protocol URLSessionProtocol { + // Task which performs the network fetch. Expected to be from URLSession.dataTask(with:completionHandler:) such that a network request + // is sent off when `.resume()` is called. + func dataTaskFromProtocol(with request: URLRequest, completionHandler: @escaping @Sendable (Data?, URLResponse?, Error?) -> Void) -> URLSessionDataTaskProtocol +} + +extension URLSession: URLSessionProtocol { + // Passthrough to URLSession.dataTask(with:completionHandler) since URLSessionDataTask conforms to URLSessionDataTaskProtocol and fetches the network data. + public func dataTaskFromProtocol(with request: URLRequest, completionHandler: @escaping @Sendable (Data?, URLResponse?, (any Error)?) -> Void) -> any URLSessionDataTaskProtocol { + return dataTask(with: request, completionHandler: completionHandler) + } +} + +extension URLSessionDataTask: URLSessionDataTaskProtocol {} + +class URLSessionRequestBuilderFactory: RequestBuilderFactory { + func getNonDecodableBuilder() -> RequestBuilder.Type { + return URLSessionRequestBuilder.self + } + + func getBuilder() -> RequestBuilder.Type { + return URLSessionDecodableRequestBuilder.self + } +} + +public typealias OpenAPIClientAPIChallengeHandler = ((URLSession, URLSessionTask, URLAuthenticationChallenge) -> (URLSession.AuthChallengeDisposition, URLCredential?)) + +// Store the URLSession's delegate to retain its reference +private let sessionDelegate = SessionDelegate() + +// Store the URLSession to retain its reference +private let defaultURLSession = URLSession(configuration: .default, delegate: sessionDelegate, delegateQueue: nil) + +// Store current taskDidReceiveChallenge for every URLSessionTask +private var challengeHandlerStore = SynchronizedDictionary() + +// Store current URLCredential for every URLSessionTask +private var credentialStore = SynchronizedDictionary() + +open class URLSessionRequestBuilder: RequestBuilder { + + /** + May be assigned if you want to control the authentication challenges. + */ + public var taskDidReceiveChallenge: OpenAPIClientAPIChallengeHandler? + + required public init(method: String, URLString: String, parameters: [String: Any]?, headers: [String: String] = [:], requiresAuthentication: Bool) { + super.init(method: method, URLString: URLString, parameters: parameters, headers: headers, requiresAuthentication: requiresAuthentication) + } + + /** + May be overridden by a subclass if you want to control the URLSession + configuration. + */ + open func createURLSession() -> URLSessionProtocol { + return defaultURLSession + } + + /** + May be overridden by a subclass if you want to control the Content-Type + that is given to an uploaded form part. + + Return nil to use the default behavior (inferring the Content-Type from + the file extension). Return the desired Content-Type otherwise. + */ + open func contentTypeForFormPart(fileURL: URL) -> String? { + return nil + } + + /** + May be overridden by a subclass if you want to control the URLRequest + configuration (e.g. to override the cache policy). + */ + open func createURLRequest(urlSession: URLSessionProtocol, method: HTTPMethod, encoding: ParameterEncoding, headers: [String: String]) throws -> URLRequest { + + guard let url = URL(string: URLString) else { + throw DownloadException.requestMissingURL + } + + var originalRequest = URLRequest(url: url) + + originalRequest.httpMethod = method.rawValue + + buildHeaders().forEach { key, value in + originalRequest.setValue(value, forHTTPHeaderField: key) + } + + let modifiedRequest = try encoding.encode(originalRequest, with: parameters) + + return modifiedRequest + } + + @discardableResult + override open func execute(_ apiResponseQueue: DispatchQueue = OpenAPIClientAPI.apiResponseQueue, _ completion: @escaping (_ result: Swift.Result, ErrorResponse>) -> Void) -> RequestTask { + let urlSession = createURLSession() + + guard let xMethod = HTTPMethod(rawValue: method) else { + fatalError("Unsupported Http method - \(method)") + } + + let encoding: ParameterEncoding + + switch xMethod { + case .get, .head: + encoding = URLEncoding() + + case .options, .post, .put, .patch, .delete, .trace, .connect: + let contentType = headers["Content-Type"] ?? "application/json" + + if contentType.hasPrefix("application/") && contentType.contains("json") { + encoding = JSONDataEncoding() + } else if contentType.hasPrefix("multipart/form-data") { + encoding = FormDataEncoding(contentTypeForFormPart: contentTypeForFormPart(fileURL:)) + } else if contentType.hasPrefix("application/x-www-form-urlencoded") { + encoding = FormURLEncoding() + } else if contentType.hasPrefix("application/octet-stream"){ + encoding = OctetStreamEncoding() + } else { + fatalError("Unsupported Media Type - \(contentType)") + } + } + + do { + let request = try createURLRequest(urlSession: urlSession, method: xMethod, encoding: encoding, headers: headers) + + var taskIdentifier: Int? + let cleanupRequest = { + if let taskIdentifier = taskIdentifier { + challengeHandlerStore[taskIdentifier] = nil + credentialStore[taskIdentifier] = nil + } + } + + let dataTask = urlSession.dataTaskFromProtocol(with: request) { data, response, error in + apiResponseQueue.async { + self.processRequestResponse(urlRequest: request, data: data, response: response, error: error, completion: completion) + cleanupRequest() + } + } + + onProgressReady?(dataTask.progress) + + taskIdentifier = dataTask.taskIdentifier + challengeHandlerStore[dataTask.taskIdentifier] = taskDidReceiveChallenge + credentialStore[dataTask.taskIdentifier] = credential + + dataTask.resume() + + requestTask.set(task: dataTask) + } catch { + apiResponseQueue.async { + completion(.failure(ErrorResponse.error(415, nil, nil, error))) + } + } + + return requestTask + } + + fileprivate func processRequestResponse(urlRequest: URLRequest, data: Data?, response: URLResponse?, error: Error?, completion: @escaping (_ result: Swift.Result, ErrorResponse>) -> Void) { + + if let error = error { + completion(.failure(ErrorResponse.error(-1, data, response, error))) + return + } + + guard let httpResponse = response as? HTTPURLResponse else { + completion(.failure(ErrorResponse.error(-2, data, response, DecodableRequestBuilderError.nilHTTPResponse))) + return + } + + guard httpResponse.isStatusCodeSuccessful else { + completion(.failure(ErrorResponse.error(httpResponse.statusCode, data, response, DecodableRequestBuilderError.unsuccessfulHTTPStatusCode))) + return + } + + switch T.self { + case is Void.Type: + + completion(.success(Response(response: httpResponse, body: () as! T, bodyData: data))) + + default: + fatalError("Unsupported Response Body Type - \(String(describing: T.self))") + } + + } + + open func buildHeaders() -> [String: String] { + var httpHeaders: [String: String] = [:] + for (key, value) in OpenAPIClientAPI.customHeaders { + httpHeaders[key] = value + } + for (key, value) in headers { + httpHeaders[key] = value + } + return httpHeaders + } + + fileprivate func getFileName(fromContentDisposition contentDisposition: String?) -> String? { + + guard let contentDisposition = contentDisposition else { + return nil + } + + let items = contentDisposition.components(separatedBy: ";") + + var filename: String? + + for contentItem in items { + + let filenameKey = "filename=" + guard let range = contentItem.range(of: filenameKey) else { + continue + } + + filename = contentItem + return filename? + .replacingCharacters(in: range, with: "") + .replacingOccurrences(of: "\"", with: "") + .trimmingCharacters(in: .whitespacesAndNewlines) + } + + return filename + + } + + fileprivate func getPath(from url: URL) throws -> String { + + guard var path = URLComponents(url: url, resolvingAgainstBaseURL: true)?.path else { + throw DownloadException.requestMissingPath + } + + if path.hasPrefix("/") { + path.remove(at: path.startIndex) + } + + return path + + } + + fileprivate func getURL(from urlRequest: URLRequest) throws -> URL { + + guard let url = urlRequest.url else { + throw DownloadException.requestMissingURL + } + + return url + } + +} + +open class URLSessionDecodableRequestBuilder: URLSessionRequestBuilder { + override fileprivate func processRequestResponse(urlRequest: URLRequest, data: Data?, response: URLResponse?, error: Error?, completion: @escaping (_ result: Swift.Result, ErrorResponse>) -> Void) { + + if let error = error { + completion(.failure(ErrorResponse.error(-1, data, response, error))) + return + } + + guard let httpResponse = response as? HTTPURLResponse else { + completion(.failure(ErrorResponse.error(-2, data, response, DecodableRequestBuilderError.nilHTTPResponse))) + return + } + + guard httpResponse.isStatusCodeSuccessful else { + completion(.failure(ErrorResponse.error(httpResponse.statusCode, data, response, DecodableRequestBuilderError.unsuccessfulHTTPStatusCode))) + return + } + + switch T.self { + case is String.Type: + + let body = data.flatMap { String(data: $0, encoding: .utf8) } ?? "" + + completion(.success(Response(response: httpResponse, body: body as! T, bodyData: data))) + + case is URL.Type: + do { + + guard error == nil else { + throw DownloadException.responseFailed + } + + guard let data = data else { + throw DownloadException.responseDataMissing + } + + let fileManager = FileManager.default + let cachesDirectory = fileManager.urls(for: .cachesDirectory, in: .userDomainMask)[0] + let requestURL = try getURL(from: urlRequest) + + var requestPath = try getPath(from: requestURL) + + if let headerFileName = getFileName(fromContentDisposition: httpResponse.allHeaderFields["Content-Disposition"] as? String) { + requestPath = requestPath.appending("/\(headerFileName)") + } else { + requestPath = requestPath.appending("/tmp.OpenAPIClient.\(UUID().uuidString)") + } + + let filePath = cachesDirectory.appendingPathComponent(requestPath) + let directoryPath = filePath.deletingLastPathComponent().path + + try fileManager.createDirectory(atPath: directoryPath, withIntermediateDirectories: true, attributes: nil) + try data.write(to: filePath, options: .atomic) + + completion(.success(Response(response: httpResponse, body: filePath as! T, bodyData: data))) + + } catch let requestParserError as DownloadException { + completion(.failure(ErrorResponse.error(400, data, response, requestParserError))) + } catch { + completion(.failure(ErrorResponse.error(400, data, response, error))) + } + + case is Void.Type: + + completion(.success(Response(response: httpResponse, body: () as! T, bodyData: data))) + + case is Data.Type: + + completion(.success(Response(response: httpResponse, body: data as! T, bodyData: data))) + + default: + + guard let unwrappedData = data, !unwrappedData.isEmpty else { + if let expressibleByNilLiteralType = T.self as? ExpressibleByNilLiteral.Type { + completion(.success(Response(response: httpResponse, body: expressibleByNilLiteralType.init(nilLiteral: ()) as! T, bodyData: data))) + } else { + completion(.failure(ErrorResponse.error(httpResponse.statusCode, nil, response, DecodableRequestBuilderError.emptyDataResponse))) + } + return + } + + let decodeResult = CodableHelper.decode(T.self, from: unwrappedData) + + switch decodeResult { + case let .success(decodableObj): + completion(.success(Response(response: httpResponse, body: decodableObj, bodyData: unwrappedData))) + case let .failure(error): + completion(.failure(ErrorResponse.error(httpResponse.statusCode, unwrappedData, response, error))) + } + } + } +} + +private class SessionDelegate: NSObject, URLSessionTaskDelegate { + func urlSession(_ session: URLSession, task: URLSessionTask, didReceive challenge: URLAuthenticationChallenge, completionHandler: @escaping (URLSession.AuthChallengeDisposition, URLCredential?) -> Void) { + + var disposition: URLSession.AuthChallengeDisposition = .performDefaultHandling + + var credential: URLCredential? + + if let taskDidReceiveChallenge = challengeHandlerStore[task.taskIdentifier] { + (disposition, credential) = taskDidReceiveChallenge(session, task, challenge) + } else { + if challenge.previousFailureCount > 0 { + disposition = .rejectProtectionSpace + } else { + credential = credentialStore[task.taskIdentifier] ?? session.configuration.urlCredentialStorage?.defaultCredential(for: challenge.protectionSpace) + + if credential != nil { + disposition = .useCredential + } + } + } + + completionHandler(disposition, credential) + } +} + +public enum HTTPMethod: String { + case options = "OPTIONS" + case get = "GET" + case head = "HEAD" + case post = "POST" + case put = "PUT" + case patch = "PATCH" + case delete = "DELETE" + case trace = "TRACE" + case connect = "CONNECT" +} + +public protocol ParameterEncoding { + func encode(_ urlRequest: URLRequest, with parameters: [String: Any]?) throws -> URLRequest +} + +private class URLEncoding: ParameterEncoding { + func encode(_ urlRequest: URLRequest, with parameters: [String: Any]?) throws -> URLRequest { + + var urlRequest = urlRequest + + guard let parameters = parameters else { return urlRequest } + + guard let url = urlRequest.url else { + throw DownloadException.requestMissingURL + } + + if var urlComponents = URLComponents(url: url, resolvingAgainstBaseURL: false), !parameters.isEmpty { + urlComponents.queryItems = APIHelper.mapValuesToQueryItems(parameters) + urlRequest.url = urlComponents.url + } + + return urlRequest + } +} + +private class FormDataEncoding: ParameterEncoding { + + let contentTypeForFormPart: (_ fileURL: URL) -> String? + + init(contentTypeForFormPart: @escaping (_ fileURL: URL) -> String?) { + self.contentTypeForFormPart = contentTypeForFormPart + } + + func encode(_ urlRequest: URLRequest, with parameters: [String: Any]?) throws -> URLRequest { + + var urlRequest = urlRequest + + guard let parameters = parameters, !parameters.isEmpty else { + return urlRequest + } + + let boundary = "Boundary-\(UUID().uuidString)" + + urlRequest.setValue("multipart/form-data; boundary=\(boundary)", forHTTPHeaderField: "Content-Type") + + for (key, value) in parameters { + for value in (value as? Array ?? [value]) { + switch value { + case let fileURL as URL: + + urlRequest = try configureFileUploadRequest( + urlRequest: urlRequest, + boundary: boundary, + name: key, + fileURL: fileURL + ) + + case let string as String: + + if let data = string.data(using: .utf8) { + urlRequest = configureDataUploadRequest( + urlRequest: urlRequest, + boundary: boundary, + name: key, + data: data + ) + } + + case let number as NSNumber: + + if let data = number.stringValue.data(using: .utf8) { + urlRequest = configureDataUploadRequest( + urlRequest: urlRequest, + boundary: boundary, + name: key, + data: data + ) + } + + case let data as Data: + + urlRequest = configureDataUploadRequest( + urlRequest: urlRequest, + boundary: boundary, + name: key, + data: data + ) + + case let uuid as UUID: + + if let data = uuid.uuidString.data(using: .utf8) { + urlRequest = configureDataUploadRequest( + urlRequest: urlRequest, + boundary: boundary, + name: key, + data: data + ) + } + + default: + fatalError("Unprocessable value \(value) with key \(key)") + } + } + } + + var body = urlRequest.httpBody.orEmpty + + body.append("\r\n--\(boundary)--\r\n") + + urlRequest.httpBody = body + + return urlRequest + } + + private func configureFileUploadRequest(urlRequest: URLRequest, boundary: String, name: String, fileURL: URL) throws -> URLRequest { + + var urlRequest = urlRequest + + var body = urlRequest.httpBody.orEmpty + + let fileData = try Data(contentsOf: fileURL) + + let mimetype = contentTypeForFormPart(fileURL) ?? mimeType(for: fileURL) + + let fileName = fileURL.lastPathComponent + + // If we already added something then we need an additional newline. + if body.count > 0 { + body.append("\r\n") + } + + // Value boundary. + body.append("--\(boundary)\r\n") + + // Value headers. + body.append("Content-Disposition: form-data; name=\"\(name)\"; filename=\"\(fileName)\"\r\n") + body.append("Content-Type: \(mimetype)\r\n") + + // Separate headers and body. + body.append("\r\n") + + // The value data. + body.append(fileData) + + urlRequest.httpBody = body + + return urlRequest + } + + private func configureDataUploadRequest(urlRequest: URLRequest, boundary: String, name: String, data: Data) -> URLRequest { + + var urlRequest = urlRequest + + var body = urlRequest.httpBody.orEmpty + + // If we already added something then we need an additional newline. + if body.count > 0 { + body.append("\r\n") + } + + // Value boundary. + body.append("--\(boundary)\r\n") + + // Value headers. + body.append("Content-Disposition: form-data; name=\"\(name)\"\r\n") + + // Separate headers and body. + body.append("\r\n") + + // The value data. + body.append(data) + + urlRequest.httpBody = body + + return urlRequest + + } + + func mimeType(for url: URL) -> String { + let pathExtension = url.pathExtension + + if #available(macOS 11.0, iOS 14.0, tvOS 14.0, watchOS 7.0, *) { + #if canImport(UniformTypeIdentifiers) + if let utType = UTType(filenameExtension: pathExtension) { + return utType.preferredMIMEType ?? "application/octet-stream" + } + #else + return "application/octet-stream" + #endif + } else { + if let uti = UTTypeCreatePreferredIdentifierForTag(kUTTagClassFilenameExtension, pathExtension as NSString, nil)?.takeRetainedValue(), + let mimetype = UTTypeCopyPreferredTagWithClass(uti, kUTTagClassMIMEType)?.takeRetainedValue() { + return mimetype as String + } + return "application/octet-stream" + } + return "application/octet-stream" + } + +} + +private class FormURLEncoding: ParameterEncoding { + func encode(_ urlRequest: URLRequest, with parameters: [String: Any]?) throws -> URLRequest { + + var urlRequest = urlRequest + + var requestBodyComponents = URLComponents() + requestBodyComponents.queryItems = APIHelper.mapValuesToQueryItems(parameters ?? [:]) + + if urlRequest.value(forHTTPHeaderField: "Content-Type") == nil { + urlRequest.setValue("application/x-www-form-urlencoded", forHTTPHeaderField: "Content-Type") + } + + urlRequest.httpBody = requestBodyComponents.query?.data(using: .utf8) + + return urlRequest + } +} + +private class OctetStreamEncoding: ParameterEncoding { + func encode(_ urlRequest: URLRequest, with parameters: [String: Any]?) throws -> URLRequest { + + var urlRequest = urlRequest + + guard let body = parameters?["body"] else { return urlRequest } + + if urlRequest.value(forHTTPHeaderField: "Content-Type") == nil { + urlRequest.setValue("application/octet-stream", forHTTPHeaderField: "Content-Type") + } + + switch body { + case let fileURL as URL: + urlRequest.httpBody = try Data(contentsOf: fileURL) + case let data as Data: + urlRequest.httpBody = data + default: + fatalError("Unprocessable body \(body)") + } + + return urlRequest + } +} + +private extension Data { + /// Append string to Data + /// + /// Rather than littering my code with calls to `dataUsingEncoding` to convert strings to Data, and then add that data to the Data, this wraps it in a nice convenient little extension to Data. This converts using UTF-8. + /// + /// - parameter string: The string to be added to the `Data`. + + mutating func append(_ string: String) { + if let data = string.data(using: .utf8) { + append(data) + } + } +} + +private extension Optional where Wrapped == Data { + var orEmpty: Data { + self ?? Data() + } +} + +extension JSONDataEncoding: ParameterEncoding {} diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift new file mode 100644 index 00000000..6a0d4c9d --- /dev/null +++ b/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift @@ -0,0 +1,161 @@ +// Validation.swift +// +// Generated by openapi-generator +// https://openapi-generator.tech +// + +import Foundation + +public struct StringRule { + public var minLength: Int? + public var maxLength: Int? + public var pattern: String? +} + +public struct NumericRule { + public var minimum: T? + public var exclusiveMinimum = false + public var maximum: T? + public var exclusiveMaximum = false + public var multipleOf: T? +} + +public struct ArrayRule { + public var minItems: Int? + public var maxItems: Int? + public var uniqueItems: Bool +} + +public enum StringValidationErrorKind: Error { + case minLength, maxLength, pattern +} + +public enum NumericValidationErrorKind: Error { + case minimum, maximum, multipleOf +} + +public enum ArrayValidationErrorKind: Error { + case minItems, maxItems, uniqueItems +} + +public struct ValidationError: Error { + public fileprivate(set) var kinds: Set +} + +public struct Validator { + /// Validate a string against a rule. + /// - Parameter string: The String you wish to validate. + /// - Parameter rule: The StringRule you wish to use for validation. + /// - Returns: A validated string. + /// - Throws: `ValidationError` if the string is invalid against the rule, + /// `NSError` if the rule.pattern is invalid. + public static func validate(_ string: String, against rule: StringRule) throws -> String { + var error = ValidationError(kinds: []) + if let minLength = rule.minLength, !(minLength <= string.count) { + error.kinds.insert(.minLength) + } + if let maxLength = rule.maxLength, !(string.count <= maxLength) { + error.kinds.insert(.maxLength) + } + if let pattern = rule.pattern { + let matches = try NSRegularExpression(pattern: pattern, options: .caseInsensitive) + .matches(in: string, range: .init(location: 0, length: string.utf16.count)) + if matches.isEmpty { + error.kinds.insert(.pattern) + } + } + guard error.kinds.isEmpty else { + throw error + } + return string + } + + /// Validate a integer against a rule. + /// - Parameter numeric: The integer you wish to validate. + /// - Parameter rule: The NumericRule you wish to use for validation. + /// - Returns: A validated integer. + /// - Throws: `ValidationError` if the numeric is invalid against the rule. + public static func validate(_ numeric: T, against rule: NumericRule) throws -> T { + var error = ValidationError(kinds: []) + if let minium = rule.minimum { + if !rule.exclusiveMinimum, minium > numeric { + error.kinds.insert(.minimum) + } + if rule.exclusiveMinimum, minium >= numeric { + error.kinds.insert(.minimum) + } + } + if let maximum = rule.maximum { + if !rule.exclusiveMaximum, numeric > maximum { + error.kinds.insert(.maximum) + } + if rule.exclusiveMaximum, numeric >= maximum { + error.kinds.insert(.maximum) + } + } + if let multipleOf = rule.multipleOf, !numeric.isMultiple(of: multipleOf) { + error.kinds.insert(.multipleOf) + } + guard error.kinds.isEmpty else { + throw error + } + return numeric + } + + /// Validate a fractional number against a rule. + /// - Parameter numeric: The fractional number you wish to validate. + /// - Parameter rule: The NumericRule you wish to use for validation. + /// - Returns: A validated fractional number. + /// - Throws: `ValidationError` if the numeric is invalid against the rule. + public static func validate(_ numeric: T, against rule: NumericRule) throws -> T { + var error = ValidationError(kinds: []) + if let minium = rule.minimum { + if !rule.exclusiveMinimum, minium > numeric { + error.kinds.insert(.minimum) + } + if rule.exclusiveMinimum, minium >= numeric { + error.kinds.insert(.minimum) + } + } + if let maximum = rule.maximum { + if !rule.exclusiveMaximum, numeric > maximum { + error.kinds.insert(.maximum) + } + if rule.exclusiveMaximum, numeric >= maximum { + error.kinds.insert(.maximum) + } + } + if let multipleOf = rule.multipleOf, numeric.remainder(dividingBy: multipleOf) != 0 { + error.kinds.insert(.multipleOf) + } + guard error.kinds.isEmpty else { + throw error + } + return numeric + } + + /// Validate a array against a rule. + /// - Parameter array: The Array you wish to validate. + /// - Parameter rule: The ArrayRule you wish to use for validation. + /// - Returns: A validated array. + /// - Throws: `ValidationError` if the string is invalid against the rule. + public static func validate(_ array: Array, against rule: ArrayRule) throws -> Array { + var error = ValidationError(kinds: []) + if let minItems = rule.minItems, !(minItems <= array.count) { + error.kinds.insert(.minItems) + } + if let maxItems = rule.maxItems, !(array.count <= maxItems) { + error.kinds.insert(.maxItems) + } + if rule.uniqueItems { + let unique = Set(array) + if unique.count != array.count { + error.kinds.insert(.uniqueItems) + } + } + guard error.kinds.isEmpty else { + throw error + } + return array + } +} diff --git a/Sources/API/Generated/README.md b/Sources/API/Generated/README.md new file mode 100644 index 00000000..27be4411 --- /dev/null +++ b/Sources/API/Generated/README.md @@ -0,0 +1,174 @@ +# Swift5 API client for OpenAPIClient + +The User API v2 provides a set of JSON:API compatible endpoints for getting the TIDAL users, and more + +## Overview +This API client was generated by the [OpenAPI Generator](https://openapi-generator.tech) project. By using the [openapi-spec](https://github.com/OAI/OpenAPI-Specification) from a remote server, you can easily generate an API client. + +- API version: 1.0.0 +- Package version: +- Generator version: 7.9.0 +- Build package: org.openapitools.codegen.languages.Swift5ClientCodegen +For more information, please visit [https://github.com/orgs/tidal-music/discussions](https://github.com/orgs/tidal-music/discussions) + +## Installation + +### Carthage + +Run `carthage update` + +### CocoaPods + +Run `pod install` + +## Documentation for API Endpoints + +All URIs are relative to *https://openapi.tidal.com/v2* + +Class | Method | HTTP request | Description +------------ | ------------- | ------------- | ------------- +*UserEntitlementsAPI* | [**getMyUserEntitlements**](docs/UserEntitlementsAPI.md#getmyuserentitlements) | **GET** /userEntitlements/me | Get the current users entitlements +*UserEntitlementsAPI* | [**getUserEntitlementsById**](docs/UserEntitlementsAPI.md#getuserentitlementsbyid) | **GET** /userEntitlements/{id} | Get user entitlements for user +*UserPublicProfilePicksAPI* | [**getMyUserPublicProfilePicks**](docs/UserPublicProfilePicksAPI.md#getmyuserpublicprofilepicks) | **GET** /userPublicProfilePicks/me | Get my picks +*UserPublicProfilePicksAPI* | [**getUserPublicProfilePickItemRelationship**](docs/UserPublicProfilePicksAPI.md#getuserpublicprofilepickitemrelationship) | **GET** /userPublicProfilePicks/{id}/relationships/item | Relationship: item (read) +*UserPublicProfilePicksAPI* | [**getUserPublicProfilePickUserPublicProfileRelationship**](docs/UserPublicProfilePicksAPI.md#getuserpublicprofilepickuserpublicprofilerelationship) | **GET** /userPublicProfilePicks/{id}/relationships/userPublicProfile | Relationship: user public profile +*UserPublicProfilePicksAPI* | [**getUserPublicProfilePicksByFilters**](docs/UserPublicProfilePicksAPI.md#getuserpublicprofilepicksbyfilters) | **GET** /userPublicProfilePicks | Get picks +*UserPublicProfilePicksAPI* | [**setUserPublicProfilePickItemRelationship**](docs/UserPublicProfilePicksAPI.md#setuserpublicprofilepickitemrelationship) | **PATCH** /userPublicProfilePicks/{id}/relationships/item | Relationship: item (update) +*UserPublicProfilesAPI* | [**getMyUserPublicProfile**](docs/UserPublicProfilesAPI.md#getmyuserpublicprofile) | **GET** /userPublicProfiles/me | Get my user profile +*UserPublicProfilesAPI* | [**getUserPublicProfileById**](docs/UserPublicProfilesAPI.md#getuserpublicprofilebyid) | **GET** /userPublicProfiles/{id} | Get user public profile by id +*UserPublicProfilesAPI* | [**getUserPublicProfileFollowersRelationship**](docs/UserPublicProfilesAPI.md#getuserpublicprofilefollowersrelationship) | **GET** /userPublicProfiles/{id}/relationships/followers | Relationship: followers +*UserPublicProfilesAPI* | [**getUserPublicProfileFollowingRelationship**](docs/UserPublicProfilesAPI.md#getuserpublicprofilefollowingrelationship) | **GET** /userPublicProfiles/{id}/relationships/following | Relationship: following +*UserPublicProfilesAPI* | [**getUserPublicProfilePublicPicksRelationship**](docs/UserPublicProfilesAPI.md#getuserpublicprofilepublicpicksrelationship) | **GET** /userPublicProfiles/{id}/relationships/publicPicks | Relationship: picks +*UserPublicProfilesAPI* | [**getUserPublicProfilePublicPlaylistsRelationship**](docs/UserPublicProfilesAPI.md#getuserpublicprofilepublicplaylistsrelationship) | **GET** /userPublicProfiles/{id}/relationships/publicPlaylists | Relationship: playlists +*UserPublicProfilesAPI* | [**getUserPublicProfilesByFilters**](docs/UserPublicProfilesAPI.md#getuserpublicprofilesbyfilters) | **GET** /userPublicProfiles | Get user public profiles +*UserRecommendationsAPI* | [**getMyUserRecommendations**](docs/UserRecommendationsAPI.md#getmyuserrecommendations) | **GET** /userRecommendations/me | Get the current users recommendations +*UserRecommendationsAPI* | [**getUserRecommendationsByFilters**](docs/UserRecommendationsAPI.md#getuserrecommendationsbyfilters) | **GET** /userRecommendations | Get recommendations for users in batch +*UserRecommendationsAPI* | [**getUserRecommendationsById**](docs/UserRecommendationsAPI.md#getuserrecommendationsbyid) | **GET** /userRecommendations/{id} | Get user recommendations for user +*UserRecommendationsAPI* | [**getUserRecommendationsDiscoveryMixesRelationship**](docs/UserRecommendationsAPI.md#getuserrecommendationsdiscoverymixesrelationship) | **GET** /userRecommendations/{id}/relationships/discoveryMixes | Relationship: discovery mixes +*UserRecommendationsAPI* | [**getUserRecommendationsMyMixesRelationship**](docs/UserRecommendationsAPI.md#getuserrecommendationsmymixesrelationship) | **GET** /userRecommendations/{id}/relationships/myMixes | Relationship: my mixes +*UserRecommendationsAPI* | [**getUserRecommendationsNewArrivalMixesRelationship**](docs/UserRecommendationsAPI.md#getuserrecommendationsnewarrivalmixesrelationship) | **GET** /userRecommendations/{id}/relationships/newArrivalMixes | Relationship: new arrivals mixes +*UsersAPI* | [**getMyUser**](docs/UsersAPI.md#getmyuser) | **GET** /users/me | Get the current user +*UsersAPI* | [**getUserById**](docs/UsersAPI.md#getuserbyid) | **GET** /users/{id} | Get a single user by id +*UsersAPI* | [**getUserEntitlementsRelationship**](docs/UsersAPI.md#getuserentitlementsrelationship) | **GET** /users/{id}/relationships/entitlements | Relationship: entitlements +*UsersAPI* | [**getUserPublicProfileRelationship**](docs/UsersAPI.md#getuserpublicprofilerelationship) | **GET** /users/{id}/relationships/publicProfile | Relationship: public profile +*UsersAPI* | [**getUserRecommendationsRelationship**](docs/UsersAPI.md#getuserrecommendationsrelationship) | **GET** /users/{id}/relationships/recommendations | Relationship: user recommendations +*UsersAPI* | [**getUsersByFilters**](docs/UsersAPI.md#getusersbyfilters) | **GET** /users | Get multiple users by id + + +## Documentation For Models + + - [AlbumsAttributes](docs/AlbumsAttributes.md) + - [AlbumsItemResourceIdentifier](docs/AlbumsItemResourceIdentifier.md) + - [AlbumsItemResourceIdentifierMeta](docs/AlbumsItemResourceIdentifierMeta.md) + - [AlbumsItemsRelationship](docs/AlbumsItemsRelationship.md) + - [AlbumsRelationships](docs/AlbumsRelationships.md) + - [AlbumsResource](docs/AlbumsResource.md) + - [ArtistsAttributes](docs/ArtistsAttributes.md) + - [ArtistsRelationships](docs/ArtistsRelationships.md) + - [ArtistsResource](docs/ArtistsResource.md) + - [ArtistsTrackProvidersRelationship](docs/ArtistsTrackProvidersRelationship.md) + - [ArtistsTrackProvidersResourceIdentifier](docs/ArtistsTrackProvidersResourceIdentifier.md) + - [ArtistsTrackProvidersResourceIdentifierMeta](docs/ArtistsTrackProvidersResourceIdentifierMeta.md) + - [CatalogueItemExternalLink](docs/CatalogueItemExternalLink.md) + - [CatalogueItemImageLink](docs/CatalogueItemImageLink.md) + - [CatalogueItemVideoLink](docs/CatalogueItemVideoLink.md) + - [ErrorDocument](docs/ErrorDocument.md) + - [ErrorObject](docs/ErrorObject.md) + - [ErrorObjectSource](docs/ErrorObjectSource.md) + - [ExternalLinkMeta](docs/ExternalLinkMeta.md) + - [ImageLinkMeta](docs/ImageLinkMeta.md) + - [Links](docs/Links.md) + - [MultiDataRelationshipDoc](docs/MultiDataRelationshipDoc.md) + - [PlaylistsAttributes](docs/PlaylistsAttributes.md) + - [PlaylistsExternalLink](docs/PlaylistsExternalLink.md) + - [PlaylistsImageLink](docs/PlaylistsImageLink.md) + - [PlaylistsRelationshipDocument](docs/PlaylistsRelationshipDocument.md) + - [PlaylistsRelationships](docs/PlaylistsRelationships.md) + - [PlaylistsResource](docs/PlaylistsResource.md) + - [PromptColors](docs/PromptColors.md) + - [ProvidersAttributes](docs/ProvidersAttributes.md) + - [ProvidersResource](docs/ProvidersResource.md) + - [ResourceIdentifier](docs/ResourceIdentifier.md) + - [SingletonDataRelationshipDoc](docs/SingletonDataRelationshipDoc.md) + - [TracksAttributes](docs/TracksAttributes.md) + - [TracksRelationships](docs/TracksRelationships.md) + - [TracksResource](docs/TracksResource.md) + - [UpdateUserPublicProfilePicksRelationshipDocument](docs/UpdateUserPublicProfilePicksRelationshipDocument.md) + - [UserEntitlementsAttributes](docs/UserEntitlementsAttributes.md) + - [UserEntitlementsRelationshipDocument](docs/UserEntitlementsRelationshipDocument.md) + - [UserEntitlementsRelationshipDocumentIncludedInner](docs/UserEntitlementsRelationshipDocumentIncludedInner.md) + - [UserEntitlementsResource](docs/UserEntitlementsResource.md) + - [UserEntitlementsSingleDataDocument](docs/UserEntitlementsSingleDataDocument.md) + - [UserPublicProfilePicksAttributes](docs/UserPublicProfilePicksAttributes.md) + - [UserPublicProfilePicksItemRelationshipDocument](docs/UserPublicProfilePicksItemRelationshipDocument.md) + - [UserPublicProfilePicksItemRelationshipDocumentIncludedInner](docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md) + - [UserPublicProfilePicksMultiDataDocument](docs/UserPublicProfilePicksMultiDataDocument.md) + - [UserPublicProfilePicksMultiDataDocumentIncludedInner](docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md) + - [UserPublicProfilePicksRelationshipDocument](docs/UserPublicProfilePicksRelationshipDocument.md) + - [UserPublicProfilePicksRelationshipDocumentIncludedInner](docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md) + - [UserPublicProfilePicksRelationships](docs/UserPublicProfilePicksRelationships.md) + - [UserPublicProfilePicksResource](docs/UserPublicProfilePicksResource.md) + - [UserPublicProfilesAttributes](docs/UserPublicProfilesAttributes.md) + - [UserPublicProfilesExternalLink](docs/UserPublicProfilesExternalLink.md) + - [UserPublicProfilesExternalLinkMeta](docs/UserPublicProfilesExternalLinkMeta.md) + - [UserPublicProfilesImageLink](docs/UserPublicProfilesImageLink.md) + - [UserPublicProfilesMultiDataDocument](docs/UserPublicProfilesMultiDataDocument.md) + - [UserPublicProfilesMultiDataDocumentIncludedInner](docs/UserPublicProfilesMultiDataDocumentIncludedInner.md) + - [UserPublicProfilesRelationshipDocument](docs/UserPublicProfilesRelationshipDocument.md) + - [UserPublicProfilesRelationshipDocumentIncludedInner](docs/UserPublicProfilesRelationshipDocumentIncludedInner.md) + - [UserPublicProfilesRelationships](docs/UserPublicProfilesRelationships.md) + - [UserPublicProfilesResource](docs/UserPublicProfilesResource.md) + - [UserPublicProfilesSingleDataDocument](docs/UserPublicProfilesSingleDataDocument.md) + - [UserRecommendationsMultiDataDocument](docs/UserRecommendationsMultiDataDocument.md) + - [UserRecommendationsMultiDataDocumentIncludedInner](docs/UserRecommendationsMultiDataDocumentIncludedInner.md) + - [UserRecommendationsRelationships](docs/UserRecommendationsRelationships.md) + - [UserRecommendationsResource](docs/UserRecommendationsResource.md) + - [UserRecommendationsSingleDataDocument](docs/UserRecommendationsSingleDataDocument.md) + - [UsersAttributes](docs/UsersAttributes.md) + - [UsersMultiDataDocument](docs/UsersMultiDataDocument.md) + - [UsersMultiDataDocumentIncludedInner](docs/UsersMultiDataDocumentIncludedInner.md) + - [UsersRecommendationsRelationshipDocument](docs/UsersRecommendationsRelationshipDocument.md) + - [UsersRecommendationsRelationshipDocumentIncludedInner](docs/UsersRecommendationsRelationshipDocumentIncludedInner.md) + - [UsersRelationshipDocument](docs/UsersRelationshipDocument.md) + - [UsersRelationshipDocumentIncludedInner](docs/UsersRelationshipDocumentIncludedInner.md) + - [UsersRelationships](docs/UsersRelationships.md) + - [UsersResource](docs/UsersResource.md) + - [UsersSingleDataDocument](docs/UsersSingleDataDocument.md) + - [VideoLinkMeta](docs/VideoLinkMeta.md) + - [VideosAttributes](docs/VideosAttributes.md) + - [VideosRelationships](docs/VideosRelationships.md) + - [VideosResource](docs/VideosResource.md) + + + +## Documentation For Authorization + + +Authentication schemes defined for the API: + +### Authorization_Code_PKCE + +- **Type**: OAuth +- **Flow**: accessCode +- **Authorization URL**: https://login.tidal.com/ +- **Scopes**: + - **user.read**: Read access to a user's account information, such as country and email address. + - **entitlements.read**: Read access to a user's entitlements + - **playlists.read**: Read access to a user's playlists + - **recommendations.read**: Read access to a user's recommendations + - **public-profile.read**: Read access to a user's public profile + - **public-profile.write**: Write access to a user's public profile + + +### Client_Credentials + +- **Type**: OAuth +- **Flow**: application +- **Authorization URL**: +- **Scopes**: N/A + + +## Author + + + diff --git a/Sources/API/Generated/docs/AlbumsAPI.md b/Sources/API/Generated/docs/AlbumsAPI.md new file mode 100644 index 00000000..8be02634 --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsAPI.md @@ -0,0 +1,348 @@ +# AlbumsAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getAlbumArtistsRelationship**](AlbumsAPI.md#getalbumartistsrelationship) | **GET** /albums/{id}/relationships/artists | Relationship: artists +[**getAlbumById**](AlbumsAPI.md#getalbumbyid) | **GET** /albums/{id} | Get single album +[**getAlbumItemsRelationship**](AlbumsAPI.md#getalbumitemsrelationship) | **GET** /albums/{id}/relationships/items | Relationship: items +[**getAlbumProvidersRelationship**](AlbumsAPI.md#getalbumprovidersrelationship) | **GET** /albums/{id}/relationships/providers | Relationship: providers +[**getAlbumSimilarAlbumsRelationship**](AlbumsAPI.md#getalbumsimilaralbumsrelationship) | **GET** /albums/{id}/relationships/similarAlbums | Relationship: similar albums +[**getAlbumsByFilters**](AlbumsAPI.md#getalbumsbyfilters) | **GET** /albums | Get multiple albums + + +# **getAlbumArtistsRelationship** +```swift + open class func getAlbumArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ArtistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: artists + +Retrieve artist details of the related album. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL album id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: artists +AlbumsAPI.getAlbumArtistsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL album id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ArtistsRelationshipDocument**](ArtistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getAlbumById** +```swift + open class func getAlbumById(id: String, countryCode: String, include: [String]? = nil, completion: @escaping (_ data: AlbumsSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get single album + +Retrieve album details by TIDAL album id. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL album id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums (optional) + +// Get single album +AlbumsAPI.getAlbumById(id: id, countryCode: countryCode, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL album id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums | [optional] + +### Return type + +[**AlbumsSingleDataDocument**](AlbumsSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getAlbumItemsRelationship** +```swift + open class func getAlbumItemsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: AlbumsItemsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: items + +Retrieve album item details. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL album id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: items (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: items +AlbumsAPI.getAlbumItemsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL album id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: items | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**AlbumsItemsRelationshipDocument**](AlbumsItemsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getAlbumProvidersRelationship** +```swift + open class func getAlbumProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ProvidersRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: providers + +This endpoint can be used to retrieve a list of album's related providers. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the album +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: providers (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: providers +AlbumsAPI.getAlbumProvidersRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the album | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: providers | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ProvidersRelationshipDocument**](ProvidersRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getAlbumSimilarAlbumsRelationship** +```swift + open class func getAlbumSimilarAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: AlbumsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: similar albums + +This endpoint can be used to retrieve a list of albums similar to the given album. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the album +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: similarAlbums (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: similar albums +AlbumsAPI.getAlbumSimilarAlbumsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the album | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: similarAlbums | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**AlbumsRelationshipDocument**](AlbumsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getAlbumsByFilters** +```swift + open class func getAlbumsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterBarcodeId: [String]? = nil, completion: @escaping (_ data: AlbumsMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get multiple albums + +Retrieve multiple album details. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums (optional) +let filterId = ["inner_example"] // [String] | Allows to filter the collection of resources based on id attribute value (optional) +let filterBarcodeId = ["inner_example"] // [String] | Allows to filter the collection of resources based on barcodeId attribute value (optional) + +// Get multiple albums +AlbumsAPI.getAlbumsByFilters(countryCode: countryCode, include: include, filterId: filterId, filterBarcodeId: filterBarcodeId) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists, items, providers, similarAlbums | [optional] + **filterId** | [**[String]**](String.md) | Allows to filter the collection of resources based on id attribute value | [optional] + **filterBarcodeId** | [**[String]**](String.md) | Allows to filter the collection of resources based on barcodeId attribute value | [optional] + +### Return type + +[**AlbumsMultiDataDocument**](AlbumsMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/AlbumsAttributes.md b/Sources/API/Generated/docs/AlbumsAttributes.md new file mode 100644 index 00000000..bc7aa86d --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsAttributes.md @@ -0,0 +1,23 @@ +# AlbumsAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**title** | **String** | Original title | +**barcodeId** | **String** | Barcode id (EAN-13 or UPC-A) | +**numberOfVolumes** | **Int** | Number of volumes | +**numberOfItems** | **Int** | Number of album items | +**duration** | **String** | Duration (ISO-8601) | +**explicit** | **Bool** | Indicates whether an album consist of any explicit content | +**releaseDate** | **Date** | Release date (ISO-8601) | [optional] +**copyright** | **String** | Copyright information | [optional] +**popularity** | **Double** | Album popularity (ranged in 0.00 ... 1.00). Conditionally visible | +**availability** | **[String]** | Defines an album availability e.g. for streaming, DJs, stems | [optional] +**mediaTags** | **[String]** | | +**imageLinks** | [CatalogueItemImageLink] | Represents available links to, and metadata about, an album cover images | [optional] +**videoLinks** | [CatalogueItemVideoLink] | Represents available links to, and metadata about, an album cover videos | [optional] +**externalLinks** | [CatalogueItemExternalLink] | Represents available links to something that is related to an album resource, but external to the TIDAL API | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsItemResourceIdentifier.md b/Sources/API/Generated/docs/AlbumsItemResourceIdentifier.md new file mode 100644 index 00000000..f28303b5 --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsItemResourceIdentifier.md @@ -0,0 +1,12 @@ +# AlbumsItemResourceIdentifier + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | +**meta** | [**AlbumsItemResourceIdentifierMeta**](AlbumsItemResourceIdentifierMeta.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsItemResourceIdentifierMeta.md b/Sources/API/Generated/docs/AlbumsItemResourceIdentifierMeta.md new file mode 100644 index 00000000..ba4091d7 --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsItemResourceIdentifierMeta.md @@ -0,0 +1,11 @@ +# AlbumsItemResourceIdentifierMeta + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**volumeNumber** | **Int** | volume number | +**trackNumber** | **Int** | track number | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsItemsRelationship.md b/Sources/API/Generated/docs/AlbumsItemsRelationship.md new file mode 100644 index 00000000..8bf871fb --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsItemsRelationship.md @@ -0,0 +1,11 @@ +# AlbumsItemsRelationship + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [[AlbumsItemResourceIdentifier]] | | [optional] +**links** | [**Links**](Links.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsItemsRelationshipDocument.md b/Sources/API/Generated/docs/AlbumsItemsRelationshipDocument.md new file mode 100644 index 00000000..2a90ee97 --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsItemsRelationshipDocument.md @@ -0,0 +1,12 @@ +# AlbumsItemsRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [[AlbumsItemResourceIdentifier]] | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [AlbumsItemsRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..4aa4737a --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# AlbumsItemsRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsMultiDataDocument.md b/Sources/API/Generated/docs/AlbumsMultiDataDocument.md new file mode 100644 index 00000000..825d2b28 --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsMultiDataDocument.md @@ -0,0 +1,12 @@ +# AlbumsMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [AlbumsResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [AlbumsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..462ed674 --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# AlbumsMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsRelationshipDocument.md b/Sources/API/Generated/docs/AlbumsRelationshipDocument.md new file mode 100644 index 00000000..0943e7ca --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsRelationshipDocument.md @@ -0,0 +1,12 @@ +# AlbumsRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [AlbumsRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..b7384e17 --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# AlbumsRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**VideosAttributes**](VideosAttributes.md) | | [optional] +**relationships** | [**VideosRelationships**](VideosRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsRelationships.md b/Sources/API/Generated/docs/AlbumsRelationships.md new file mode 100644 index 00000000..a49939dc --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsRelationships.md @@ -0,0 +1,13 @@ +# AlbumsRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**artists** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**items** | [**AlbumsItemsRelationship**](AlbumsItemsRelationship.md) | | +**similarAlbums** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**providers** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsResource.md b/Sources/API/Generated/docs/AlbumsResource.md new file mode 100644 index 00000000..0b5d0e3f --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsResource.md @@ -0,0 +1,14 @@ +# AlbumsResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**AlbumsAttributes**](AlbumsAttributes.md) | | [optional] +**relationships** | [**AlbumsRelationships**](AlbumsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/AlbumsSingleDataDocument.md b/Sources/API/Generated/docs/AlbumsSingleDataDocument.md new file mode 100644 index 00000000..f8dd5377 --- /dev/null +++ b/Sources/API/Generated/docs/AlbumsSingleDataDocument.md @@ -0,0 +1,12 @@ +# AlbumsSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**AlbumsResource**](AlbumsResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [AlbumsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsAPI.md b/Sources/API/Generated/docs/ArtistsAPI.md new file mode 100644 index 00000000..593e7375 --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsAPI.md @@ -0,0 +1,460 @@ +# ArtistsAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getArtistAlbumsRelationship**](ArtistsAPI.md#getartistalbumsrelationship) | **GET** /artists/{id}/relationships/albums | Relationship: albums +[**getArtistById**](ArtistsAPI.md#getartistbyid) | **GET** /artists/{id} | Get single artist +[**getArtistRadioRelationship**](ArtistsAPI.md#getartistradiorelationship) | **GET** /artists/{id}/relationships/radio | Relationship: radio +[**getArtistSimilarArtistsRelationship**](ArtistsAPI.md#getartistsimilarartistsrelationship) | **GET** /artists/{id}/relationships/similarArtists | Relationship: similar artists +[**getArtistTrackProvidersRelationship**](ArtistsAPI.md#getartisttrackprovidersrelationship) | **GET** /artists/{id}/relationships/trackProviders | Relationship: track providers +[**getArtistTracksRelationship**](ArtistsAPI.md#getartisttracksrelationship) | **GET** /artists/{id}/relationships/tracks | Relationship: tracks +[**getArtistVideosRelationship**](ArtistsAPI.md#getartistvideosrelationship) | **GET** /artists/{id}/relationships/videos | Relationship: videos +[**getArtistsByFilters**](ArtistsAPI.md#getartistsbyfilters) | **GET** /artists | Get multiple artists + + +# **getArtistAlbumsRelationship** +```swift + open class func getArtistAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: AlbumsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: albums + +Retrieve album details of the related artist. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL artist id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: albums (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: albums +ArtistsAPI.getArtistAlbumsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL artist id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: albums | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**AlbumsRelationshipDocument**](AlbumsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getArtistById** +```swift + open class func getArtistById(id: String, countryCode: String, include: [String]? = nil, completion: @escaping (_ data: ArtistsSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get single artist + +Retrieve artist details by TIDAL artist id. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL artist id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio (optional) + +// Get single artist +ArtistsAPI.getArtistById(id: id, countryCode: countryCode, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL artist id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio | [optional] + +### Return type + +[**ArtistsSingleDataDocument**](ArtistsSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getArtistRadioRelationship** +```swift + open class func getArtistRadioRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ArtistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: radio + +This endpoint can be used to retrieve a list of radios for the given artist. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the artist +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: radio (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: radio +ArtistsAPI.getArtistRadioRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the artist | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: radio | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ArtistsRelationshipDocument**](ArtistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getArtistSimilarArtistsRelationship** +```swift + open class func getArtistSimilarArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ArtistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: similar artists + +This endpoint can be used to retrieve a list of artists similar to the given artist. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the artist +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: similarArtists (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: similar artists +ArtistsAPI.getArtistSimilarArtistsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the artist | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: similarArtists | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ArtistsRelationshipDocument**](ArtistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getArtistTrackProvidersRelationship** +```swift + open class func getArtistTrackProvidersRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ArtistsTrackProvidersRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: track providers + +Retrieve providers that have released tracks for this artist + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the artist +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: trackProviders (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: track providers +ArtistsAPI.getArtistTrackProvidersRelationship(id: id, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the artist | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: trackProviders | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ArtistsTrackProvidersRelationshipDocument**](ArtistsTrackProvidersRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getArtistTracksRelationship** +```swift + open class func getArtistTracksRelationship(id: String, countryCode: String, collapseBy: CollapseBy_getArtistTracksRelationship? = nil, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: TracksRelationshipsDocument?, _ error: Error?) -> Void) +``` + +Relationship: tracks + +Retrieve track details by related artist. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL artist id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let collapseBy = "collapseBy_example" // String | Collapse by options for getting artist tracks. Available options: FINGERPRINT, ID. FINGERPRINT option might collapse similar tracks based item fingerprints while collapsing by ID always returns all available items. (optional) (default to .fingerprint) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: tracks (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: tracks +ArtistsAPI.getArtistTracksRelationship(id: id, countryCode: countryCode, collapseBy: collapseBy, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL artist id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **collapseBy** | **String** | Collapse by options for getting artist tracks. Available options: FINGERPRINT, ID. FINGERPRINT option might collapse similar tracks based item fingerprints while collapsing by ID always returns all available items. | [optional] [default to .fingerprint] + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: tracks | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**TracksRelationshipsDocument**](TracksRelationshipsDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getArtistVideosRelationship** +```swift + open class func getArtistVideosRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: VideosRelationshipsDocument?, _ error: Error?) -> Void) +``` + +Relationship: videos + +Retrieve video details by related artist. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL artist id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: videos (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: videos +ArtistsAPI.getArtistVideosRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL artist id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: videos | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**VideosRelationshipsDocument**](VideosRelationshipsDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getArtistsByFilters** +```swift + open class func getArtistsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, completion: @escaping (_ data: ArtistsMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get multiple artists + +Retrieve multiple artist details. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio (optional) +let filterId = ["inner_example"] // [String] | Allows to filter the collection of resources based on id attribute value (optional) + +// Get multiple artists +ArtistsAPI.getArtistsByFilters(countryCode: countryCode, include: include, filterId: filterId) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: albums, tracks, videos, similarArtists, trackProviders, radio | [optional] + **filterId** | [**[String]**](String.md) | Allows to filter the collection of resources based on id attribute value | [optional] + +### Return type + +[**ArtistsMultiDataDocument**](ArtistsMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/ArtistsAttributes.md b/Sources/API/Generated/docs/ArtistsAttributes.md new file mode 100644 index 00000000..8b609695 --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsAttributes.md @@ -0,0 +1,13 @@ +# ArtistsAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | Artist name | +**popularity** | **Double** | Artist popularity (ranged in 0.00 ... 1.00). Conditionally visible | +**imageLinks** | [CatalogueItemImageLink] | Represents available links to, and metadata about, an artist images | [optional] +**externalLinks** | [CatalogueItemExternalLink] | Represents available links to something that is related to an artist resource, but external to the TIDAL API | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsMultiDataDocument.md b/Sources/API/Generated/docs/ArtistsMultiDataDocument.md new file mode 100644 index 00000000..9bdb496f --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsMultiDataDocument.md @@ -0,0 +1,12 @@ +# ArtistsMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ArtistsResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [ArtistsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..48c9874f --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# ArtistsMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsRelationshipDocument.md b/Sources/API/Generated/docs/ArtistsRelationshipDocument.md new file mode 100644 index 00000000..7004b625 --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsRelationshipDocument.md @@ -0,0 +1,12 @@ +# ArtistsRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [ArtistsRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..711a62ef --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# ArtistsRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsRelationships.md b/Sources/API/Generated/docs/ArtistsRelationships.md new file mode 100644 index 00000000..25fb1d05 --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsRelationships.md @@ -0,0 +1,15 @@ +# ArtistsRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**albums** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**tracks** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**videos** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**similarArtists** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**trackProviders** | [**ArtistsTrackProvidersRelationship**](ArtistsTrackProvidersRelationship.md) | | +**radio** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsResource.md b/Sources/API/Generated/docs/ArtistsResource.md new file mode 100644 index 00000000..250cf95f --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsResource.md @@ -0,0 +1,14 @@ +# ArtistsResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**ArtistsAttributes**](ArtistsAttributes.md) | | [optional] +**relationships** | [**ArtistsRelationships**](ArtistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsSingleDataDocument.md b/Sources/API/Generated/docs/ArtistsSingleDataDocument.md new file mode 100644 index 00000000..960a0cbd --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsSingleDataDocument.md @@ -0,0 +1,12 @@ +# ArtistsSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**ArtistsResource**](ArtistsResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [ArtistsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsTrackProvidersRelationship.md b/Sources/API/Generated/docs/ArtistsTrackProvidersRelationship.md new file mode 100644 index 00000000..3c14d790 --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsTrackProvidersRelationship.md @@ -0,0 +1,11 @@ +# ArtistsTrackProvidersRelationship + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [[ArtistsTrackProvidersResourceIdentifier]] | | [optional] +**links** | [**Links**](Links.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md b/Sources/API/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md new file mode 100644 index 00000000..501a60a1 --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md @@ -0,0 +1,12 @@ +# ArtistsTrackProvidersRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [[ArtistsTrackProvidersResourceIdentifier]] | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [ProvidersRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md b/Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md new file mode 100644 index 00000000..43666bc4 --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md @@ -0,0 +1,12 @@ +# ArtistsTrackProvidersResourceIdentifier + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | +**meta** | [**ArtistsTrackProvidersResourceIdentifierMeta**](ArtistsTrackProvidersResourceIdentifierMeta.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md b/Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md new file mode 100644 index 00000000..1c817067 --- /dev/null +++ b/Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md @@ -0,0 +1,10 @@ +# ArtistsTrackProvidersResourceIdentifierMeta + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**numberOfTracks** | **Int64** | total number of tracks released together with the provider | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/CatalogueItemExternalLink.md b/Sources/API/Generated/docs/CatalogueItemExternalLink.md new file mode 100644 index 00000000..25de9b58 --- /dev/null +++ b/Sources/API/Generated/docs/CatalogueItemExternalLink.md @@ -0,0 +1,11 @@ +# CatalogueItemExternalLink + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**href** | **String** | link to something that is related to a resource | +**meta** | [**ExternalLinkMeta**](ExternalLinkMeta.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/CatalogueItemImageLink.md b/Sources/API/Generated/docs/CatalogueItemImageLink.md new file mode 100644 index 00000000..da70d539 --- /dev/null +++ b/Sources/API/Generated/docs/CatalogueItemImageLink.md @@ -0,0 +1,11 @@ +# CatalogueItemImageLink + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**href** | **String** | link to an image | +**meta** | [**ImageLinkMeta**](ImageLinkMeta.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/CatalogueItemVideoLink.md b/Sources/API/Generated/docs/CatalogueItemVideoLink.md new file mode 100644 index 00000000..5c181a79 --- /dev/null +++ b/Sources/API/Generated/docs/CatalogueItemVideoLink.md @@ -0,0 +1,11 @@ +# CatalogueItemVideoLink + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**href** | **String** | link to a video | +**meta** | [**VideoLinkMeta**](VideoLinkMeta.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ErrorDocument.md b/Sources/API/Generated/docs/ErrorDocument.md new file mode 100644 index 00000000..aff9b104 --- /dev/null +++ b/Sources/API/Generated/docs/ErrorDocument.md @@ -0,0 +1,11 @@ +# ErrorDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**errors** | [ErrorObject] | array of error objects | [optional] +**links** | [**Links**](Links.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ErrorObject.md b/Sources/API/Generated/docs/ErrorObject.md new file mode 100644 index 00000000..203fe9b9 --- /dev/null +++ b/Sources/API/Generated/docs/ErrorObject.md @@ -0,0 +1,14 @@ +# ErrorObject + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | unique identifier for this particular occurrence of the problem | [optional] +**status** | **String** | HTTP status code applicable to this problem | [optional] +**code** | **String** | application-specific error code | [optional] +**detail** | **String** | human-readable explanation specific to this occurrence of the problem | [optional] +**source** | [**ErrorObjectSource**](ErrorObjectSource.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ErrorObjectSource.md b/Sources/API/Generated/docs/ErrorObjectSource.md new file mode 100644 index 00000000..40ac5728 --- /dev/null +++ b/Sources/API/Generated/docs/ErrorObjectSource.md @@ -0,0 +1,12 @@ +# ErrorObjectSource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**pointer** | **String** | a JSON Pointer [RFC6901] to the value in the request document that caused the error | [optional] +**parameter** | **String** | string indicating which URI query parameter caused the error. | [optional] +**header** | **String** | string indicating the name of a single request header which caused the error | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ExternalLinkMeta.md b/Sources/API/Generated/docs/ExternalLinkMeta.md new file mode 100644 index 00000000..a3133eb5 --- /dev/null +++ b/Sources/API/Generated/docs/ExternalLinkMeta.md @@ -0,0 +1,10 @@ +# ExternalLinkMeta + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **String** | external link type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ImageLinkMeta.md b/Sources/API/Generated/docs/ImageLinkMeta.md new file mode 100644 index 00000000..0f2b5616 --- /dev/null +++ b/Sources/API/Generated/docs/ImageLinkMeta.md @@ -0,0 +1,11 @@ +# ImageLinkMeta + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**width** | **Int** | image width (in pixels) | +**height** | **Int** | image height (in pixels) | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/Links.md b/Sources/API/Generated/docs/Links.md new file mode 100644 index 00000000..e3c3303c --- /dev/null +++ b/Sources/API/Generated/docs/Links.md @@ -0,0 +1,11 @@ +# Links + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**_self** | **String** | the link that generated the current response document | +**next** | **String** | the next page of data (pagination) | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/MultiDataRelationshipDoc.md b/Sources/API/Generated/docs/MultiDataRelationshipDoc.md new file mode 100644 index 00000000..9bdc8678 --- /dev/null +++ b/Sources/API/Generated/docs/MultiDataRelationshipDoc.md @@ -0,0 +1,11 @@ +# MultiDataRelationshipDoc + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsAPI.md b/Sources/API/Generated/docs/PlaylistsAPI.md new file mode 100644 index 00000000..57dca17c --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsAPI.md @@ -0,0 +1,283 @@ +# PlaylistsAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getMyPlaylists**](PlaylistsAPI.md#getmyplaylists) | **GET** /playlists/me | Get current user's playlists +[**getPlaylistById**](PlaylistsAPI.md#getplaylistbyid) | **GET** /playlists/{id} | Get single playlist +[**getPlaylistItemsRelationship**](PlaylistsAPI.md#getplaylistitemsrelationship) | **GET** /playlists/{id}/relationships/items | Relationship: items +[**getPlaylistOwnersRelationship**](PlaylistsAPI.md#getplaylistownersrelationship) | **GET** /playlists/{id}/relationships/owners | Relationship: owner +[**getPlaylistsByFilters**](PlaylistsAPI.md#getplaylistsbyfilters) | **GET** /playlists | Get multiple playlists + + +# **getMyPlaylists** +```swift + open class func getMyPlaylists(include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: PlaylistsMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get current user's playlists + +Get my playlists + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: items, owners (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Get current user's playlists +PlaylistsAPI.getMyPlaylists(include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: items, owners | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**PlaylistsMultiDataDocument**](PlaylistsMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getPlaylistById** +```swift + open class func getPlaylistById(countryCode: String, id: String, include: [String]? = nil, completion: @escaping (_ data: PlaylistsSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get single playlist + +Get playlist by id + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let countryCode = "countryCode_example" // String | Country code (ISO 3166-1 alpha-2) +let id = "id_example" // String | TIDAL playlist id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: items, owners (optional) + +// Get single playlist +PlaylistsAPI.getPlaylistById(countryCode: countryCode, id: id, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **countryCode** | **String** | Country code (ISO 3166-1 alpha-2) | + **id** | **String** | TIDAL playlist id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: items, owners | [optional] + +### Return type + +[**PlaylistsSingleDataDocument**](PlaylistsSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getPlaylistItemsRelationship** +```swift + open class func getPlaylistItemsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: PlaylistsItemsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: items + +Get playlist items + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL playlist id +let countryCode = "countryCode_example" // String | Country code (ISO 3166-1 alpha-2) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: items (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: items +PlaylistsAPI.getPlaylistItemsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL playlist id | + **countryCode** | **String** | Country code (ISO 3166-1 alpha-2) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: items | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**PlaylistsItemsRelationshipDocument**](PlaylistsItemsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getPlaylistOwnersRelationship** +```swift + open class func getPlaylistOwnersRelationship(id: String, countryCode: String, include: [String]? = nil, completion: @escaping (_ data: PlaylistsOwnersRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: owner + +Get playlist owner + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL playlist id +let countryCode = "countryCode_example" // String | Country code (ISO 3166-1 alpha-2) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: owners (optional) + +// Relationship: owner +PlaylistsAPI.getPlaylistOwnersRelationship(id: id, countryCode: countryCode, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL playlist id | + **countryCode** | **String** | Country code (ISO 3166-1 alpha-2) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: owners | [optional] + +### Return type + +[**PlaylistsOwnersRelationshipDocument**](PlaylistsOwnersRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getPlaylistsByFilters** +```swift + open class func getPlaylistsByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, completion: @escaping (_ data: PlaylistsMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get multiple playlists + +Get user playlists + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let countryCode = "countryCode_example" // String | Country code (ISO 3166-1 alpha-2) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: items, owners (optional) +let filterId = ["inner_example"] // [String] | public.usercontent.getPlaylists.ids.descr (optional) + +// Get multiple playlists +PlaylistsAPI.getPlaylistsByFilters(countryCode: countryCode, include: include, filterId: filterId) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **countryCode** | **String** | Country code (ISO 3166-1 alpha-2) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: items, owners | [optional] + **filterId** | [**[String]**](String.md) | public.usercontent.getPlaylists.ids.descr | [optional] + +### Return type + +[**PlaylistsMultiDataDocument**](PlaylistsMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json, */* + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/PlaylistsAttributes.md b/Sources/API/Generated/docs/PlaylistsAttributes.md new file mode 100644 index 00000000..e086ad70 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsAttributes.md @@ -0,0 +1,20 @@ +# PlaylistsAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | Playlist name | +**description** | **String** | Playlist description | [optional] +**bounded** | **Bool** | Indicates if the playlist has a duration and set number of tracks | +**duration** | **String** | Duration of the playlist expressed in accordance with ISO 8601 | [optional] +**numberOfItems** | **Int** | Number of items in the playlist | [optional] +**externalLinks** | [PlaylistsExternalLink] | Sharing links to the playlist | +**createdAt** | **Date** | Datetime of playlist creation (ISO 8601) | +**lastModifiedAt** | **Date** | Datetime of last modification of the playlist (ISO 8601) | +**privacy** | **String** | Privacy setting of the playlist | +**playlistType** | **String** | The type of the playlist | +**imageLinks** | [PlaylistsImageLink] | Images associated with the playlist | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsExternalLink.md b/Sources/API/Generated/docs/PlaylistsExternalLink.md new file mode 100644 index 00000000..af74e06b --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsExternalLink.md @@ -0,0 +1,11 @@ +# PlaylistsExternalLink + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**href** | **String** | link to something that is related to a resource | +**meta** | [**ExternalLinkMeta**](ExternalLinkMeta.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsImageLink.md b/Sources/API/Generated/docs/PlaylistsImageLink.md new file mode 100644 index 00000000..bf6d44b3 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsImageLink.md @@ -0,0 +1,11 @@ +# PlaylistsImageLink + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**href** | **String** | link to an image | +**meta** | [**ImageLinkMeta**](ImageLinkMeta.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsItemsRelationshipDocument.md b/Sources/API/Generated/docs/PlaylistsItemsRelationshipDocument.md new file mode 100644 index 00000000..c09980f4 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsItemsRelationshipDocument.md @@ -0,0 +1,12 @@ +# PlaylistsItemsRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [PlaylistsItemsRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..c2920d80 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# PlaylistsItemsRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsMultiDataDocument.md b/Sources/API/Generated/docs/PlaylistsMultiDataDocument.md new file mode 100644 index 00000000..c7e01882 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsMultiDataDocument.md @@ -0,0 +1,12 @@ +# PlaylistsMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [PlaylistsResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [PlaylistsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..436658fb --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# PlaylistsMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UserEntitlementsAttributes**](UserEntitlementsAttributes.md) | | [optional] +**relationships** | **AnyCodable** | relationships object describing relationships between the resource and other resources | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocument.md b/Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocument.md new file mode 100644 index 00000000..fcd66049 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocument.md @@ -0,0 +1,12 @@ +# PlaylistsOwnersRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [PlaylistsOwnersRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..4aca6bb0 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# PlaylistsOwnersRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**ProvidersAttributes**](ProvidersAttributes.md) | | [optional] +**relationships** | **AnyCodable** | relationships object describing relationships between the resource and other resources | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsRelationshipDocument.md b/Sources/API/Generated/docs/PlaylistsRelationshipDocument.md new file mode 100644 index 00000000..4f30f32f --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsRelationshipDocument.md @@ -0,0 +1,12 @@ +# PlaylistsRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserRecommendationsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..7e77ed91 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# PlaylistsRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsRelationships.md b/Sources/API/Generated/docs/PlaylistsRelationships.md new file mode 100644 index 00000000..d42f2351 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsRelationships.md @@ -0,0 +1,11 @@ +# PlaylistsRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**items** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**owners** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsResource.md b/Sources/API/Generated/docs/PlaylistsResource.md new file mode 100644 index 00000000..940db92c --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsResource.md @@ -0,0 +1,14 @@ +# PlaylistsResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PlaylistsSingleDataDocument.md b/Sources/API/Generated/docs/PlaylistsSingleDataDocument.md new file mode 100644 index 00000000..1001ab15 --- /dev/null +++ b/Sources/API/Generated/docs/PlaylistsSingleDataDocument.md @@ -0,0 +1,12 @@ +# PlaylistsSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**PlaylistsResource**](PlaylistsResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [PlaylistsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/PromptColors.md b/Sources/API/Generated/docs/PromptColors.md new file mode 100644 index 00000000..cc0bc9da --- /dev/null +++ b/Sources/API/Generated/docs/PromptColors.md @@ -0,0 +1,11 @@ +# PromptColors + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**primary** | **String** | Primary color to visually render the pick | +**secondary** | **String** | Secondary color to visually render the pick | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ProvidersAPI.md b/Sources/API/Generated/docs/ProvidersAPI.md new file mode 100644 index 00000000..9d8502e2 --- /dev/null +++ b/Sources/API/Generated/docs/ProvidersAPI.md @@ -0,0 +1,114 @@ +# ProvidersAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getProviderById**](ProvidersAPI.md#getproviderbyid) | **GET** /providers/{id} | Get single provider +[**getProvidersByFilters**](ProvidersAPI.md#getprovidersbyfilters) | **GET** /providers | Get multiple providers + + +# **getProviderById** +```swift + open class func getProviderById(id: String, include: [String]? = nil, completion: @escaping (_ data: ProvidersSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get single provider + +Retrieve provider details by TIDAL provider id. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL provider id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned (optional) + +// Get single provider +ProvidersAPI.getProviderById(id: id, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL provider id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned | [optional] + +### Return type + +[**ProvidersSingleDataDocument**](ProvidersSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getProvidersByFilters** +```swift + open class func getProvidersByFilters(include: [String]? = nil, filterId: [String]? = nil, completion: @escaping (_ data: ProvidersMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get multiple providers + +Retrieve multiple provider details. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned (optional) +let filterId = ["inner_example"] // [String] | provider id (optional) + +// Get multiple providers +ProvidersAPI.getProvidersByFilters(include: include, filterId: filterId) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned | [optional] + **filterId** | [**[String]**](String.md) | provider id | [optional] + +### Return type + +[**ProvidersMultiDataDocument**](ProvidersMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/ProvidersAttributes.md b/Sources/API/Generated/docs/ProvidersAttributes.md new file mode 100644 index 00000000..ac5b27e2 --- /dev/null +++ b/Sources/API/Generated/docs/ProvidersAttributes.md @@ -0,0 +1,10 @@ +# ProvidersAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**name** | **String** | Provider name. Conditionally visible. | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ProvidersMultiDataDocument.md b/Sources/API/Generated/docs/ProvidersMultiDataDocument.md new file mode 100644 index 00000000..b417daed --- /dev/null +++ b/Sources/API/Generated/docs/ProvidersMultiDataDocument.md @@ -0,0 +1,11 @@ +# ProvidersMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ProvidersResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ProvidersRelationshipDocument.md b/Sources/API/Generated/docs/ProvidersRelationshipDocument.md new file mode 100644 index 00000000..31a6de6b --- /dev/null +++ b/Sources/API/Generated/docs/ProvidersRelationshipDocument.md @@ -0,0 +1,12 @@ +# ProvidersRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [ProvidersRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..2b4e9f20 --- /dev/null +++ b/Sources/API/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# ProvidersRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**ProvidersAttributes**](ProvidersAttributes.md) | | [optional] +**relationships** | **AnyCodable** | relationships object describing relationships between the resource and other resources | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ProvidersResource.md b/Sources/API/Generated/docs/ProvidersResource.md new file mode 100644 index 00000000..00c75784 --- /dev/null +++ b/Sources/API/Generated/docs/ProvidersResource.md @@ -0,0 +1,14 @@ +# ProvidersResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**ProvidersAttributes**](ProvidersAttributes.md) | | [optional] +**relationships** | **AnyCodable** | relationships object describing relationships between the resource and other resources | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ProvidersSingleDataDocument.md b/Sources/API/Generated/docs/ProvidersSingleDataDocument.md new file mode 100644 index 00000000..96c5aa30 --- /dev/null +++ b/Sources/API/Generated/docs/ProvidersSingleDataDocument.md @@ -0,0 +1,11 @@ +# ProvidersSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**ProvidersResource**](ProvidersResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/ResourceIdentifier.md b/Sources/API/Generated/docs/ResourceIdentifier.md new file mode 100644 index 00000000..b65a67bf --- /dev/null +++ b/Sources/API/Generated/docs/ResourceIdentifier.md @@ -0,0 +1,11 @@ +# ResourceIdentifier + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/SearchResultsAPI.md b/Sources/API/Generated/docs/SearchResultsAPI.md new file mode 100644 index 00000000..f29525ff --- /dev/null +++ b/Sources/API/Generated/docs/SearchResultsAPI.md @@ -0,0 +1,405 @@ +# SearchResultsAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getSearchResultsAlbumsRelationship**](SearchResultsAPI.md#getsearchresultsalbumsrelationship) | **GET** /searchresults/{query}/relationships/albums | Relationship: albums +[**getSearchResultsArtistsRelationship**](SearchResultsAPI.md#getsearchresultsartistsrelationship) | **GET** /searchresults/{query}/relationships/artists | Relationship: artists +[**getSearchResultsByQuery**](SearchResultsAPI.md#getsearchresultsbyquery) | **GET** /searchresults/{query} | Search for music metadata by a query +[**getSearchResultsPlaylistsRelationship**](SearchResultsAPI.md#getsearchresultsplaylistsrelationship) | **GET** /searchresults/{query}/relationships/playlists | Relationship: playlists +[**getSearchResultsTopHitsRelationship**](SearchResultsAPI.md#getsearchresultstophitsrelationship) | **GET** /searchresults/{query}/relationships/topHits | Relationship: topHits +[**getSearchResultsTracksRelationship**](SearchResultsAPI.md#getsearchresultstracksrelationship) | **GET** /searchresults/{query}/relationships/tracks | Relationship: tracks +[**getSearchResultsVideosRelationship**](SearchResultsAPI.md#getsearchresultsvideosrelationship) | **GET** /searchresults/{query}/relationships/videos | Relationship: videos + + +# **getSearchResultsAlbumsRelationship** +```swift + open class func getSearchResultsAlbumsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: AlbumsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: albums + +Search for albums by a query. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let query = "query_example" // String | Search query +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: albums (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: albums +SearchResultsAPI.getSearchResultsAlbumsRelationship(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **query** | **String** | Search query | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: albums | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**AlbumsRelationshipDocument**](AlbumsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getSearchResultsArtistsRelationship** +```swift + open class func getSearchResultsArtistsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ArtistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: artists + +Search for artists by a query. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let query = "query_example" // String | Search query +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: artists +SearchResultsAPI.getSearchResultsArtistsRelationship(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **query** | **String** | Search query | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ArtistsRelationshipDocument**](ArtistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getSearchResultsByQuery** +```swift + open class func getSearchResultsByQuery(query: String, countryCode: String, include: [String]? = nil, completion: @escaping (_ data: SearchResultsSingleDataDocument?, _ error: Error?) -> Void) +``` + +Search for music metadata by a query + +Search for music: albums, artists, tracks, etc. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let query = "query_example" // String | Search query +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists, albums, tracks, videos, playlists, topHits (optional) + +// Search for music metadata by a query +SearchResultsAPI.getSearchResultsByQuery(query: query, countryCode: countryCode, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **query** | **String** | Search query | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists, albums, tracks, videos, playlists, topHits | [optional] + +### Return type + +[**SearchResultsSingleDataDocument**](SearchResultsSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getSearchResultsPlaylistsRelationship** +```swift + open class func getSearchResultsPlaylistsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: PlaylistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: playlists + +Search for playlists by a query. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let query = "query_example" // String | Searh query +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: playlists (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: playlists +SearchResultsAPI.getSearchResultsPlaylistsRelationship(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **query** | **String** | Searh query | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: playlists | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**PlaylistsRelationshipDocument**](PlaylistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getSearchResultsTopHitsRelationship** +```swift + open class func getSearchResultsTopHitsRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: SearchResultsTopHitsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: topHits + +Search for top hits by a query: artists, albums, tracks, videos. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let query = "query_example" // String | Search query +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: topHits (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: topHits +SearchResultsAPI.getSearchResultsTopHitsRelationship(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **query** | **String** | Search query | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: topHits | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**SearchResultsTopHitsRelationshipDocument**](SearchResultsTopHitsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getSearchResultsTracksRelationship** +```swift + open class func getSearchResultsTracksRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: TracksRelationshipsDocument?, _ error: Error?) -> Void) +``` + +Relationship: tracks + +Search for tracks by a query. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let query = "query_example" // String | Search query +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: tracks (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: tracks +SearchResultsAPI.getSearchResultsTracksRelationship(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **query** | **String** | Search query | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: tracks | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**TracksRelationshipsDocument**](TracksRelationshipsDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getSearchResultsVideosRelationship** +```swift + open class func getSearchResultsVideosRelationship(query: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: VideosRelationshipsDocument?, _ error: Error?) -> Void) +``` + +Relationship: videos + +Search for videos by a query. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let query = "query_example" // String | Search query +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: videos (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: videos +SearchResultsAPI.getSearchResultsVideosRelationship(query: query, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **query** | **String** | Search query | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: videos | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**VideosRelationshipsDocument**](VideosRelationshipsDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/SearchResultsAttributes.md b/Sources/API/Generated/docs/SearchResultsAttributes.md new file mode 100644 index 00000000..618bd833 --- /dev/null +++ b/Sources/API/Generated/docs/SearchResultsAttributes.md @@ -0,0 +1,11 @@ +# SearchResultsAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**trackingId** | **String** | search request unique tracking number | +**didYouMean** | **String** | 'did you mean' prompt | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/SearchResultsRelationships.md b/Sources/API/Generated/docs/SearchResultsRelationships.md new file mode 100644 index 00000000..131e4aba --- /dev/null +++ b/Sources/API/Generated/docs/SearchResultsRelationships.md @@ -0,0 +1,15 @@ +# SearchResultsRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**albums** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**artists** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**tracks** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**videos** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**playlists** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**topHits** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/SearchResultsResource.md b/Sources/API/Generated/docs/SearchResultsResource.md new file mode 100644 index 00000000..0f315039 --- /dev/null +++ b/Sources/API/Generated/docs/SearchResultsResource.md @@ -0,0 +1,14 @@ +# SearchResultsResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**SearchResultsAttributes**](SearchResultsAttributes.md) | | [optional] +**relationships** | [**SearchResultsRelationships**](SearchResultsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/SearchResultsSingleDataDocument.md b/Sources/API/Generated/docs/SearchResultsSingleDataDocument.md new file mode 100644 index 00000000..4fdee362 --- /dev/null +++ b/Sources/API/Generated/docs/SearchResultsSingleDataDocument.md @@ -0,0 +1,12 @@ +# SearchResultsSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**SearchResultsResource**](SearchResultsResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [SearchResultsSingleDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md b/Sources/API/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md new file mode 100644 index 00000000..03903968 --- /dev/null +++ b/Sources/API/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# SearchResultsSingleDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocument.md b/Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocument.md new file mode 100644 index 00000000..139f8ff1 --- /dev/null +++ b/Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocument.md @@ -0,0 +1,12 @@ +# SearchResultsTopHitsRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [SearchResultsTopHitsRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..7f462570 --- /dev/null +++ b/Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# SearchResultsTopHitsRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/SingletonDataRelationshipDoc.md b/Sources/API/Generated/docs/SingletonDataRelationshipDoc.md new file mode 100644 index 00000000..8ebbeeb3 --- /dev/null +++ b/Sources/API/Generated/docs/SingletonDataRelationshipDoc.md @@ -0,0 +1,11 @@ +# SingletonDataRelationshipDoc + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**ResourceIdentifier**](ResourceIdentifier.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/TracksAPI.md b/Sources/API/Generated/docs/TracksAPI.md new file mode 100644 index 00000000..8b953f2f --- /dev/null +++ b/Sources/API/Generated/docs/TracksAPI.md @@ -0,0 +1,405 @@ +# TracksAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getTrackAlbumsRelationship**](TracksAPI.md#gettrackalbumsrelationship) | **GET** /tracks/{id}/relationships/albums | Relationship: albums +[**getTrackArtistsRelationship**](TracksAPI.md#gettrackartistsrelationship) | **GET** /tracks/{id}/relationships/artists | Relationship: artists +[**getTrackById**](TracksAPI.md#gettrackbyid) | **GET** /tracks/{id} | Get single track +[**getTrackProvidersRelationship**](TracksAPI.md#gettrackprovidersrelationship) | **GET** /tracks/{id}/relationships/providers | Relationship: providers +[**getTrackRadioRelationship**](TracksAPI.md#gettrackradiorelationship) | **GET** /tracks/{id}/relationships/radio | Relationship: radio +[**getTrackSimilarTracksRelationship**](TracksAPI.md#gettracksimilartracksrelationship) | **GET** /tracks/{id}/relationships/similarTracks | Relationship: similar tracks +[**getTracksByFilters**](TracksAPI.md#gettracksbyfilters) | **GET** /tracks | Get multiple tracks + + +# **getTrackAlbumsRelationship** +```swift + open class func getTrackAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: AlbumsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: albums + +Retrieve album details of the related track. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL track id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: albums (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: albums +TracksAPI.getTrackAlbumsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL track id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: albums | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**AlbumsRelationshipDocument**](AlbumsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getTrackArtistsRelationship** +```swift + open class func getTrackArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ArtistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: artists + +Retrieve artist details of the related track. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL track id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: artists +TracksAPI.getTrackArtistsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL track id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ArtistsRelationshipDocument**](ArtistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getTrackById** +```swift + open class func getTrackById(id: String, countryCode: String, include: [String]? = nil, completion: @escaping (_ data: TracksSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get single track + +Retrieve track details by TIDAL track id. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL track id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio (optional) + +// Get single track +TracksAPI.getTrackById(id: id, countryCode: countryCode, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL track id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio | [optional] + +### Return type + +[**TracksSingleDataDocument**](TracksSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getTrackProvidersRelationship** +```swift + open class func getTrackProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ProvidersRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: providers + +This endpoint can be used to retrieve a list of track's related providers. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the track +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: providers (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: providers +TracksAPI.getTrackProvidersRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the track | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: providers | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ProvidersRelationshipDocument**](ProvidersRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getTrackRadioRelationship** +```swift + open class func getTrackRadioRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: TracksRelationshipsDocument?, _ error: Error?) -> Void) +``` + +Relationship: radio + +This endpoint can be used to retrieve a list of radios for the given track. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the track +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: radio (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: radio +TracksAPI.getTrackRadioRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the track | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: radio | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**TracksRelationshipsDocument**](TracksRelationshipsDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getTrackSimilarTracksRelationship** +```swift + open class func getTrackSimilarTracksRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: TracksRelationshipsDocument?, _ error: Error?) -> Void) +``` + +Relationship: similar tracks + +This endpoint can be used to retrieve a list of tracks similar to the given track. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the track +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: similarTracks (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: similar tracks +TracksAPI.getTrackSimilarTracksRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the track | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: similarTracks | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**TracksRelationshipsDocument**](TracksRelationshipsDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getTracksByFilters** +```swift + open class func getTracksByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterIsrc: [String]? = nil, completion: @escaping (_ data: TracksMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get multiple tracks + +Retrieve multiple track details. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio (optional) +let filterId = ["inner_example"] // [String] | Allows to filter the collection of resources based on id attribute value (optional) +let filterIsrc = ["inner_example"] // [String] | Allows to filter the collection of resources based on isrc attribute value (optional) + +// Get multiple tracks +TracksAPI.getTracksByFilters(countryCode: countryCode, include: include, filterId: filterId, filterIsrc: filterIsrc) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists, albums, providers, similarTracks, radio | [optional] + **filterId** | [**[String]**](String.md) | Allows to filter the collection of resources based on id attribute value | [optional] + **filterIsrc** | [**[String]**](String.md) | Allows to filter the collection of resources based on isrc attribute value | [optional] + +### Return type + +[**TracksMultiDataDocument**](TracksMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/TracksAttributes.md b/Sources/API/Generated/docs/TracksAttributes.md new file mode 100644 index 00000000..3cd71b6a --- /dev/null +++ b/Sources/API/Generated/docs/TracksAttributes.md @@ -0,0 +1,19 @@ +# TracksAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**title** | **String** | Album item's title | +**version** | **String** | Version of the album's item; complements title | [optional] +**isrc** | **String** | ISRC code | +**duration** | **String** | Duration expressed in accordance with ISO 8601 | +**copyright** | **String** | Copyright information | [optional] +**explicit** | **Bool** | Indicates whether a catalog item consist of any explicit content | +**popularity** | **Double** | Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible | +**availability** | **[String]** | Defines a catalog item availability e.g. for streaming, DJs, stems | [optional] +**mediaTags** | **[String]** | | +**externalLinks** | [CatalogueItemExternalLink] | Represents available links to something that is related to a catalog item, but external to the TIDAL API | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/TracksMultiDataDocument.md b/Sources/API/Generated/docs/TracksMultiDataDocument.md new file mode 100644 index 00000000..00c9b24b --- /dev/null +++ b/Sources/API/Generated/docs/TracksMultiDataDocument.md @@ -0,0 +1,12 @@ +# TracksMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [TracksResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [TracksMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/TracksMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/TracksMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..1f9a2bb6 --- /dev/null +++ b/Sources/API/Generated/docs/TracksMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# TracksMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/TracksRelationships.md b/Sources/API/Generated/docs/TracksRelationships.md new file mode 100644 index 00000000..b8472606 --- /dev/null +++ b/Sources/API/Generated/docs/TracksRelationships.md @@ -0,0 +1,14 @@ +# TracksRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**albums** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**artists** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**providers** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**similarTracks** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**radio** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/TracksRelationshipsDocument.md b/Sources/API/Generated/docs/TracksRelationshipsDocument.md new file mode 100644 index 00000000..f5786702 --- /dev/null +++ b/Sources/API/Generated/docs/TracksRelationshipsDocument.md @@ -0,0 +1,12 @@ +# TracksRelationshipsDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [TracksRelationshipsDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/TracksRelationshipsDocumentIncludedInner.md b/Sources/API/Generated/docs/TracksRelationshipsDocumentIncludedInner.md new file mode 100644 index 00000000..07b3a1cb --- /dev/null +++ b/Sources/API/Generated/docs/TracksRelationshipsDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# TracksRelationshipsDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/TracksResource.md b/Sources/API/Generated/docs/TracksResource.md new file mode 100644 index 00000000..e566e9ea --- /dev/null +++ b/Sources/API/Generated/docs/TracksResource.md @@ -0,0 +1,14 @@ +# TracksResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**TracksAttributes**](TracksAttributes.md) | | [optional] +**relationships** | [**TracksRelationships**](TracksRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/TracksSingleDataDocument.md b/Sources/API/Generated/docs/TracksSingleDataDocument.md new file mode 100644 index 00000000..5299623e --- /dev/null +++ b/Sources/API/Generated/docs/TracksSingleDataDocument.md @@ -0,0 +1,12 @@ +# TracksSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**TracksResource**](TracksResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [TracksMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md b/Sources/API/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md new file mode 100644 index 00000000..115c95f9 --- /dev/null +++ b/Sources/API/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md @@ -0,0 +1,10 @@ +# UpdateUserPublicProfilePicksRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**ResourceIdentifier**](ResourceIdentifier.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserEntitlementsAPI.md b/Sources/API/Generated/docs/UserEntitlementsAPI.md new file mode 100644 index 00000000..8629b1de --- /dev/null +++ b/Sources/API/Generated/docs/UserEntitlementsAPI.md @@ -0,0 +1,112 @@ +# UserEntitlementsAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getMyUserEntitlements**](UserEntitlementsAPI.md#getmyuserentitlements) | **GET** /userEntitlements/me | Get the current users entitlements +[**getUserEntitlementsById**](UserEntitlementsAPI.md#getuserentitlementsbyid) | **GET** /userEntitlements/{id} | Get user entitlements for user + + +# **getMyUserEntitlements** +```swift + open class func getMyUserEntitlements(include: [String]? = nil, completion: @escaping (_ data: UserEntitlementsSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get the current users entitlements + +Get the current users entitlements + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned (optional) + +// Get the current users entitlements +UserEntitlementsAPI.getMyUserEntitlements(include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned | [optional] + +### Return type + +[**UserEntitlementsSingleDataDocument**](UserEntitlementsSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserEntitlementsById** +```swift + open class func getUserEntitlementsById(id: String, include: [String]? = nil, completion: @escaping (_ data: UserEntitlementsSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get user entitlements for user + +Get user entitlements for user + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User entitlements id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned (optional) + +// Get user entitlements for user +UserEntitlementsAPI.getUserEntitlementsById(id: id, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User entitlements id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned | [optional] + +### Return type + +[**UserEntitlementsSingleDataDocument**](UserEntitlementsSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/UserEntitlementsAttributes.md b/Sources/API/Generated/docs/UserEntitlementsAttributes.md new file mode 100644 index 00000000..9bf1f4cb --- /dev/null +++ b/Sources/API/Generated/docs/UserEntitlementsAttributes.md @@ -0,0 +1,10 @@ +# UserEntitlementsAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**entitlements** | **[String]** | entitlements for user | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserEntitlementsRelationshipDocument.md b/Sources/API/Generated/docs/UserEntitlementsRelationshipDocument.md new file mode 100644 index 00000000..dbd2e6e5 --- /dev/null +++ b/Sources/API/Generated/docs/UserEntitlementsRelationshipDocument.md @@ -0,0 +1,12 @@ +# UserEntitlementsRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**ResourceIdentifier**](ResourceIdentifier.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserEntitlementsRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..1a98db5c --- /dev/null +++ b/Sources/API/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UserEntitlementsRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UserEntitlementsAttributes**](UserEntitlementsAttributes.md) | | [optional] +**relationships** | **AnyCodable** | relationships object describing relationships between the resource and other resources | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserEntitlementsResource.md b/Sources/API/Generated/docs/UserEntitlementsResource.md new file mode 100644 index 00000000..bfe2a792 --- /dev/null +++ b/Sources/API/Generated/docs/UserEntitlementsResource.md @@ -0,0 +1,14 @@ +# UserEntitlementsResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UserEntitlementsAttributes**](UserEntitlementsAttributes.md) | | [optional] +**relationships** | **AnyCodable** | relationships object describing relationships between the resource and other resources | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserEntitlementsSingleDataDocument.md b/Sources/API/Generated/docs/UserEntitlementsSingleDataDocument.md new file mode 100644 index 00000000..89007f0f --- /dev/null +++ b/Sources/API/Generated/docs/UserEntitlementsSingleDataDocument.md @@ -0,0 +1,11 @@ +# UserEntitlementsSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**UserEntitlementsResource**](UserEntitlementsResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksAPI.md b/Sources/API/Generated/docs/UserPublicProfilePicksAPI.md new file mode 100644 index 00000000..35a23093 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksAPI.md @@ -0,0 +1,281 @@ +# UserPublicProfilePicksAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getMyUserPublicProfilePicks**](UserPublicProfilePicksAPI.md#getmyuserpublicprofilepicks) | **GET** /userPublicProfilePicks/me | Get my picks +[**getUserPublicProfilePickItemRelationship**](UserPublicProfilePicksAPI.md#getuserpublicprofilepickitemrelationship) | **GET** /userPublicProfilePicks/{id}/relationships/item | Relationship: item (read) +[**getUserPublicProfilePickUserPublicProfileRelationship**](UserPublicProfilePicksAPI.md#getuserpublicprofilepickuserpublicprofilerelationship) | **GET** /userPublicProfilePicks/{id}/relationships/userPublicProfile | Relationship: user public profile +[**getUserPublicProfilePicksByFilters**](UserPublicProfilePicksAPI.md#getuserpublicprofilepicksbyfilters) | **GET** /userPublicProfilePicks | Get picks +[**setUserPublicProfilePickItemRelationship**](UserPublicProfilePicksAPI.md#setuserpublicprofilepickitemrelationship) | **PATCH** /userPublicProfilePicks/{id}/relationships/item | Relationship: item (update) + + +# **getMyUserPublicProfilePicks** +```swift + open class func getMyUserPublicProfilePicks(locale: String, include: [String]? = nil, completion: @escaping (_ data: UserPublicProfilePicksMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get my picks + +Retrieves picks for the logged-in user. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let locale = "locale_example" // String | Locale language tag (IETF BCP 47 Language Tag) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile (optional) + +// Get my picks +UserPublicProfilePicksAPI.getMyUserPublicProfilePicks(locale: locale, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **locale** | **String** | Locale language tag (IETF BCP 47 Language Tag) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile | [optional] + +### Return type + +[**UserPublicProfilePicksMultiDataDocument**](UserPublicProfilePicksMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfilePickItemRelationship** +```swift + open class func getUserPublicProfilePickItemRelationship(id: String, locale: String, include: [String]? = nil, completion: @escaping (_ data: UserPublicProfilePicksItemRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: item (read) + +Retrieves a picks item relationship + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL pick id +let locale = "locale_example" // String | Locale language tag (IETF BCP 47 Language Tag) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: item (optional) + +// Relationship: item (read) +UserPublicProfilePicksAPI.getUserPublicProfilePickItemRelationship(id: id, locale: locale, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL pick id | + **locale** | **String** | Locale language tag (IETF BCP 47 Language Tag) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: item | [optional] + +### Return type + +[**UserPublicProfilePicksItemRelationshipDocument**](UserPublicProfilePicksItemRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfilePickUserPublicProfileRelationship** +```swift + open class func getUserPublicProfilePickUserPublicProfileRelationship(id: String, include: [String]? = nil, completion: @escaping (_ data: UserPublicProfilesRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: user public profile + +Retrieves a picks owner public profile + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL pick id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: userPublicProfile (optional) + +// Relationship: user public profile +UserPublicProfilePicksAPI.getUserPublicProfilePickUserPublicProfileRelationship(id: id, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL pick id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: userPublicProfile | [optional] + +### Return type + +[**UserPublicProfilesRelationshipDocument**](UserPublicProfilesRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfilePicksByFilters** +```swift + open class func getUserPublicProfilePicksByFilters(locale: String, include: [String]? = nil, filterId: [String]? = nil, filterUserPublicProfileId: [String]? = nil, completion: @escaping (_ data: UserPublicProfilePicksMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get picks + +Retrieves a filtered collection of user's public picks. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let locale = "locale_example" // String | Locale language tag (IETF BCP 47 Language Tag) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile (optional) +let filterId = ["inner_example"] // [String] | Allows to filter the collection of resources based on id attribute value (optional) +let filterUserPublicProfileId = ["inner_example"] // [String] | Allows to filter the collection of resources based on userPublicProfile.id attribute value (optional) + +// Get picks +UserPublicProfilePicksAPI.getUserPublicProfilePicksByFilters(locale: locale, include: include, filterId: filterId, filterUserPublicProfileId: filterUserPublicProfileId) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **locale** | **String** | Locale language tag (IETF BCP 47 Language Tag) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: item, userPublicProfile | [optional] + **filterId** | [**[String]**](String.md) | Allows to filter the collection of resources based on id attribute value | [optional] + **filterUserPublicProfileId** | [**[String]**](String.md) | Allows to filter the collection of resources based on userPublicProfile.id attribute value | [optional] + +### Return type + +[**UserPublicProfilePicksMultiDataDocument**](UserPublicProfilePicksMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **setUserPublicProfilePickItemRelationship** +```swift + open class func setUserPublicProfilePickItemRelationship(id: String, updateUserPublicProfilePicksRelationshipDocument: UpdateUserPublicProfilePicksRelationshipDocument, include: [String]? = nil, completion: @escaping (_ data: AnyCodable?, _ error: Error?) -> Void) +``` + +Relationship: item (update) + +Updates a picks item relationship, e.g. sets a 'track', 'album' or 'artist' reference. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL pick id +let updateUserPublicProfilePicksRelationshipDocument = Update_User_Public_Profile_Picks_Relationship_Document(data: Resource_Identifier(id: "id_example", type: "type_example")) // UpdateUserPublicProfilePicksRelationshipDocument | +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned (optional) + +// Relationship: item (update) +UserPublicProfilePicksAPI.setUserPublicProfilePickItemRelationship(id: id, updateUserPublicProfilePicksRelationshipDocument: updateUserPublicProfilePicksRelationshipDocument, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL pick id | + **updateUserPublicProfilePicksRelationshipDocument** | [**UpdateUserPublicProfilePicksRelationshipDocument**](UpdateUserPublicProfilePicksRelationshipDocument.md) | | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned | [optional] + +### Return type + +**AnyCodable** + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: application/vnd.api+json + - **Accept**: application/vnd.api+json, */* + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksAttributes.md b/Sources/API/Generated/docs/UserPublicProfilePicksAttributes.md new file mode 100644 index 00000000..2863bef8 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksAttributes.md @@ -0,0 +1,14 @@ +# UserPublicProfilePicksAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**title** | **String** | Pick title | +**description** | **String** | Description of pick | +**supportedContentType** | **String** | CatalogueResourceType for supported item for the pick | +**colors** | [**PromptColors**](PromptColors.md) | | +**lastModifiedAt** | **Date** | Date of last modification of the pick (ISO 8601) | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md b/Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md new file mode 100644 index 00000000..45acea8c --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md @@ -0,0 +1,12 @@ +# UserPublicProfilePicksItemRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**ResourceIdentifier**](ResourceIdentifier.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserPublicProfilePicksItemRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..51e46c85 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UserPublicProfilePicksItemRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocument.md b/Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocument.md new file mode 100644 index 00000000..c3e64a86 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocument.md @@ -0,0 +1,12 @@ +# UserPublicProfilePicksMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [UserPublicProfilePicksResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserPublicProfilePicksMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..4b0bef7d --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UserPublicProfilePicksMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocument.md b/Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocument.md new file mode 100644 index 00000000..7bbf5459 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocument.md @@ -0,0 +1,12 @@ +# UserPublicProfilePicksRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserPublicProfilePicksRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..929e6834 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UserPublicProfilePicksRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UserPublicProfilesAttributes**](UserPublicProfilesAttributes.md) | | [optional] +**relationships** | [**UserPublicProfilesRelationships**](UserPublicProfilesRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksRelationships.md b/Sources/API/Generated/docs/UserPublicProfilePicksRelationships.md new file mode 100644 index 00000000..9c21d941 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksRelationships.md @@ -0,0 +1,11 @@ +# UserPublicProfilePicksRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**item** | [**SingletonDataRelationshipDoc**](SingletonDataRelationshipDoc.md) | | +**userPublicProfile** | [**SingletonDataRelationshipDoc**](SingletonDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksResource.md b/Sources/API/Generated/docs/UserPublicProfilePicksResource.md new file mode 100644 index 00000000..87d7b53a --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilePicksResource.md @@ -0,0 +1,14 @@ +# UserPublicProfilePicksResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UserPublicProfilePicksAttributes**](UserPublicProfilePicksAttributes.md) | | [optional] +**relationships** | [**UserPublicProfilePicksRelationships**](UserPublicProfilePicksRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesAPI.md b/Sources/API/Generated/docs/UserPublicProfilesAPI.md new file mode 100644 index 00000000..366cb581 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesAPI.md @@ -0,0 +1,391 @@ +# UserPublicProfilesAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getMyUserPublicProfile**](UserPublicProfilesAPI.md#getmyuserpublicprofile) | **GET** /userPublicProfiles/me | Get my user profile +[**getUserPublicProfileById**](UserPublicProfilesAPI.md#getuserpublicprofilebyid) | **GET** /userPublicProfiles/{id} | Get user public profile by id +[**getUserPublicProfileFollowersRelationship**](UserPublicProfilesAPI.md#getuserpublicprofilefollowersrelationship) | **GET** /userPublicProfiles/{id}/relationships/followers | Relationship: followers +[**getUserPublicProfileFollowingRelationship**](UserPublicProfilesAPI.md#getuserpublicprofilefollowingrelationship) | **GET** /userPublicProfiles/{id}/relationships/following | Relationship: following +[**getUserPublicProfilePublicPicksRelationship**](UserPublicProfilesAPI.md#getuserpublicprofilepublicpicksrelationship) | **GET** /userPublicProfiles/{id}/relationships/publicPicks | Relationship: picks +[**getUserPublicProfilePublicPlaylistsRelationship**](UserPublicProfilesAPI.md#getuserpublicprofilepublicplaylistsrelationship) | **GET** /userPublicProfiles/{id}/relationships/publicPlaylists | Relationship: playlists +[**getUserPublicProfilesByFilters**](UserPublicProfilesAPI.md#getuserpublicprofilesbyfilters) | **GET** /userPublicProfiles | Get user public profiles + + +# **getMyUserPublicProfile** +```swift + open class func getMyUserPublicProfile(locale: String, include: [String]? = nil, completion: @escaping (_ data: UserPublicProfilesSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get my user profile + +Retrieve the logged-in user's public profile details. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let locale = "locale_example" // String | Locale language tag (IETF BCP 47 Language Tag) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) + +// Get my user profile +UserPublicProfilesAPI.getMyUserPublicProfile(locale: locale, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **locale** | **String** | Locale language tag (IETF BCP 47 Language Tag) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following | [optional] + +### Return type + +[**UserPublicProfilesSingleDataDocument**](UserPublicProfilesSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfileById** +```swift + open class func getUserPublicProfileById(id: String, locale: String, include: [String]? = nil, completion: @escaping (_ data: UserPublicProfilesSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get user public profile by id + +Retrieve user public profile details by TIDAL user id. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL user id +let locale = "locale_example" // String | Locale language tag (IETF BCP 47 Language Tag) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) + +// Get user public profile by id +UserPublicProfilesAPI.getUserPublicProfileById(id: id, locale: locale, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL user id | + **locale** | **String** | Locale language tag (IETF BCP 47 Language Tag) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following | [optional] + +### Return type + +[**UserPublicProfilesSingleDataDocument**](UserPublicProfilesSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfileFollowersRelationship** +```swift + open class func getUserPublicProfileFollowersRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: UsersRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: followers + +Retrieve user's public followers + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL user id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: followers (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: followers +UserPublicProfilesAPI.getUserPublicProfileFollowersRelationship(id: id, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL user id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: followers | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**UsersRelationshipDocument**](UsersRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfileFollowingRelationship** +```swift + open class func getUserPublicProfileFollowingRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: UsersRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: following + +Retrieve user's public followings + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL user id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: following (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: following +UserPublicProfilesAPI.getUserPublicProfileFollowingRelationship(id: id, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL user id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: following | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**UsersRelationshipDocument**](UsersRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfilePublicPicksRelationship** +```swift + open class func getUserPublicProfilePublicPicksRelationship(id: String, locale: String, include: [String]? = nil, completion: @escaping (_ data: UserPublicProfilePicksRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: picks + +Retrieve user's public picks. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL user id +let locale = "locale_example" // String | Locale language tag (IETF BCP 47 Language Tag) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: publicPicks (optional) + +// Relationship: picks +UserPublicProfilesAPI.getUserPublicProfilePublicPicksRelationship(id: id, locale: locale, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL user id | + **locale** | **String** | Locale language tag (IETF BCP 47 Language Tag) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: publicPicks | [optional] + +### Return type + +[**UserPublicProfilePicksRelationshipDocument**](UserPublicProfilePicksRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfilePublicPlaylistsRelationship** +```swift + open class func getUserPublicProfilePublicPlaylistsRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: PlaylistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: playlists + +Retrieves user's public playlists. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL user id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: publicPlaylists (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: playlists +UserPublicProfilesAPI.getUserPublicProfilePublicPlaylistsRelationship(id: id, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL user id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: publicPlaylists | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**PlaylistsRelationshipDocument**](PlaylistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfilesByFilters** +```swift + open class func getUserPublicProfilesByFilters(locale: String, include: [String]? = nil, filterId: [String]? = nil, completion: @escaping (_ data: UserPublicProfilesMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get user public profiles + +Reads user public profile details by TIDAL user ids. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let locale = "locale_example" // String | Locale language tag (IETF BCP 47 Language Tag) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following (optional) +let filterId = ["inner_example"] // [String] | TIDAL user id (optional) + +// Get user public profiles +UserPublicProfilesAPI.getUserPublicProfilesByFilters(locale: locale, include: include, filterId: filterId) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **locale** | **String** | Locale language tag (IETF BCP 47 Language Tag) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: publicPlaylists, publicPicks, followers, following | [optional] + **filterId** | [**[String]**](String.md) | TIDAL user id | [optional] + +### Return type + +[**UserPublicProfilesMultiDataDocument**](UserPublicProfilesMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/UserPublicProfilesAttributes.md b/Sources/API/Generated/docs/UserPublicProfilesAttributes.md new file mode 100644 index 00000000..7ede2b91 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesAttributes.md @@ -0,0 +1,15 @@ +# UserPublicProfilesAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**profileName** | **String** | Public Name of the user profile | [optional] +**picture** | [**UserPublicProfilesImageLink**](UserPublicProfilesImageLink.md) | | [optional] +**color** | **[String]** | | +**externalLinks** | [UserPublicProfilesExternalLink] | ExternalLinks for the user's profile | [optional] +**numberOfFollowers** | **Int** | Number of followers for the user | [optional] +**numberOfFollows** | **Int** | Number of users the user follows | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesExternalLink.md b/Sources/API/Generated/docs/UserPublicProfilesExternalLink.md new file mode 100644 index 00000000..f34be932 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesExternalLink.md @@ -0,0 +1,11 @@ +# UserPublicProfilesExternalLink + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**href** | **String** | link to something that is related to a resource | +**meta** | [**UserPublicProfilesExternalLinkMeta**](UserPublicProfilesExternalLinkMeta.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesExternalLinkMeta.md b/Sources/API/Generated/docs/UserPublicProfilesExternalLinkMeta.md new file mode 100644 index 00000000..7b85f171 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesExternalLinkMeta.md @@ -0,0 +1,11 @@ +# UserPublicProfilesExternalLinkMeta + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**type** | **String** | external link type | +**handle** | **String** | external link handle | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesImageLink.md b/Sources/API/Generated/docs/UserPublicProfilesImageLink.md new file mode 100644 index 00000000..cde2def7 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesImageLink.md @@ -0,0 +1,11 @@ +# UserPublicProfilesImageLink + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**href** | **String** | link to an image | +**meta** | [**ImageLinkMeta**](ImageLinkMeta.md) | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesMultiDataDocument.md b/Sources/API/Generated/docs/UserPublicProfilesMultiDataDocument.md new file mode 100644 index 00000000..86579daf --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesMultiDataDocument.md @@ -0,0 +1,12 @@ +# UserPublicProfilesMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [UserPublicProfilesResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserPublicProfilesMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..410f3970 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UserPublicProfilesMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | **AnyCodable** | attributes object representing some of the resource's data | [optional] +**relationships** | [**UserRecommendationsRelationships**](UserRecommendationsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesRelationshipDocument.md b/Sources/API/Generated/docs/UserPublicProfilesRelationshipDocument.md new file mode 100644 index 00000000..866aab5b --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesRelationshipDocument.md @@ -0,0 +1,12 @@ +# UserPublicProfilesRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**ResourceIdentifier**](ResourceIdentifier.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserPublicProfilesRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..5ea2bc1a --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UserPublicProfilesRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UserPublicProfilePicksAttributes**](UserPublicProfilePicksAttributes.md) | | [optional] +**relationships** | [**UserPublicProfilePicksRelationships**](UserPublicProfilePicksRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesRelationships.md b/Sources/API/Generated/docs/UserPublicProfilesRelationships.md new file mode 100644 index 00000000..a365481e --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesRelationships.md @@ -0,0 +1,13 @@ +# UserPublicProfilesRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**followers** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**following** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**publicPlaylists** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**publicPicks** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesResource.md b/Sources/API/Generated/docs/UserPublicProfilesResource.md new file mode 100644 index 00000000..b19b0db1 --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesResource.md @@ -0,0 +1,14 @@ +# UserPublicProfilesResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UserPublicProfilesAttributes**](UserPublicProfilesAttributes.md) | | [optional] +**relationships** | [**UserPublicProfilesRelationships**](UserPublicProfilesRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserPublicProfilesSingleDataDocument.md b/Sources/API/Generated/docs/UserPublicProfilesSingleDataDocument.md new file mode 100644 index 00000000..ea8392ea --- /dev/null +++ b/Sources/API/Generated/docs/UserPublicProfilesSingleDataDocument.md @@ -0,0 +1,12 @@ +# UserPublicProfilesSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**UserPublicProfilesResource**](UserPublicProfilesResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserPublicProfilesMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserRecommendationsAPI.md b/Sources/API/Generated/docs/UserRecommendationsAPI.md new file mode 100644 index 00000000..37665721 --- /dev/null +++ b/Sources/API/Generated/docs/UserRecommendationsAPI.md @@ -0,0 +1,330 @@ +# UserRecommendationsAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getMyUserRecommendations**](UserRecommendationsAPI.md#getmyuserrecommendations) | **GET** /userRecommendations/me | Get the current users recommendations +[**getUserRecommendationsByFilters**](UserRecommendationsAPI.md#getuserrecommendationsbyfilters) | **GET** /userRecommendations | Get recommendations for users in batch +[**getUserRecommendationsById**](UserRecommendationsAPI.md#getuserrecommendationsbyid) | **GET** /userRecommendations/{id} | Get user recommendations for user +[**getUserRecommendationsDiscoveryMixesRelationship**](UserRecommendationsAPI.md#getuserrecommendationsdiscoverymixesrelationship) | **GET** /userRecommendations/{id}/relationships/discoveryMixes | Relationship: discovery mixes +[**getUserRecommendationsMyMixesRelationship**](UserRecommendationsAPI.md#getuserrecommendationsmymixesrelationship) | **GET** /userRecommendations/{id}/relationships/myMixes | Relationship: my mixes +[**getUserRecommendationsNewArrivalMixesRelationship**](UserRecommendationsAPI.md#getuserrecommendationsnewarrivalmixesrelationship) | **GET** /userRecommendations/{id}/relationships/newArrivalMixes | Relationship: new arrivals mixes + + +# **getMyUserRecommendations** +```swift + open class func getMyUserRecommendations(include: [String]? = nil, completion: @escaping (_ data: UserRecommendationsSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get the current users recommendations + +Get the current users recommendations + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) + +// Get the current users recommendations +UserRecommendationsAPI.getMyUserRecommendations(include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes | [optional] + +### Return type + +[**UserRecommendationsSingleDataDocument**](UserRecommendationsSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserRecommendationsByFilters** +```swift + open class func getUserRecommendationsByFilters(include: [String]? = nil, filterId: [String]? = nil, completion: @escaping (_ data: UserRecommendationsMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get recommendations for users in batch + +Get recommendations for users in batch + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) +let filterId = ["inner_example"] // [String] | User recommendations id (optional) + +// Get recommendations for users in batch +UserRecommendationsAPI.getUserRecommendationsByFilters(include: include, filterId: filterId) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes | [optional] + **filterId** | [**[String]**](String.md) | User recommendations id | [optional] + +### Return type + +[**UserRecommendationsMultiDataDocument**](UserRecommendationsMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserRecommendationsById** +```swift + open class func getUserRecommendationsById(id: String, include: [String]? = nil, completion: @escaping (_ data: UserRecommendationsSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get user recommendations for user + +Get user recommendations for user + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User recommendations id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes (optional) + +// Get user recommendations for user +UserRecommendationsAPI.getUserRecommendationsById(id: id, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User recommendations id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: myMixes, discoveryMixes, newArrivalMixes | [optional] + +### Return type + +[**UserRecommendationsSingleDataDocument**](UserRecommendationsSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserRecommendationsDiscoveryMixesRelationship** +```swift + open class func getUserRecommendationsDiscoveryMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: PlaylistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: discovery mixes + +Get discovery mixes relationship + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User recommendations id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: discoveryMixes (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: discovery mixes +UserRecommendationsAPI.getUserRecommendationsDiscoveryMixesRelationship(id: id, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User recommendations id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: discoveryMixes | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**PlaylistsRelationshipDocument**](PlaylistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserRecommendationsMyMixesRelationship** +```swift + open class func getUserRecommendationsMyMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: PlaylistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: my mixes + +Get my mixes relationship + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User recommendations id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: myMixes (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: my mixes +UserRecommendationsAPI.getUserRecommendationsMyMixesRelationship(id: id, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User recommendations id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: myMixes | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**PlaylistsRelationshipDocument**](PlaylistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserRecommendationsNewArrivalMixesRelationship** +```swift + open class func getUserRecommendationsNewArrivalMixesRelationship(id: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: PlaylistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: new arrivals mixes + +Get new arrival mixes relationship + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User recommendations id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: newArrivalMixes (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: new arrivals mixes +UserRecommendationsAPI.getUserRecommendationsNewArrivalMixesRelationship(id: id, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User recommendations id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: newArrivalMixes | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**PlaylistsRelationshipDocument**](PlaylistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/UserRecommendationsMultiDataDocument.md b/Sources/API/Generated/docs/UserRecommendationsMultiDataDocument.md new file mode 100644 index 00000000..d0bd4d49 --- /dev/null +++ b/Sources/API/Generated/docs/UserRecommendationsMultiDataDocument.md @@ -0,0 +1,12 @@ +# UserRecommendationsMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [UserRecommendationsResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserRecommendationsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..f5dea668 --- /dev/null +++ b/Sources/API/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UserRecommendationsMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserRecommendationsRelationships.md b/Sources/API/Generated/docs/UserRecommendationsRelationships.md new file mode 100644 index 00000000..4bc72587 --- /dev/null +++ b/Sources/API/Generated/docs/UserRecommendationsRelationships.md @@ -0,0 +1,12 @@ +# UserRecommendationsRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**myMixes** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**discoveryMixes** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**newArrivalMixes** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserRecommendationsResource.md b/Sources/API/Generated/docs/UserRecommendationsResource.md new file mode 100644 index 00000000..bcad549d --- /dev/null +++ b/Sources/API/Generated/docs/UserRecommendationsResource.md @@ -0,0 +1,14 @@ +# UserRecommendationsResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | **AnyCodable** | attributes object representing some of the resource's data | [optional] +**relationships** | [**UserRecommendationsRelationships**](UserRecommendationsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UserRecommendationsSingleDataDocument.md b/Sources/API/Generated/docs/UserRecommendationsSingleDataDocument.md new file mode 100644 index 00000000..1b594ba2 --- /dev/null +++ b/Sources/API/Generated/docs/UserRecommendationsSingleDataDocument.md @@ -0,0 +1,12 @@ +# UserRecommendationsSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**UserRecommendationsResource**](UserRecommendationsResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UserRecommendationsMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersAPI.md b/Sources/API/Generated/docs/UsersAPI.md new file mode 100644 index 00000000..70a59f92 --- /dev/null +++ b/Sources/API/Generated/docs/UsersAPI.md @@ -0,0 +1,326 @@ +# UsersAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getMyUser**](UsersAPI.md#getmyuser) | **GET** /users/me | Get the current user +[**getUserById**](UsersAPI.md#getuserbyid) | **GET** /users/{id} | Get a single user by id +[**getUserEntitlementsRelationship**](UsersAPI.md#getuserentitlementsrelationship) | **GET** /users/{id}/relationships/entitlements | Relationship: entitlements +[**getUserPublicProfileRelationship**](UsersAPI.md#getuserpublicprofilerelationship) | **GET** /users/{id}/relationships/publicProfile | Relationship: public profile +[**getUserRecommendationsRelationship**](UsersAPI.md#getuserrecommendationsrelationship) | **GET** /users/{id}/relationships/recommendations | Relationship: user recommendations +[**getUsersByFilters**](UsersAPI.md#getusersbyfilters) | **GET** /users | Get multiple users by id + + +# **getMyUser** +```swift + open class func getMyUser(include: [String]? = nil, completion: @escaping (_ data: UsersSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get the current user + +Get the current user + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) + +// Get the current user +UsersAPI.getMyUser(include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations | [optional] + +### Return type + +[**UsersSingleDataDocument**](UsersSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserById** +```swift + open class func getUserById(id: String, include: [String]? = nil, completion: @escaping (_ data: UsersSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get a single user by id + +Get a single user by id + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User Id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) + +// Get a single user by id +UsersAPI.getUserById(id: id, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User Id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations | [optional] + +### Return type + +[**UsersSingleDataDocument**](UsersSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserEntitlementsRelationship** +```swift + open class func getUserEntitlementsRelationship(id: String, include: [String]? = nil, completion: @escaping (_ data: UserEntitlementsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: entitlements + +Get user entitlements relationship + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User Id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: entitlements (optional) + +// Relationship: entitlements +UsersAPI.getUserEntitlementsRelationship(id: id, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User Id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: entitlements | [optional] + +### Return type + +[**UserEntitlementsRelationshipDocument**](UserEntitlementsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserPublicProfileRelationship** +```swift + open class func getUserPublicProfileRelationship(id: String, locale: String, include: [String]? = nil, completion: @escaping (_ data: UserPublicProfilesRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: public profile + +Get user public profile + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User Id +let locale = "locale_example" // String | Locale language tag (IETF BCP 47 Language Tag) +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: publicProfile (optional) + +// Relationship: public profile +UsersAPI.getUserPublicProfileRelationship(id: id, locale: locale, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User Id | + **locale** | **String** | Locale language tag (IETF BCP 47 Language Tag) | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: publicProfile | [optional] + +### Return type + +[**UserPublicProfilesRelationshipDocument**](UserPublicProfilesRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUserRecommendationsRelationship** +```swift + open class func getUserRecommendationsRelationship(id: String, include: [String]? = nil, completion: @escaping (_ data: UsersRecommendationsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: user recommendations + +Get user recommendations + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | User Id +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: recommendations (optional) + +// Relationship: user recommendations +UsersAPI.getUserRecommendationsRelationship(id: id, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | User Id | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: recommendations | [optional] + +### Return type + +[**UsersRecommendationsRelationshipDocument**](UsersRecommendationsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getUsersByFilters** +```swift + open class func getUsersByFilters(include: [String]? = nil, filterId: [String]? = nil, completion: @escaping (_ data: UsersMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get multiple users by id + +Get multiple users by id + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations (optional) +let filterId = ["inner_example"] // [String] | Allows to filter the collection of resources based on id attribute value (optional) + +// Get multiple users by id +UsersAPI.getUsersByFilters(include: include, filterId: filterId) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: entitlements, publicProfile, recommendations | [optional] + **filterId** | [**[String]**](String.md) | Allows to filter the collection of resources based on id attribute value | [optional] + +### Return type + +[**UsersMultiDataDocument**](UsersMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/UsersAttributes.md b/Sources/API/Generated/docs/UsersAttributes.md new file mode 100644 index 00000000..6d4d266d --- /dev/null +++ b/Sources/API/Generated/docs/UsersAttributes.md @@ -0,0 +1,15 @@ +# UsersAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**username** | **String** | user name | +**country** | **String** | ISO 3166-1 alpha-2 country code | +**email** | **String** | email address | [optional] +**emailVerified** | **Bool** | Is the email verified | [optional] +**firstName** | **String** | Users first name | [optional] +**lastName** | **String** | Users last name | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersMultiDataDocument.md b/Sources/API/Generated/docs/UsersMultiDataDocument.md new file mode 100644 index 00000000..eacaaf8d --- /dev/null +++ b/Sources/API/Generated/docs/UsersMultiDataDocument.md @@ -0,0 +1,12 @@ +# UsersMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [UsersResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UsersMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/UsersMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..57a4c942 --- /dev/null +++ b/Sources/API/Generated/docs/UsersMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UsersMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersRecommendationsRelationshipDocument.md b/Sources/API/Generated/docs/UsersRecommendationsRelationshipDocument.md new file mode 100644 index 00000000..b15250df --- /dev/null +++ b/Sources/API/Generated/docs/UsersRecommendationsRelationshipDocument.md @@ -0,0 +1,12 @@ +# UsersRecommendationsRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**ResourceIdentifier**](ResourceIdentifier.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UsersRecommendationsRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..a8e159fd --- /dev/null +++ b/Sources/API/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UsersRecommendationsRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersRelationshipDocument.md b/Sources/API/Generated/docs/UsersRelationshipDocument.md new file mode 100644 index 00000000..daf1b8ae --- /dev/null +++ b/Sources/API/Generated/docs/UsersRelationshipDocument.md @@ -0,0 +1,12 @@ +# UsersRelationshipDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UsersRelationshipDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersRelationshipDocumentIncludedInner.md b/Sources/API/Generated/docs/UsersRelationshipDocumentIncludedInner.md new file mode 100644 index 00000000..b8d705c8 --- /dev/null +++ b/Sources/API/Generated/docs/UsersRelationshipDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# UsersRelationshipDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | **AnyCodable** | attributes object representing some of the resource's data | [optional] +**relationships** | [**UserRecommendationsRelationships**](UserRecommendationsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersRelationships.md b/Sources/API/Generated/docs/UsersRelationships.md new file mode 100644 index 00000000..cb3cba9f --- /dev/null +++ b/Sources/API/Generated/docs/UsersRelationships.md @@ -0,0 +1,12 @@ +# UsersRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**entitlements** | [**SingletonDataRelationshipDoc**](SingletonDataRelationshipDoc.md) | | +**publicProfile** | [**SingletonDataRelationshipDoc**](SingletonDataRelationshipDoc.md) | | +**recommendations** | [**SingletonDataRelationshipDoc**](SingletonDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersResource.md b/Sources/API/Generated/docs/UsersResource.md new file mode 100644 index 00000000..6df7f893 --- /dev/null +++ b/Sources/API/Generated/docs/UsersResource.md @@ -0,0 +1,14 @@ +# UsersResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**UsersAttributes**](UsersAttributes.md) | | [optional] +**relationships** | [**UsersRelationships**](UsersRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/UsersSingleDataDocument.md b/Sources/API/Generated/docs/UsersSingleDataDocument.md new file mode 100644 index 00000000..1ed9b7dc --- /dev/null +++ b/Sources/API/Generated/docs/UsersSingleDataDocument.md @@ -0,0 +1,12 @@ +# UsersSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**UsersResource**](UsersResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [UsersMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideoLinkMeta.md b/Sources/API/Generated/docs/VideoLinkMeta.md new file mode 100644 index 00000000..2ed41bba --- /dev/null +++ b/Sources/API/Generated/docs/VideoLinkMeta.md @@ -0,0 +1,11 @@ +# VideoLinkMeta + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**width** | **Int** | video width (in pixels) | +**height** | **Int** | video height (in pixels) | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideosAPI.md b/Sources/API/Generated/docs/VideosAPI.md new file mode 100644 index 00000000..fe970517 --- /dev/null +++ b/Sources/API/Generated/docs/VideosAPI.md @@ -0,0 +1,291 @@ +# VideosAPI + +All URIs are relative to *https://openapi.tidal.com/v2* + +Method | HTTP request | Description +------------- | ------------- | ------------- +[**getVideoAlbumsRelationship**](VideosAPI.md#getvideoalbumsrelationship) | **GET** /videos/{id}/relationships/albums | Relationship: albums +[**getVideoArtistsRelationship**](VideosAPI.md#getvideoartistsrelationship) | **GET** /videos/{id}/relationships/artists | Relationship: artists +[**getVideoById**](VideosAPI.md#getvideobyid) | **GET** /videos/{id} | Get single video +[**getVideoProvidersRelationship**](VideosAPI.md#getvideoprovidersrelationship) | **GET** /videos/{id}/relationships/providers | Relationship: providers +[**getVideosByFilters**](VideosAPI.md#getvideosbyfilters) | **GET** /videos | Get multiple videos + + +# **getVideoAlbumsRelationship** +```swift + open class func getVideoAlbumsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: AlbumsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: albums + +Retrieve album details of the related video. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL video id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: albums (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: albums +VideosAPI.getVideoAlbumsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL video id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: albums | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**AlbumsRelationshipDocument**](AlbumsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getVideoArtistsRelationship** +```swift + open class func getVideoArtistsRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ArtistsRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: artists + +Retrieve artist details of the related video. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL video id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: artists +VideosAPI.getVideoArtistsRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL video id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ArtistsRelationshipDocument**](ArtistsRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getVideoById** +```swift + open class func getVideoById(id: String, countryCode: String, include: [String]? = nil, completion: @escaping (_ data: VideosSingleDataDocument?, _ error: Error?) -> Void) +``` + +Get single video + +Retrieve video details by TIDAL video id. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL video id +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists, albums, providers (optional) + +// Get single video +VideosAPI.getVideoById(id: id, countryCode: countryCode, include: include) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL video id | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists, albums, providers | [optional] + +### Return type + +[**VideosSingleDataDocument**](VideosSingleDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getVideoProvidersRelationship** +```swift + open class func getVideoProvidersRelationship(id: String, countryCode: String, include: [String]? = nil, pageCursor: String? = nil, completion: @escaping (_ data: ProvidersRelationshipDocument?, _ error: Error?) -> Void) +``` + +Relationship: providers + +This endpoint can be used to retrieve a list of video's related providers. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let id = "id_example" // String | TIDAL id of the video +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: providers (optional) +let pageCursor = "pageCursor_example" // String | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified (optional) + +// Relationship: providers +VideosAPI.getVideoProvidersRelationship(id: id, countryCode: countryCode, include: include, pageCursor: pageCursor) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **id** | **String** | TIDAL id of the video | + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: providers | [optional] + **pageCursor** | **String** | Server-generated cursor value pointing a certain page of items. Optional, targets first page if not specified | [optional] + +### Return type + +[**ProvidersRelationshipDocument**](ProvidersRelationshipDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + +# **getVideosByFilters** +```swift + open class func getVideosByFilters(countryCode: String, include: [String]? = nil, filterId: [String]? = nil, filterIsrc: [String]? = nil, completion: @escaping (_ data: VideosMultiDataDocument?, _ error: Error?) -> Void) +``` + +Get multiple videos + +Retrieve multiple video details. + +### Example +```swift +// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new +import OpenAPIClient + +let countryCode = "countryCode_example" // String | ISO 3166-1 alpha-2 country code +let include = ["inner_example"] // [String] | Allows the client to customize which related resources should be returned. Available options: artists, albums, providers (optional) +let filterId = ["inner_example"] // [String] | Allows to filter the collection of resources based on id attribute value (optional) +let filterIsrc = ["inner_example"] // [String] | Allows to filter the collection of resources based on isrc attribute value (optional) + +// Get multiple videos +VideosAPI.getVideosByFilters(countryCode: countryCode, include: include, filterId: filterId, filterIsrc: filterIsrc) { (response, error) in + guard error == nil else { + print(error) + return + } + + if (response) { + dump(response) + } +} +``` + +### Parameters + +Name | Type | Description | Notes +------------- | ------------- | ------------- | ------------- + **countryCode** | **String** | ISO 3166-1 alpha-2 country code | + **include** | [**[String]**](String.md) | Allows the client to customize which related resources should be returned. Available options: artists, albums, providers | [optional] + **filterId** | [**[String]**](String.md) | Allows to filter the collection of resources based on id attribute value | [optional] + **filterIsrc** | [**[String]**](String.md) | Allows to filter the collection of resources based on isrc attribute value | [optional] + +### Return type + +[**VideosMultiDataDocument**](VideosMultiDataDocument.md) + +### Authorization + +[Authorization_Code_PKCE](../README.md#Authorization_Code_PKCE), [Client_Credentials](../README.md#Client_Credentials) + +### HTTP request headers + + - **Content-Type**: Not defined + - **Accept**: application/vnd.api+json + +[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) + diff --git a/Sources/API/Generated/docs/VideosAttributes.md b/Sources/API/Generated/docs/VideosAttributes.md new file mode 100644 index 00000000..1c144638 --- /dev/null +++ b/Sources/API/Generated/docs/VideosAttributes.md @@ -0,0 +1,20 @@ +# VideosAttributes + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**title** | **String** | Album item's title | +**version** | **String** | Version of the album's item; complements title | [optional] +**isrc** | **String** | ISRC code | +**duration** | **String** | Duration expressed in accordance with ISO 8601 | +**copyright** | **String** | Copyright information | [optional] +**releaseDate** | **Date** | Release date (ISO-8601) | [optional] +**explicit** | **Bool** | Indicates whether a catalog item consist of any explicit content | +**popularity** | **Double** | Track or video popularity (ranged in 0.00 ... 1.00). Conditionally visible | +**availability** | **[String]** | Defines a catalog item availability e.g. for streaming, DJs, stems | [optional] +**imageLinks** | [CatalogueItemImageLink] | Represents available links to, and metadata about, an album item images | [optional] +**externalLinks** | [CatalogueItemExternalLink] | Represents available links to something that is related to a catalog item, but external to the TIDAL API | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideosMultiDataDocument.md b/Sources/API/Generated/docs/VideosMultiDataDocument.md new file mode 100644 index 00000000..9a8de873 --- /dev/null +++ b/Sources/API/Generated/docs/VideosMultiDataDocument.md @@ -0,0 +1,12 @@ +# VideosMultiDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [VideosResource] | array of primary resource data | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [VideosMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideosMultiDataDocumentIncludedInner.md b/Sources/API/Generated/docs/VideosMultiDataDocumentIncludedInner.md new file mode 100644 index 00000000..a74a0ca9 --- /dev/null +++ b/Sources/API/Generated/docs/VideosMultiDataDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# VideosMultiDataDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**PlaylistsAttributes**](PlaylistsAttributes.md) | | [optional] +**relationships** | [**PlaylistsRelationships**](PlaylistsRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideosRelationships.md b/Sources/API/Generated/docs/VideosRelationships.md new file mode 100644 index 00000000..956116bf --- /dev/null +++ b/Sources/API/Generated/docs/VideosRelationships.md @@ -0,0 +1,12 @@ +# VideosRelationships + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**albums** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**artists** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | +**providers** | [**MultiDataRelationshipDoc**](MultiDataRelationshipDoc.md) | | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideosRelationshipsDocument.md b/Sources/API/Generated/docs/VideosRelationshipsDocument.md new file mode 100644 index 00000000..cf19b3d4 --- /dev/null +++ b/Sources/API/Generated/docs/VideosRelationshipsDocument.md @@ -0,0 +1,12 @@ +# VideosRelationshipsDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [ResourceIdentifier] | array of relationship resource linkages | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [VideosRelationshipsDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideosRelationshipsDocumentIncludedInner.md b/Sources/API/Generated/docs/VideosRelationshipsDocumentIncludedInner.md new file mode 100644 index 00000000..4e9d090e --- /dev/null +++ b/Sources/API/Generated/docs/VideosRelationshipsDocumentIncludedInner.md @@ -0,0 +1,14 @@ +# VideosRelationshipsDocumentIncludedInner + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**ProvidersAttributes**](ProvidersAttributes.md) | | [optional] +**relationships** | **AnyCodable** | relationships object describing relationships between the resource and other resources | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideosResource.md b/Sources/API/Generated/docs/VideosResource.md new file mode 100644 index 00000000..5335d78d --- /dev/null +++ b/Sources/API/Generated/docs/VideosResource.md @@ -0,0 +1,14 @@ +# VideosResource + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**attributes** | [**VideosAttributes**](VideosAttributes.md) | | [optional] +**relationships** | [**VideosRelationships**](VideosRelationships.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**id** | **String** | resource unique identifier | +**type** | **String** | resource unique type | + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + diff --git a/Sources/API/Generated/docs/VideosSingleDataDocument.md b/Sources/API/Generated/docs/VideosSingleDataDocument.md new file mode 100644 index 00000000..bc9490bf --- /dev/null +++ b/Sources/API/Generated/docs/VideosSingleDataDocument.md @@ -0,0 +1,12 @@ +# VideosSingleDataDocument + +## Properties +Name | Type | Description | Notes +------------ | ------------- | ------------- | ------------- +**data** | [**VideosResource**](VideosResource.md) | | [optional] +**links** | [**Links**](Links.md) | | [optional] +**included** | [VideosMultiDataDocumentIncludedInner] | | [optional] + +[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) + + From c1a10860151e5090eee6c81ade41d3353dcbf46d Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Tue, 22 Oct 2024 12:40:02 +0200 Subject: [PATCH 08/11] renamed "API" to "TidalAPI" --- Package.swift | 8 ++++---- .../Config/custom_template/TidalAPI.mustache | 0 .../{API => TidalAPI}/Config/custom_template/api.mustache | 0 .../Config/input/tidal-catalog-v2-openapi-3.0.json | 0 .../Config/input/tidal-search-v2-openapi-3.0.json | 0 .../Config/input/tidal-user-content-openapi-3.0.json | 0 .../Config/input/tidal-user-v2-openapi-3.0.json | 0 Sources/{API => TidalAPI}/Config/openapi-config.yml | 0 .../{API => TidalAPI}/Generated/.openapi-generator/FILES | 0 .../Generated/.openapi-generator/VERSION | 0 .../OpenAPIClient/Classes/OpenAPIs/APIHelper.swift | 0 .../Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift | 0 .../Classes/OpenAPIs/APIs/AlbumsAPITidal.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift | 0 .../Classes/OpenAPIs/APIs/ArtistsAPITidal.swift | 0 .../Classes/OpenAPIs/APIs/PlaylistsAPI.swift | 0 .../Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift | 0 .../Classes/OpenAPIs/APIs/ProvidersAPI.swift | 0 .../Classes/OpenAPIs/APIs/ProvidersAPITidal.swift | 0 .../Classes/OpenAPIs/APIs/SearchResultsAPI.swift | 0 .../Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift | 0 .../Classes/OpenAPIs/APIs/TracksAPITidal.swift | 0 .../Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift | 0 .../Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift | 0 .../Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift | 0 .../OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift | 0 .../Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift | 0 .../OpenAPIs/APIs/UserPublicProfilesAPITidal.swift | 0 .../Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift | 0 .../OpenAPIs/APIs/UserRecommendationsAPITidal.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift | 0 .../Classes/OpenAPIs/APIs/UsersAPITidal.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift | 0 .../Classes/OpenAPIs/APIs/VideosAPITidal.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/Configuration.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/Extensions.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift | 0 .../Classes/OpenAPIs/JSONEncodingHelper.swift | 0 .../Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift | 0 .../Classes/OpenAPIs/Models/AlbumsAttributes.swift | 0 .../OpenAPIs/Models/AlbumsItemResourceIdentifier.swift | 0 .../Models/AlbumsItemResourceIdentifierMeta.swift | 0 .../Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift | 0 .../OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift | 0 .../AlbumsItemsRelationshipDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift | 0 .../Models/AlbumsMultiDataDocumentIncludedInner.swift | 0 .../OpenAPIs/Models/AlbumsRelationshipDocument.swift | 0 .../Models/AlbumsRelationshipDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/AlbumsRelationships.swift | 0 .../Classes/OpenAPIs/Models/AlbumsResource.swift | 0 .../OpenAPIs/Models/AlbumsSingleDataDocument.swift | 0 .../Classes/OpenAPIs/Models/ArtistsAttributes.swift | 0 .../OpenAPIs/Models/ArtistsMultiDataDocument.swift | 0 .../Models/ArtistsMultiDataDocumentIncludedInner.swift | 0 .../OpenAPIs/Models/ArtistsRelationshipDocument.swift | 0 .../Models/ArtistsRelationshipDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/ArtistsRelationships.swift | 0 .../Classes/OpenAPIs/Models/ArtistsResource.swift | 0 .../OpenAPIs/Models/ArtistsSingleDataDocument.swift | 0 .../Models/ArtistsTrackProvidersRelationship.swift | 0 .../ArtistsTrackProvidersRelationshipDocument.swift | 0 .../Models/ArtistsTrackProvidersResourceIdentifier.swift | 0 .../ArtistsTrackProvidersResourceIdentifierMeta.swift | 0 .../OpenAPIs/Models/CatalogueItemExternalLink.swift | 0 .../Classes/OpenAPIs/Models/CatalogueItemImageLink.swift | 0 .../Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift | 0 .../Classes/OpenAPIs/Models/ErrorDocument.swift | 0 .../Classes/OpenAPIs/Models/ErrorObject.swift | 0 .../Classes/OpenAPIs/Models/ErrorObjectSource.swift | 0 .../Classes/OpenAPIs/Models/ExternalLinkMeta.swift | 0 .../Classes/OpenAPIs/Models/ImageLinkMeta.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/Models/Links.swift | 0 .../OpenAPIs/Models/MultiDataRelationshipDoc.swift | 0 .../Classes/OpenAPIs/Models/PlaylistsAttributes.swift | 0 .../Classes/OpenAPIs/Models/PlaylistsExternalLink.swift | 0 .../Classes/OpenAPIs/Models/PlaylistsImageLink.swift | 0 .../Models/PlaylistsItemsRelationshipDocument.swift | 0 .../PlaylistsItemsRelationshipDocumentIncludedInner.swift | 0 .../OpenAPIs/Models/PlaylistsMultiDataDocument.swift | 0 .../Models/PlaylistsMultiDataDocumentIncludedInner.swift | 0 .../Models/PlaylistsOwnersRelationshipDocument.swift | 0 ...PlaylistsOwnersRelationshipDocumentIncludedInner.swift | 0 .../OpenAPIs/Models/PlaylistsRelationshipDocument.swift | 0 .../PlaylistsRelationshipDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/PlaylistsRelationships.swift | 0 .../Classes/OpenAPIs/Models/PlaylistsResource.swift | 0 .../OpenAPIs/Models/PlaylistsSingleDataDocument.swift | 0 .../Classes/OpenAPIs/Models/PromptColors.swift | 0 .../Classes/OpenAPIs/Models/ProvidersAttributes.swift | 0 .../OpenAPIs/Models/ProvidersMultiDataDocument.swift | 0 .../OpenAPIs/Models/ProvidersRelationshipDocument.swift | 0 .../ProvidersRelationshipDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/ProvidersResource.swift | 0 .../OpenAPIs/Models/ProvidersSingleDataDocument.swift | 0 .../Classes/OpenAPIs/Models/ResourceIdentifier.swift | 0 .../Classes/OpenAPIs/Models/SearchResultsAttributes.swift | 0 .../OpenAPIs/Models/SearchResultsRelationships.swift | 0 .../Classes/OpenAPIs/Models/SearchResultsResource.swift | 0 .../OpenAPIs/Models/SearchResultsSingleDataDocument.swift | 0 .../SearchResultsSingleDataDocumentIncludedInner.swift | 0 .../Models/SearchResultsTopHitsRelationshipDocument.swift | 0 ...hResultsTopHitsRelationshipDocumentIncludedInner.swift | 0 .../OpenAPIs/Models/SingletonDataRelationshipDoc.swift | 0 .../Classes/OpenAPIs/Models/TracksAttributes.swift | 0 .../Classes/OpenAPIs/Models/TracksMultiDataDocument.swift | 0 .../Models/TracksMultiDataDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/TracksRelationships.swift | 0 .../OpenAPIs/Models/TracksRelationshipsDocument.swift | 0 .../Models/TracksRelationshipsDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/TracksResource.swift | 0 .../OpenAPIs/Models/TracksSingleDataDocument.swift | 0 ...UpdateUserPublicProfilePicksRelationshipDocument.swift | 0 .../OpenAPIs/Models/UserEntitlementsAttributes.swift | 0 .../Models/UserEntitlementsRelationshipDocument.swift | 0 ...serEntitlementsRelationshipDocumentIncludedInner.swift | 0 .../OpenAPIs/Models/UserEntitlementsResource.swift | 0 .../Models/UserEntitlementsSingleDataDocument.swift | 0 .../Models/UserPublicProfilePicksAttributes.swift | 0 .../UserPublicProfilePicksItemRelationshipDocument.swift | 0 ...rofilePicksItemRelationshipDocumentIncludedInner.swift | 0 .../Models/UserPublicProfilePicksMultiDataDocument.swift | 0 ...PublicProfilePicksMultiDataDocumentIncludedInner.swift | 0 .../UserPublicProfilePicksRelationshipDocument.swift | 0 ...licProfilePicksRelationshipDocumentIncludedInner.swift | 0 .../Models/UserPublicProfilePicksRelationships.swift | 0 .../OpenAPIs/Models/UserPublicProfilePicksResource.swift | 0 .../OpenAPIs/Models/UserPublicProfilesAttributes.swift | 0 .../OpenAPIs/Models/UserPublicProfilesExternalLink.swift | 0 .../Models/UserPublicProfilesExternalLinkMeta.swift | 0 .../OpenAPIs/Models/UserPublicProfilesImageLink.swift | 0 .../Models/UserPublicProfilesMultiDataDocument.swift | 0 ...UserPublicProfilesMultiDataDocumentIncludedInner.swift | 0 .../Models/UserPublicProfilesRelationshipDocument.swift | 0 ...rPublicProfilesRelationshipDocumentIncludedInner.swift | 0 .../OpenAPIs/Models/UserPublicProfilesRelationships.swift | 0 .../OpenAPIs/Models/UserPublicProfilesResource.swift | 0 .../Models/UserPublicProfilesSingleDataDocument.swift | 0 .../Models/UserRecommendationsMultiDataDocument.swift | 0 ...serRecommendationsMultiDataDocumentIncludedInner.swift | 0 .../Models/UserRecommendationsRelationships.swift | 0 .../OpenAPIs/Models/UserRecommendationsResource.swift | 0 .../Models/UserRecommendationsSingleDataDocument.swift | 0 .../Classes/OpenAPIs/Models/UsersAttributes.swift | 0 .../Classes/OpenAPIs/Models/UsersMultiDataDocument.swift | 0 .../Models/UsersMultiDataDocumentIncludedInner.swift | 0 .../Models/UsersRecommendationsRelationshipDocument.swift | 0 ...RecommendationsRelationshipDocumentIncludedInner.swift | 0 .../OpenAPIs/Models/UsersRelationshipDocument.swift | 0 .../Models/UsersRelationshipDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/UsersRelationships.swift | 0 .../Classes/OpenAPIs/Models/UsersResource.swift | 0 .../Classes/OpenAPIs/Models/UsersSingleDataDocument.swift | 0 .../Classes/OpenAPIs/Models/VideoLinkMeta.swift | 0 .../Classes/OpenAPIs/Models/VideosAttributes.swift | 0 .../Classes/OpenAPIs/Models/VideosMultiDataDocument.swift | 0 .../Models/VideosMultiDataDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/VideosRelationships.swift | 0 .../OpenAPIs/Models/VideosRelationshipsDocument.swift | 0 .../Models/VideosRelationshipsDocumentIncludedInner.swift | 0 .../Classes/OpenAPIs/Models/VideosResource.swift | 0 .../OpenAPIs/Models/VideosSingleDataDocument.swift | 0 .../Classes/OpenAPIs/OpenISO8601DateFormatter.swift | 0 .../Classes/OpenAPIs/SynchronizedDictionary.swift | 0 .../Classes/OpenAPIs/URLSessionImplementations.swift | 0 .../OpenAPIClient/Classes/OpenAPIs/Validation.swift | 0 Sources/{API => TidalAPI}/Generated/README.md | 0 Sources/{API => TidalAPI}/Generated/docs/AlbumsAPI.md | 0 .../{API => TidalAPI}/Generated/docs/AlbumsAttributes.md | 0 .../Generated/docs/AlbumsItemResourceIdentifier.md | 0 .../Generated/docs/AlbumsItemResourceIdentifierMeta.md | 0 .../Generated/docs/AlbumsItemsRelationship.md | 0 .../Generated/docs/AlbumsItemsRelationshipDocument.md | 0 .../docs/AlbumsItemsRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/AlbumsMultiDataDocument.md | 0 .../docs/AlbumsMultiDataDocumentIncludedInner.md | 0 .../Generated/docs/AlbumsRelationshipDocument.md | 0 .../docs/AlbumsRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/AlbumsRelationships.md | 0 .../{API => TidalAPI}/Generated/docs/AlbumsResource.md | 0 .../Generated/docs/AlbumsSingleDataDocument.md | 0 Sources/{API => TidalAPI}/Generated/docs/ArtistsAPI.md | 0 .../{API => TidalAPI}/Generated/docs/ArtistsAttributes.md | 0 .../Generated/docs/ArtistsMultiDataDocument.md | 0 .../docs/ArtistsMultiDataDocumentIncludedInner.md | 0 .../Generated/docs/ArtistsRelationshipDocument.md | 0 .../docs/ArtistsRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/ArtistsRelationships.md | 0 .../{API => TidalAPI}/Generated/docs/ArtistsResource.md | 0 .../Generated/docs/ArtistsSingleDataDocument.md | 0 .../Generated/docs/ArtistsTrackProvidersRelationship.md | 0 .../docs/ArtistsTrackProvidersRelationshipDocument.md | 0 .../docs/ArtistsTrackProvidersResourceIdentifier.md | 0 .../docs/ArtistsTrackProvidersResourceIdentifierMeta.md | 0 .../Generated/docs/CatalogueItemExternalLink.md | 0 .../Generated/docs/CatalogueItemImageLink.md | 0 .../Generated/docs/CatalogueItemVideoLink.md | 0 Sources/{API => TidalAPI}/Generated/docs/ErrorDocument.md | 0 Sources/{API => TidalAPI}/Generated/docs/ErrorObject.md | 0 .../{API => TidalAPI}/Generated/docs/ErrorObjectSource.md | 0 .../{API => TidalAPI}/Generated/docs/ExternalLinkMeta.md | 0 Sources/{API => TidalAPI}/Generated/docs/ImageLinkMeta.md | 0 Sources/{API => TidalAPI}/Generated/docs/Links.md | 0 .../Generated/docs/MultiDataRelationshipDoc.md | 0 Sources/{API => TidalAPI}/Generated/docs/PlaylistsAPI.md | 0 .../Generated/docs/PlaylistsAttributes.md | 0 .../Generated/docs/PlaylistsExternalLink.md | 0 .../Generated/docs/PlaylistsImageLink.md | 0 .../Generated/docs/PlaylistsItemsRelationshipDocument.md | 0 .../PlaylistsItemsRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/PlaylistsMultiDataDocument.md | 0 .../docs/PlaylistsMultiDataDocumentIncludedInner.md | 0 .../Generated/docs/PlaylistsOwnersRelationshipDocument.md | 0 .../PlaylistsOwnersRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/PlaylistsRelationshipDocument.md | 0 .../docs/PlaylistsRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/PlaylistsRelationships.md | 0 .../{API => TidalAPI}/Generated/docs/PlaylistsResource.md | 0 .../Generated/docs/PlaylistsSingleDataDocument.md | 0 Sources/{API => TidalAPI}/Generated/docs/PromptColors.md | 0 Sources/{API => TidalAPI}/Generated/docs/ProvidersAPI.md | 0 .../Generated/docs/ProvidersAttributes.md | 0 .../Generated/docs/ProvidersMultiDataDocument.md | 0 .../Generated/docs/ProvidersRelationshipDocument.md | 0 .../docs/ProvidersRelationshipDocumentIncludedInner.md | 0 .../{API => TidalAPI}/Generated/docs/ProvidersResource.md | 0 .../Generated/docs/ProvidersSingleDataDocument.md | 0 .../Generated/docs/ResourceIdentifier.md | 0 .../{API => TidalAPI}/Generated/docs/SearchResultsAPI.md | 0 .../Generated/docs/SearchResultsAttributes.md | 0 .../Generated/docs/SearchResultsRelationships.md | 0 .../Generated/docs/SearchResultsResource.md | 0 .../Generated/docs/SearchResultsSingleDataDocument.md | 0 .../docs/SearchResultsSingleDataDocumentIncludedInner.md | 0 .../docs/SearchResultsTopHitsRelationshipDocument.md | 0 ...archResultsTopHitsRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/SingletonDataRelationshipDoc.md | 0 Sources/{API => TidalAPI}/Generated/docs/TracksAPI.md | 0 .../{API => TidalAPI}/Generated/docs/TracksAttributes.md | 0 .../Generated/docs/TracksMultiDataDocument.md | 0 .../docs/TracksMultiDataDocumentIncludedInner.md | 0 .../Generated/docs/TracksRelationships.md | 0 .../Generated/docs/TracksRelationshipsDocument.md | 0 .../docs/TracksRelationshipsDocumentIncludedInner.md | 0 .../{API => TidalAPI}/Generated/docs/TracksResource.md | 0 .../Generated/docs/TracksSingleDataDocument.md | 0 .../UpdateUserPublicProfilePicksRelationshipDocument.md | 0 .../Generated/docs/UserEntitlementsAPI.md | 0 .../Generated/docs/UserEntitlementsAttributes.md | 0 .../docs/UserEntitlementsRelationshipDocument.md | 0 .../UserEntitlementsRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/UserEntitlementsResource.md | 0 .../Generated/docs/UserEntitlementsSingleDataDocument.md | 0 .../Generated/docs/UserPublicProfilePicksAPI.md | 0 .../Generated/docs/UserPublicProfilePicksAttributes.md | 0 .../UserPublicProfilePicksItemRelationshipDocument.md | 0 ...icProfilePicksItemRelationshipDocumentIncludedInner.md | 0 .../docs/UserPublicProfilePicksMultiDataDocument.md | 0 ...serPublicProfilePicksMultiDataDocumentIncludedInner.md | 0 .../docs/UserPublicProfilePicksRelationshipDocument.md | 0 ...PublicProfilePicksRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/UserPublicProfilePicksRelationships.md | 0 .../Generated/docs/UserPublicProfilePicksResource.md | 0 .../Generated/docs/UserPublicProfilesAPI.md | 0 .../Generated/docs/UserPublicProfilesAttributes.md | 0 .../Generated/docs/UserPublicProfilesExternalLink.md | 0 .../Generated/docs/UserPublicProfilesExternalLinkMeta.md | 0 .../Generated/docs/UserPublicProfilesImageLink.md | 0 .../Generated/docs/UserPublicProfilesMultiDataDocument.md | 0 .../UserPublicProfilesMultiDataDocumentIncludedInner.md | 0 .../docs/UserPublicProfilesRelationshipDocument.md | 0 ...UserPublicProfilesRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/UserPublicProfilesRelationships.md | 0 .../Generated/docs/UserPublicProfilesResource.md | 0 .../docs/UserPublicProfilesSingleDataDocument.md | 0 .../Generated/docs/UserRecommendationsAPI.md | 0 .../docs/UserRecommendationsMultiDataDocument.md | 0 .../UserRecommendationsMultiDataDocumentIncludedInner.md | 0 .../Generated/docs/UserRecommendationsRelationships.md | 0 .../Generated/docs/UserRecommendationsResource.md | 0 .../docs/UserRecommendationsSingleDataDocument.md | 0 Sources/{API => TidalAPI}/Generated/docs/UsersAPI.md | 0 .../{API => TidalAPI}/Generated/docs/UsersAttributes.md | 0 .../Generated/docs/UsersMultiDataDocument.md | 0 .../Generated/docs/UsersMultiDataDocumentIncludedInner.md | 0 .../docs/UsersRecommendationsRelationshipDocument.md | 0 ...ersRecommendationsRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/UsersRelationshipDocument.md | 0 .../docs/UsersRelationshipDocumentIncludedInner.md | 0 .../Generated/docs/UsersRelationships.md | 0 Sources/{API => TidalAPI}/Generated/docs/UsersResource.md | 0 .../Generated/docs/UsersSingleDataDocument.md | 0 Sources/{API => TidalAPI}/Generated/docs/VideoLinkMeta.md | 0 Sources/{API => TidalAPI}/Generated/docs/VideosAPI.md | 0 .../{API => TidalAPI}/Generated/docs/VideosAttributes.md | 0 .../Generated/docs/VideosMultiDataDocument.md | 0 .../docs/VideosMultiDataDocumentIncludedInner.md | 0 .../Generated/docs/VideosRelationships.md | 0 .../Generated/docs/VideosRelationshipsDocument.md | 0 .../docs/VideosRelationshipsDocumentIncludedInner.md | 0 .../{API => TidalAPI}/Generated/docs/VideosResource.md | 0 .../Generated/docs/VideosSingleDataDocument.md | 0 Sources/{API => TidalAPI}/README.md | 0 Sources/{API => TidalAPI}/Utils/APIError.swift | 0 .../{API => TidalAPI}/Utils/OpenAPIClientAPI+Auth.swift | 0 Sources/{API => TidalAPI}/Utils/RequestHelper.swift | 0 Sources/{API => TidalAPI}/generate_and_clean.sh | 0 310 files changed, 4 insertions(+), 4 deletions(-) rename Sources/{API => TidalAPI}/Config/custom_template/TidalAPI.mustache (100%) rename Sources/{API => TidalAPI}/Config/custom_template/api.mustache (100%) rename Sources/{API => TidalAPI}/Config/input/tidal-catalog-v2-openapi-3.0.json (100%) rename Sources/{API => TidalAPI}/Config/input/tidal-search-v2-openapi-3.0.json (100%) rename Sources/{API => TidalAPI}/Config/input/tidal-user-content-openapi-3.0.json (100%) rename Sources/{API => TidalAPI}/Config/input/tidal-user-v2-openapi-3.0.json (100%) rename Sources/{API => TidalAPI}/Config/openapi-config.yml (100%) rename Sources/{API => TidalAPI}/Generated/.openapi-generator/FILES (100%) rename Sources/{API => TidalAPI}/Generated/.openapi-generator/VERSION (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift (100%) rename Sources/{API => TidalAPI}/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift (100%) rename Sources/{API => TidalAPI}/Generated/README.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsItemResourceIdentifier.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsItemResourceIdentifierMeta.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsItemsRelationship.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsItemsRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/AlbumsSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsTrackProvidersRelationship.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/CatalogueItemExternalLink.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/CatalogueItemImageLink.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/CatalogueItemVideoLink.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ErrorDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ErrorObject.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ErrorObjectSource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ExternalLinkMeta.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ImageLinkMeta.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/Links.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/MultiDataRelationshipDoc.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsExternalLink.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsImageLink.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsItemsRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsOwnersRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PlaylistsSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/PromptColors.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ProvidersAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ProvidersAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ProvidersMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ProvidersRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ProvidersResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ProvidersSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/ResourceIdentifier.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SearchResultsAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SearchResultsAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SearchResultsRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SearchResultsResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SearchResultsSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SearchResultsTopHitsRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/SingletonDataRelationshipDoc.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksRelationshipsDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksRelationshipsDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/TracksSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserEntitlementsAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserEntitlementsAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserEntitlementsRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserEntitlementsResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserEntitlementsSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilePicksResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesExternalLink.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesExternalLinkMeta.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesImageLink.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserPublicProfilesSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserRecommendationsAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserRecommendationsMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserRecommendationsRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserRecommendationsResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UserRecommendationsSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersRecommendationsRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersRelationshipDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersRelationshipDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/UsersSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideoLinkMeta.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosAPI.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosAttributes.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosMultiDataDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosMultiDataDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosRelationships.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosRelationshipsDocument.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosRelationshipsDocumentIncludedInner.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosResource.md (100%) rename Sources/{API => TidalAPI}/Generated/docs/VideosSingleDataDocument.md (100%) rename Sources/{API => TidalAPI}/README.md (100%) rename Sources/{API => TidalAPI}/Utils/APIError.swift (100%) rename Sources/{API => TidalAPI}/Utils/OpenAPIClientAPI+Auth.swift (100%) rename Sources/{API => TidalAPI}/Utils/RequestHelper.swift (100%) rename Sources/{API => TidalAPI}/generate_and_clean.sh (100%) diff --git a/Package.swift b/Package.swift index c87e0e17..f8a5cfca 100644 --- a/Package.swift +++ b/Package.swift @@ -35,8 +35,8 @@ let package = Package( targets: ["Common"] ), .library( - name: "API", - targets: ["API"] + name: "TidalAPI", + targets: ["TidalAPI"] ), ], dependencies: [ @@ -71,7 +71,7 @@ let package = Package( ] ), .target( - name: "API", + name: "TidalAPI", dependencies: [ .AnyCodable, ], @@ -176,7 +176,7 @@ extension Target.Dependency { static let template = byName(name: "Template") static let eventProducer = byName(name: "EventProducer") static let catalogue = byName(name: "Catalogue") - static let api = byName(name: "API") + static let tidalAPI = byName(name: "TidalAPI") static let common = byName(name: "Common") static let auth = byName(name: "Auth") static let player = byName(name: "Player") diff --git a/Sources/API/Config/custom_template/TidalAPI.mustache b/Sources/TidalAPI/Config/custom_template/TidalAPI.mustache similarity index 100% rename from Sources/API/Config/custom_template/TidalAPI.mustache rename to Sources/TidalAPI/Config/custom_template/TidalAPI.mustache diff --git a/Sources/API/Config/custom_template/api.mustache b/Sources/TidalAPI/Config/custom_template/api.mustache similarity index 100% rename from Sources/API/Config/custom_template/api.mustache rename to Sources/TidalAPI/Config/custom_template/api.mustache diff --git a/Sources/API/Config/input/tidal-catalog-v2-openapi-3.0.json b/Sources/TidalAPI/Config/input/tidal-catalog-v2-openapi-3.0.json similarity index 100% rename from Sources/API/Config/input/tidal-catalog-v2-openapi-3.0.json rename to Sources/TidalAPI/Config/input/tidal-catalog-v2-openapi-3.0.json diff --git a/Sources/API/Config/input/tidal-search-v2-openapi-3.0.json b/Sources/TidalAPI/Config/input/tidal-search-v2-openapi-3.0.json similarity index 100% rename from Sources/API/Config/input/tidal-search-v2-openapi-3.0.json rename to Sources/TidalAPI/Config/input/tidal-search-v2-openapi-3.0.json diff --git a/Sources/API/Config/input/tidal-user-content-openapi-3.0.json b/Sources/TidalAPI/Config/input/tidal-user-content-openapi-3.0.json similarity index 100% rename from Sources/API/Config/input/tidal-user-content-openapi-3.0.json rename to Sources/TidalAPI/Config/input/tidal-user-content-openapi-3.0.json diff --git a/Sources/API/Config/input/tidal-user-v2-openapi-3.0.json b/Sources/TidalAPI/Config/input/tidal-user-v2-openapi-3.0.json similarity index 100% rename from Sources/API/Config/input/tidal-user-v2-openapi-3.0.json rename to Sources/TidalAPI/Config/input/tidal-user-v2-openapi-3.0.json diff --git a/Sources/API/Config/openapi-config.yml b/Sources/TidalAPI/Config/openapi-config.yml similarity index 100% rename from Sources/API/Config/openapi-config.yml rename to Sources/TidalAPI/Config/openapi-config.yml diff --git a/Sources/API/Generated/.openapi-generator/FILES b/Sources/TidalAPI/Generated/.openapi-generator/FILES similarity index 100% rename from Sources/API/Generated/.openapi-generator/FILES rename to Sources/TidalAPI/Generated/.openapi-generator/FILES diff --git a/Sources/API/Generated/.openapi-generator/VERSION b/Sources/TidalAPI/Generated/.openapi-generator/VERSION similarity index 100% rename from Sources/API/Generated/.openapi-generator/VERSION rename to Sources/TidalAPI/Generated/.openapi-generator/VERSION diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIHelper.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPI.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/CodableHelper.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Configuration.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Extensions.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/JSONDataEncoding.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/JSONEncodingHelper.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifier.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemResourceIdentifierMeta.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationship.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsItemsRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/AlbumsSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationship.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifier.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ArtistsTrackProvidersResourceIdentifierMeta.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemExternalLink.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemImageLink.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/CatalogueItemVideoLink.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObject.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ErrorObjectSource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ExternalLinkMeta.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ImageLinkMeta.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/Links.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/MultiDataRelationshipDoc.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsExternalLink.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsImageLink.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsItemsRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsOwnersRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PlaylistsSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/PromptColors.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ProvidersSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/ResourceIdentifier.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsSingleDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SearchResultsTopHitsRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/SingletonDataRelationshipDoc.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksRelationshipsDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/TracksSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UpdateUserPublicProfilePicksRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserEntitlementsSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilePicksResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLink.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesExternalLinkMeta.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesImageLink.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserPublicProfilesSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UserRecommendationsSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRecommendationsRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationshipDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/UsersSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideoLinkMeta.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosAttributes.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosMultiDataDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationships.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosRelationshipsDocumentIncludedInner.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosResource.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Models/VideosSingleDataDocument.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/OpenISO8601DateFormatter.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/SynchronizedDictionary.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/URLSessionImplementations.swift diff --git a/Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift similarity index 100% rename from Sources/API/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift rename to Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/Validation.swift diff --git a/Sources/API/Generated/README.md b/Sources/TidalAPI/Generated/README.md similarity index 100% rename from Sources/API/Generated/README.md rename to Sources/TidalAPI/Generated/README.md diff --git a/Sources/API/Generated/docs/AlbumsAPI.md b/Sources/TidalAPI/Generated/docs/AlbumsAPI.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsAPI.md rename to Sources/TidalAPI/Generated/docs/AlbumsAPI.md diff --git a/Sources/API/Generated/docs/AlbumsAttributes.md b/Sources/TidalAPI/Generated/docs/AlbumsAttributes.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsAttributes.md rename to Sources/TidalAPI/Generated/docs/AlbumsAttributes.md diff --git a/Sources/API/Generated/docs/AlbumsItemResourceIdentifier.md b/Sources/TidalAPI/Generated/docs/AlbumsItemResourceIdentifier.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsItemResourceIdentifier.md rename to Sources/TidalAPI/Generated/docs/AlbumsItemResourceIdentifier.md diff --git a/Sources/API/Generated/docs/AlbumsItemResourceIdentifierMeta.md b/Sources/TidalAPI/Generated/docs/AlbumsItemResourceIdentifierMeta.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsItemResourceIdentifierMeta.md rename to Sources/TidalAPI/Generated/docs/AlbumsItemResourceIdentifierMeta.md diff --git a/Sources/API/Generated/docs/AlbumsItemsRelationship.md b/Sources/TidalAPI/Generated/docs/AlbumsItemsRelationship.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsItemsRelationship.md rename to Sources/TidalAPI/Generated/docs/AlbumsItemsRelationship.md diff --git a/Sources/API/Generated/docs/AlbumsItemsRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/AlbumsItemsRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsItemsRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/AlbumsItemsRelationshipDocument.md diff --git a/Sources/API/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/AlbumsItemsRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/AlbumsMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/AlbumsMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/AlbumsMultiDataDocument.md diff --git a/Sources/API/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/AlbumsMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/AlbumsRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/AlbumsRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/AlbumsRelationshipDocument.md diff --git a/Sources/API/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/AlbumsRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/AlbumsRelationships.md b/Sources/TidalAPI/Generated/docs/AlbumsRelationships.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsRelationships.md rename to Sources/TidalAPI/Generated/docs/AlbumsRelationships.md diff --git a/Sources/API/Generated/docs/AlbumsResource.md b/Sources/TidalAPI/Generated/docs/AlbumsResource.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsResource.md rename to Sources/TidalAPI/Generated/docs/AlbumsResource.md diff --git a/Sources/API/Generated/docs/AlbumsSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/AlbumsSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/AlbumsSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/AlbumsSingleDataDocument.md diff --git a/Sources/API/Generated/docs/ArtistsAPI.md b/Sources/TidalAPI/Generated/docs/ArtistsAPI.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsAPI.md rename to Sources/TidalAPI/Generated/docs/ArtistsAPI.md diff --git a/Sources/API/Generated/docs/ArtistsAttributes.md b/Sources/TidalAPI/Generated/docs/ArtistsAttributes.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsAttributes.md rename to Sources/TidalAPI/Generated/docs/ArtistsAttributes.md diff --git a/Sources/API/Generated/docs/ArtistsMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/ArtistsMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/ArtistsMultiDataDocument.md diff --git a/Sources/API/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/ArtistsMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/ArtistsRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/ArtistsRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/ArtistsRelationshipDocument.md diff --git a/Sources/API/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/ArtistsRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/ArtistsRelationships.md b/Sources/TidalAPI/Generated/docs/ArtistsRelationships.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsRelationships.md rename to Sources/TidalAPI/Generated/docs/ArtistsRelationships.md diff --git a/Sources/API/Generated/docs/ArtistsResource.md b/Sources/TidalAPI/Generated/docs/ArtistsResource.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsResource.md rename to Sources/TidalAPI/Generated/docs/ArtistsResource.md diff --git a/Sources/API/Generated/docs/ArtistsSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/ArtistsSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/ArtistsSingleDataDocument.md diff --git a/Sources/API/Generated/docs/ArtistsTrackProvidersRelationship.md b/Sources/TidalAPI/Generated/docs/ArtistsTrackProvidersRelationship.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsTrackProvidersRelationship.md rename to Sources/TidalAPI/Generated/docs/ArtistsTrackProvidersRelationship.md diff --git a/Sources/API/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/ArtistsTrackProvidersRelationshipDocument.md diff --git a/Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md b/Sources/TidalAPI/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md rename to Sources/TidalAPI/Generated/docs/ArtistsTrackProvidersResourceIdentifier.md diff --git a/Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md b/Sources/TidalAPI/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md similarity index 100% rename from Sources/API/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md rename to Sources/TidalAPI/Generated/docs/ArtistsTrackProvidersResourceIdentifierMeta.md diff --git a/Sources/API/Generated/docs/CatalogueItemExternalLink.md b/Sources/TidalAPI/Generated/docs/CatalogueItemExternalLink.md similarity index 100% rename from Sources/API/Generated/docs/CatalogueItemExternalLink.md rename to Sources/TidalAPI/Generated/docs/CatalogueItemExternalLink.md diff --git a/Sources/API/Generated/docs/CatalogueItemImageLink.md b/Sources/TidalAPI/Generated/docs/CatalogueItemImageLink.md similarity index 100% rename from Sources/API/Generated/docs/CatalogueItemImageLink.md rename to Sources/TidalAPI/Generated/docs/CatalogueItemImageLink.md diff --git a/Sources/API/Generated/docs/CatalogueItemVideoLink.md b/Sources/TidalAPI/Generated/docs/CatalogueItemVideoLink.md similarity index 100% rename from Sources/API/Generated/docs/CatalogueItemVideoLink.md rename to Sources/TidalAPI/Generated/docs/CatalogueItemVideoLink.md diff --git a/Sources/API/Generated/docs/ErrorDocument.md b/Sources/TidalAPI/Generated/docs/ErrorDocument.md similarity index 100% rename from Sources/API/Generated/docs/ErrorDocument.md rename to Sources/TidalAPI/Generated/docs/ErrorDocument.md diff --git a/Sources/API/Generated/docs/ErrorObject.md b/Sources/TidalAPI/Generated/docs/ErrorObject.md similarity index 100% rename from Sources/API/Generated/docs/ErrorObject.md rename to Sources/TidalAPI/Generated/docs/ErrorObject.md diff --git a/Sources/API/Generated/docs/ErrorObjectSource.md b/Sources/TidalAPI/Generated/docs/ErrorObjectSource.md similarity index 100% rename from Sources/API/Generated/docs/ErrorObjectSource.md rename to Sources/TidalAPI/Generated/docs/ErrorObjectSource.md diff --git a/Sources/API/Generated/docs/ExternalLinkMeta.md b/Sources/TidalAPI/Generated/docs/ExternalLinkMeta.md similarity index 100% rename from Sources/API/Generated/docs/ExternalLinkMeta.md rename to Sources/TidalAPI/Generated/docs/ExternalLinkMeta.md diff --git a/Sources/API/Generated/docs/ImageLinkMeta.md b/Sources/TidalAPI/Generated/docs/ImageLinkMeta.md similarity index 100% rename from Sources/API/Generated/docs/ImageLinkMeta.md rename to Sources/TidalAPI/Generated/docs/ImageLinkMeta.md diff --git a/Sources/API/Generated/docs/Links.md b/Sources/TidalAPI/Generated/docs/Links.md similarity index 100% rename from Sources/API/Generated/docs/Links.md rename to Sources/TidalAPI/Generated/docs/Links.md diff --git a/Sources/API/Generated/docs/MultiDataRelationshipDoc.md b/Sources/TidalAPI/Generated/docs/MultiDataRelationshipDoc.md similarity index 100% rename from Sources/API/Generated/docs/MultiDataRelationshipDoc.md rename to Sources/TidalAPI/Generated/docs/MultiDataRelationshipDoc.md diff --git a/Sources/API/Generated/docs/PlaylistsAPI.md b/Sources/TidalAPI/Generated/docs/PlaylistsAPI.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsAPI.md rename to Sources/TidalAPI/Generated/docs/PlaylistsAPI.md diff --git a/Sources/API/Generated/docs/PlaylistsAttributes.md b/Sources/TidalAPI/Generated/docs/PlaylistsAttributes.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsAttributes.md rename to Sources/TidalAPI/Generated/docs/PlaylistsAttributes.md diff --git a/Sources/API/Generated/docs/PlaylistsExternalLink.md b/Sources/TidalAPI/Generated/docs/PlaylistsExternalLink.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsExternalLink.md rename to Sources/TidalAPI/Generated/docs/PlaylistsExternalLink.md diff --git a/Sources/API/Generated/docs/PlaylistsImageLink.md b/Sources/TidalAPI/Generated/docs/PlaylistsImageLink.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsImageLink.md rename to Sources/TidalAPI/Generated/docs/PlaylistsImageLink.md diff --git a/Sources/API/Generated/docs/PlaylistsItemsRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/PlaylistsItemsRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsItemsRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/PlaylistsItemsRelationshipDocument.md diff --git a/Sources/API/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/PlaylistsItemsRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/PlaylistsMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/PlaylistsMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/PlaylistsMultiDataDocument.md diff --git a/Sources/API/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/PlaylistsMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/PlaylistsOwnersRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/PlaylistsOwnersRelationshipDocument.md diff --git a/Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/PlaylistsOwnersRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/PlaylistsRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/PlaylistsRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/PlaylistsRelationshipDocument.md diff --git a/Sources/API/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/PlaylistsRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/PlaylistsRelationships.md b/Sources/TidalAPI/Generated/docs/PlaylistsRelationships.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsRelationships.md rename to Sources/TidalAPI/Generated/docs/PlaylistsRelationships.md diff --git a/Sources/API/Generated/docs/PlaylistsResource.md b/Sources/TidalAPI/Generated/docs/PlaylistsResource.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsResource.md rename to Sources/TidalAPI/Generated/docs/PlaylistsResource.md diff --git a/Sources/API/Generated/docs/PlaylistsSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/PlaylistsSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/PlaylistsSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/PlaylistsSingleDataDocument.md diff --git a/Sources/API/Generated/docs/PromptColors.md b/Sources/TidalAPI/Generated/docs/PromptColors.md similarity index 100% rename from Sources/API/Generated/docs/PromptColors.md rename to Sources/TidalAPI/Generated/docs/PromptColors.md diff --git a/Sources/API/Generated/docs/ProvidersAPI.md b/Sources/TidalAPI/Generated/docs/ProvidersAPI.md similarity index 100% rename from Sources/API/Generated/docs/ProvidersAPI.md rename to Sources/TidalAPI/Generated/docs/ProvidersAPI.md diff --git a/Sources/API/Generated/docs/ProvidersAttributes.md b/Sources/TidalAPI/Generated/docs/ProvidersAttributes.md similarity index 100% rename from Sources/API/Generated/docs/ProvidersAttributes.md rename to Sources/TidalAPI/Generated/docs/ProvidersAttributes.md diff --git a/Sources/API/Generated/docs/ProvidersMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/ProvidersMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/ProvidersMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/ProvidersMultiDataDocument.md diff --git a/Sources/API/Generated/docs/ProvidersRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/ProvidersRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/ProvidersRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/ProvidersRelationshipDocument.md diff --git a/Sources/API/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/ProvidersRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/ProvidersResource.md b/Sources/TidalAPI/Generated/docs/ProvidersResource.md similarity index 100% rename from Sources/API/Generated/docs/ProvidersResource.md rename to Sources/TidalAPI/Generated/docs/ProvidersResource.md diff --git a/Sources/API/Generated/docs/ProvidersSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/ProvidersSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/ProvidersSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/ProvidersSingleDataDocument.md diff --git a/Sources/API/Generated/docs/ResourceIdentifier.md b/Sources/TidalAPI/Generated/docs/ResourceIdentifier.md similarity index 100% rename from Sources/API/Generated/docs/ResourceIdentifier.md rename to Sources/TidalAPI/Generated/docs/ResourceIdentifier.md diff --git a/Sources/API/Generated/docs/SearchResultsAPI.md b/Sources/TidalAPI/Generated/docs/SearchResultsAPI.md similarity index 100% rename from Sources/API/Generated/docs/SearchResultsAPI.md rename to Sources/TidalAPI/Generated/docs/SearchResultsAPI.md diff --git a/Sources/API/Generated/docs/SearchResultsAttributes.md b/Sources/TidalAPI/Generated/docs/SearchResultsAttributes.md similarity index 100% rename from Sources/API/Generated/docs/SearchResultsAttributes.md rename to Sources/TidalAPI/Generated/docs/SearchResultsAttributes.md diff --git a/Sources/API/Generated/docs/SearchResultsRelationships.md b/Sources/TidalAPI/Generated/docs/SearchResultsRelationships.md similarity index 100% rename from Sources/API/Generated/docs/SearchResultsRelationships.md rename to Sources/TidalAPI/Generated/docs/SearchResultsRelationships.md diff --git a/Sources/API/Generated/docs/SearchResultsResource.md b/Sources/TidalAPI/Generated/docs/SearchResultsResource.md similarity index 100% rename from Sources/API/Generated/docs/SearchResultsResource.md rename to Sources/TidalAPI/Generated/docs/SearchResultsResource.md diff --git a/Sources/API/Generated/docs/SearchResultsSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/SearchResultsSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/SearchResultsSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/SearchResultsSingleDataDocument.md diff --git a/Sources/API/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/SearchResultsSingleDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/SearchResultsTopHitsRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/SearchResultsTopHitsRelationshipDocument.md diff --git a/Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/SearchResultsTopHitsRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/SingletonDataRelationshipDoc.md b/Sources/TidalAPI/Generated/docs/SingletonDataRelationshipDoc.md similarity index 100% rename from Sources/API/Generated/docs/SingletonDataRelationshipDoc.md rename to Sources/TidalAPI/Generated/docs/SingletonDataRelationshipDoc.md diff --git a/Sources/API/Generated/docs/TracksAPI.md b/Sources/TidalAPI/Generated/docs/TracksAPI.md similarity index 100% rename from Sources/API/Generated/docs/TracksAPI.md rename to Sources/TidalAPI/Generated/docs/TracksAPI.md diff --git a/Sources/API/Generated/docs/TracksAttributes.md b/Sources/TidalAPI/Generated/docs/TracksAttributes.md similarity index 100% rename from Sources/API/Generated/docs/TracksAttributes.md rename to Sources/TidalAPI/Generated/docs/TracksAttributes.md diff --git a/Sources/API/Generated/docs/TracksMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/TracksMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/TracksMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/TracksMultiDataDocument.md diff --git a/Sources/API/Generated/docs/TracksMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/TracksMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/TracksMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/TracksMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/TracksRelationships.md b/Sources/TidalAPI/Generated/docs/TracksRelationships.md similarity index 100% rename from Sources/API/Generated/docs/TracksRelationships.md rename to Sources/TidalAPI/Generated/docs/TracksRelationships.md diff --git a/Sources/API/Generated/docs/TracksRelationshipsDocument.md b/Sources/TidalAPI/Generated/docs/TracksRelationshipsDocument.md similarity index 100% rename from Sources/API/Generated/docs/TracksRelationshipsDocument.md rename to Sources/TidalAPI/Generated/docs/TracksRelationshipsDocument.md diff --git a/Sources/API/Generated/docs/TracksRelationshipsDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/TracksRelationshipsDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/TracksRelationshipsDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/TracksRelationshipsDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/TracksResource.md b/Sources/TidalAPI/Generated/docs/TracksResource.md similarity index 100% rename from Sources/API/Generated/docs/TracksResource.md rename to Sources/TidalAPI/Generated/docs/TracksResource.md diff --git a/Sources/API/Generated/docs/TracksSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/TracksSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/TracksSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/TracksSingleDataDocument.md diff --git a/Sources/API/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/UpdateUserPublicProfilePicksRelationshipDocument.md diff --git a/Sources/API/Generated/docs/UserEntitlementsAPI.md b/Sources/TidalAPI/Generated/docs/UserEntitlementsAPI.md similarity index 100% rename from Sources/API/Generated/docs/UserEntitlementsAPI.md rename to Sources/TidalAPI/Generated/docs/UserEntitlementsAPI.md diff --git a/Sources/API/Generated/docs/UserEntitlementsAttributes.md b/Sources/TidalAPI/Generated/docs/UserEntitlementsAttributes.md similarity index 100% rename from Sources/API/Generated/docs/UserEntitlementsAttributes.md rename to Sources/TidalAPI/Generated/docs/UserEntitlementsAttributes.md diff --git a/Sources/API/Generated/docs/UserEntitlementsRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/UserEntitlementsRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserEntitlementsRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/UserEntitlementsRelationshipDocument.md diff --git a/Sources/API/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UserEntitlementsRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UserEntitlementsResource.md b/Sources/TidalAPI/Generated/docs/UserEntitlementsResource.md similarity index 100% rename from Sources/API/Generated/docs/UserEntitlementsResource.md rename to Sources/TidalAPI/Generated/docs/UserEntitlementsResource.md diff --git a/Sources/API/Generated/docs/UserEntitlementsSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/UserEntitlementsSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserEntitlementsSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/UserEntitlementsSingleDataDocument.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksAPI.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksAPI.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksAPI.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksAPI.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksAttributes.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksAttributes.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksAttributes.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksAttributes.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksItemRelationshipDocument.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksItemRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksMultiDataDocument.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksRelationshipDocument.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksRelationships.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksRelationships.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksRelationships.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksRelationships.md diff --git a/Sources/API/Generated/docs/UserPublicProfilePicksResource.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilePicksResource.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilePicksResource.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilePicksResource.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesAPI.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesAPI.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesAPI.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesAPI.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesAttributes.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesAttributes.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesAttributes.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesAttributes.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesExternalLink.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesExternalLink.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesExternalLink.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesExternalLink.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesExternalLinkMeta.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesExternalLinkMeta.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesExternalLinkMeta.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesExternalLinkMeta.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesImageLink.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesImageLink.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesImageLink.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesImageLink.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesMultiDataDocument.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesRelationshipDocument.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesRelationships.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesRelationships.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesRelationships.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesRelationships.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesResource.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesResource.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesResource.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesResource.md diff --git a/Sources/API/Generated/docs/UserPublicProfilesSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/UserPublicProfilesSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserPublicProfilesSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/UserPublicProfilesSingleDataDocument.md diff --git a/Sources/API/Generated/docs/UserRecommendationsAPI.md b/Sources/TidalAPI/Generated/docs/UserRecommendationsAPI.md similarity index 100% rename from Sources/API/Generated/docs/UserRecommendationsAPI.md rename to Sources/TidalAPI/Generated/docs/UserRecommendationsAPI.md diff --git a/Sources/API/Generated/docs/UserRecommendationsMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/UserRecommendationsMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserRecommendationsMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/UserRecommendationsMultiDataDocument.md diff --git a/Sources/API/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UserRecommendationsMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UserRecommendationsRelationships.md b/Sources/TidalAPI/Generated/docs/UserRecommendationsRelationships.md similarity index 100% rename from Sources/API/Generated/docs/UserRecommendationsRelationships.md rename to Sources/TidalAPI/Generated/docs/UserRecommendationsRelationships.md diff --git a/Sources/API/Generated/docs/UserRecommendationsResource.md b/Sources/TidalAPI/Generated/docs/UserRecommendationsResource.md similarity index 100% rename from Sources/API/Generated/docs/UserRecommendationsResource.md rename to Sources/TidalAPI/Generated/docs/UserRecommendationsResource.md diff --git a/Sources/API/Generated/docs/UserRecommendationsSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/UserRecommendationsSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/UserRecommendationsSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/UserRecommendationsSingleDataDocument.md diff --git a/Sources/API/Generated/docs/UsersAPI.md b/Sources/TidalAPI/Generated/docs/UsersAPI.md similarity index 100% rename from Sources/API/Generated/docs/UsersAPI.md rename to Sources/TidalAPI/Generated/docs/UsersAPI.md diff --git a/Sources/API/Generated/docs/UsersAttributes.md b/Sources/TidalAPI/Generated/docs/UsersAttributes.md similarity index 100% rename from Sources/API/Generated/docs/UsersAttributes.md rename to Sources/TidalAPI/Generated/docs/UsersAttributes.md diff --git a/Sources/API/Generated/docs/UsersMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/UsersMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/UsersMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/UsersMultiDataDocument.md diff --git a/Sources/API/Generated/docs/UsersMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UsersMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UsersMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UsersMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UsersRecommendationsRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/UsersRecommendationsRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/UsersRecommendationsRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/UsersRecommendationsRelationshipDocument.md diff --git a/Sources/API/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UsersRecommendationsRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UsersRelationshipDocument.md b/Sources/TidalAPI/Generated/docs/UsersRelationshipDocument.md similarity index 100% rename from Sources/API/Generated/docs/UsersRelationshipDocument.md rename to Sources/TidalAPI/Generated/docs/UsersRelationshipDocument.md diff --git a/Sources/API/Generated/docs/UsersRelationshipDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/UsersRelationshipDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/UsersRelationshipDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/UsersRelationshipDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/UsersRelationships.md b/Sources/TidalAPI/Generated/docs/UsersRelationships.md similarity index 100% rename from Sources/API/Generated/docs/UsersRelationships.md rename to Sources/TidalAPI/Generated/docs/UsersRelationships.md diff --git a/Sources/API/Generated/docs/UsersResource.md b/Sources/TidalAPI/Generated/docs/UsersResource.md similarity index 100% rename from Sources/API/Generated/docs/UsersResource.md rename to Sources/TidalAPI/Generated/docs/UsersResource.md diff --git a/Sources/API/Generated/docs/UsersSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/UsersSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/UsersSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/UsersSingleDataDocument.md diff --git a/Sources/API/Generated/docs/VideoLinkMeta.md b/Sources/TidalAPI/Generated/docs/VideoLinkMeta.md similarity index 100% rename from Sources/API/Generated/docs/VideoLinkMeta.md rename to Sources/TidalAPI/Generated/docs/VideoLinkMeta.md diff --git a/Sources/API/Generated/docs/VideosAPI.md b/Sources/TidalAPI/Generated/docs/VideosAPI.md similarity index 100% rename from Sources/API/Generated/docs/VideosAPI.md rename to Sources/TidalAPI/Generated/docs/VideosAPI.md diff --git a/Sources/API/Generated/docs/VideosAttributes.md b/Sources/TidalAPI/Generated/docs/VideosAttributes.md similarity index 100% rename from Sources/API/Generated/docs/VideosAttributes.md rename to Sources/TidalAPI/Generated/docs/VideosAttributes.md diff --git a/Sources/API/Generated/docs/VideosMultiDataDocument.md b/Sources/TidalAPI/Generated/docs/VideosMultiDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/VideosMultiDataDocument.md rename to Sources/TidalAPI/Generated/docs/VideosMultiDataDocument.md diff --git a/Sources/API/Generated/docs/VideosMultiDataDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/VideosMultiDataDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/VideosMultiDataDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/VideosMultiDataDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/VideosRelationships.md b/Sources/TidalAPI/Generated/docs/VideosRelationships.md similarity index 100% rename from Sources/API/Generated/docs/VideosRelationships.md rename to Sources/TidalAPI/Generated/docs/VideosRelationships.md diff --git a/Sources/API/Generated/docs/VideosRelationshipsDocument.md b/Sources/TidalAPI/Generated/docs/VideosRelationshipsDocument.md similarity index 100% rename from Sources/API/Generated/docs/VideosRelationshipsDocument.md rename to Sources/TidalAPI/Generated/docs/VideosRelationshipsDocument.md diff --git a/Sources/API/Generated/docs/VideosRelationshipsDocumentIncludedInner.md b/Sources/TidalAPI/Generated/docs/VideosRelationshipsDocumentIncludedInner.md similarity index 100% rename from Sources/API/Generated/docs/VideosRelationshipsDocumentIncludedInner.md rename to Sources/TidalAPI/Generated/docs/VideosRelationshipsDocumentIncludedInner.md diff --git a/Sources/API/Generated/docs/VideosResource.md b/Sources/TidalAPI/Generated/docs/VideosResource.md similarity index 100% rename from Sources/API/Generated/docs/VideosResource.md rename to Sources/TidalAPI/Generated/docs/VideosResource.md diff --git a/Sources/API/Generated/docs/VideosSingleDataDocument.md b/Sources/TidalAPI/Generated/docs/VideosSingleDataDocument.md similarity index 100% rename from Sources/API/Generated/docs/VideosSingleDataDocument.md rename to Sources/TidalAPI/Generated/docs/VideosSingleDataDocument.md diff --git a/Sources/API/README.md b/Sources/TidalAPI/README.md similarity index 100% rename from Sources/API/README.md rename to Sources/TidalAPI/README.md diff --git a/Sources/API/Utils/APIError.swift b/Sources/TidalAPI/Utils/APIError.swift similarity index 100% rename from Sources/API/Utils/APIError.swift rename to Sources/TidalAPI/Utils/APIError.swift diff --git a/Sources/API/Utils/OpenAPIClientAPI+Auth.swift b/Sources/TidalAPI/Utils/OpenAPIClientAPI+Auth.swift similarity index 100% rename from Sources/API/Utils/OpenAPIClientAPI+Auth.swift rename to Sources/TidalAPI/Utils/OpenAPIClientAPI+Auth.swift diff --git a/Sources/API/Utils/RequestHelper.swift b/Sources/TidalAPI/Utils/RequestHelper.swift similarity index 100% rename from Sources/API/Utils/RequestHelper.swift rename to Sources/TidalAPI/Utils/RequestHelper.swift diff --git a/Sources/API/generate_and_clean.sh b/Sources/TidalAPI/generate_and_clean.sh similarity index 100% rename from Sources/API/generate_and_clean.sh rename to Sources/TidalAPI/generate_and_clean.sh From 18d305803934e7c093a56ea32fdd424a372f9769 Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Tue, 22 Oct 2024 12:40:28 +0200 Subject: [PATCH 09/11] added .auth dependency for TidalAPI --- Package.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/Package.swift b/Package.swift index f8a5cfca..0491d170 100644 --- a/Package.swift +++ b/Package.swift @@ -74,6 +74,7 @@ let package = Package( name: "TidalAPI", dependencies: [ .AnyCodable, + .auth ], plugins: [ .plugin(name: "SwiftLint", package: "SwiftLintPlugin"), From c1bd99e404e612248e8ea2d789a6240b0ca031ff Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Tue, 22 Oct 2024 16:04:11 +0200 Subject: [PATCH 10/11] adjusted template to have proper names in documentation --- Sources/TidalAPI/Config/custom_template/TidalAPI.mustache | 2 +- .../OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift | 2 +- .../OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift | 2 +- .../OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift | 2 +- .../OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift | 2 +- .../Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift | 2 +- .../OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift | 2 +- .../Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift | 2 +- .../Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift | 2 +- .../Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift | 2 +- .../Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift | 2 +- .../OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift | 2 +- .../OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Sources/TidalAPI/Config/custom_template/TidalAPI.mustache b/Sources/TidalAPI/Config/custom_template/TidalAPI.mustache index 41accd60..b85c76c6 100644 --- a/Sources/TidalAPI/Config/custom_template/TidalAPI.mustache +++ b/Sources/TidalAPI/Config/custom_template/TidalAPI.mustache @@ -10,7 +10,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await {{classname}}.getResource() +/// let dataDocument = try await {{classname}}Tidal.getResource() /// ``` public enum {{classname}}Tidal { {{#operation}} diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift index 1396faf1..d3769dde 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/AlbumsAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await AlbumsAPI.getResource() +/// let dataDocument = try await AlbumsAPITidal.getResource() /// ``` public enum AlbumsAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift index ffd60e0d..6ca143b9 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ArtistsAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await ArtistsAPI.getResource() +/// let dataDocument = try await ArtistsAPITidal.getResource() /// ``` public enum ArtistsAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift index 8eb96273..777a2219 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/PlaylistsAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await PlaylistsAPI.getResource() +/// let dataDocument = try await PlaylistsAPITidal.getResource() /// ``` public enum PlaylistsAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift index c1afffdf..97cb636b 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/ProvidersAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await ProvidersAPI.getResource() +/// let dataDocument = try await ProvidersAPITidal.getResource() /// ``` public enum ProvidersAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift index 1bb033dc..9eba6bce 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/SearchResultsAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await SearchResultsAPI.getResource() +/// let dataDocument = try await SearchResultsAPITidal.getResource() /// ``` public enum SearchResultsAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift index ef86cba8..90457a05 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/TracksAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await TracksAPI.getResource() +/// let dataDocument = try await TracksAPITidal.getResource() /// ``` public enum TracksAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift index 5af6ccb1..1448388d 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserEntitlementsAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await UserEntitlementsAPI.getResource() +/// let dataDocument = try await UserEntitlementsAPITidal.getResource() /// ``` public enum UserEntitlementsAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift index 843bbf61..a9edf49e 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilePicksAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await UserPublicProfilePicksAPI.getResource() +/// let dataDocument = try await UserPublicProfilePicksAPITidal.getResource() /// ``` public enum UserPublicProfilePicksAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift index eb83b9d9..8dd7aceb 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserPublicProfilesAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await UserPublicProfilesAPI.getResource() +/// let dataDocument = try await UserPublicProfilesAPITidal.getResource() /// ``` public enum UserPublicProfilesAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift index ab178a12..4a77c3db 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UserRecommendationsAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await UserRecommendationsAPI.getResource() +/// let dataDocument = try await UserRecommendationsAPITidal.getResource() /// ``` public enum UserRecommendationsAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift index d6b10d5f..3ead3973 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/UsersAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await UsersAPI.getResource() +/// let dataDocument = try await UsersAPITidal.getResource() /// ``` public enum UsersAPITidal { diff --git a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift index 23386861..c5db1157 100644 --- a/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift +++ b/Sources/TidalAPI/Generated/OpenAPIClient/Classes/OpenAPIs/APIs/VideosAPITidal.swift @@ -9,7 +9,7 @@ import AnyCodable /// Usage example: /// ```swift /// OpenAPIClientAPI.credentialsProvider = TidalAuth.shared -/// let dataDocument = try await VideosAPI.getResource() +/// let dataDocument = try await VideosAPITidal.getResource() /// ``` public enum VideosAPITidal { From 348235f4cc5470fa03bb8450c375fabb752a6dfa Mon Sep 17 00:00:00 2001 From: Evgenii Kononenko Date: Wed, 23 Oct 2024 12:38:10 +0200 Subject: [PATCH 11/11] renamed APIError to TidalAPIError --- Sources/TidalAPI/Utils/RequestHelper.swift | 14 +++++++------- .../Utils/{APIError.swift => TidalAPIError.swift} | 4 ++-- 2 files changed, 9 insertions(+), 9 deletions(-) rename Sources/TidalAPI/Utils/{APIError.swift => TidalAPIError.swift} (93%) diff --git a/Sources/TidalAPI/Utils/RequestHelper.swift b/Sources/TidalAPI/Utils/RequestHelper.swift index 6c0c75d4..3f7df4e0 100644 --- a/Sources/TidalAPI/Utils/RequestHelper.swift +++ b/Sources/TidalAPI/Utils/RequestHelper.swift @@ -9,7 +9,7 @@ enum RequestHelper { requestBuilder: @escaping () async throws -> RequestBuilder ) async throws -> T { guard let credentialsProvider = OpenAPIClientAPI.credentialsProvider else { - throw APIError(message: "NO_CREDENTIALS_PROVIDER", url: "Not available") + throw TidalAPIError(message: "NO_CREDENTIALS_PROVIDER", url: "Not available") } let credentials = try await credentialsProvider.getCredentials() @@ -19,7 +19,7 @@ enum RequestHelper { let token = credentials.token, OpenAPIClientAPI.credentialsProvider?.isUserLoggedIn == true else { - throw APIError( + throw TidalAPIError( message: "NO_TOKEN", url: requestURL ) @@ -68,7 +68,7 @@ enum RequestHelper { let currentRetryCount = retries[url] ?? 0 // Default to 0 if nil guard let provider = OpenAPIClientAPI.credentialsProvider else { - throw APIError(message: "NO_CREDENTIALS_PROVIDER", url: url) + throw TidalAPIError(message: "NO_CREDENTIALS_PROVIDER", url: url) } switch error { @@ -80,19 +80,19 @@ enum RequestHelper { _ = try await provider.getCredentials(apiErrorSubStatus: subStatus.flatMap(String.init)) } catch { if subStatus != nil { - throw APIError( + throw TidalAPIError( message: "Failed to get credentials", url: url, statusCode: statusCode, subStatus: subStatus ) } else { - throw APIError(error: error, url: url) + throw TidalAPIError(error: error, url: url) } } if subStatus != nil, OpenAPIClientAPI.credentialsProvider?.isUserLoggedIn == false { - throw APIError( + throw TidalAPIError( message: "User is not logged in", url: url, statusCode: statusCode, @@ -109,6 +109,6 @@ enum RequestHelper { } } - throw APIError(error: error, url: url) // Propagate the error if not handled or retried + throw TidalAPIError(error: error, url: url) // Propagate the error if not handled or retried } } diff --git a/Sources/TidalAPI/Utils/APIError.swift b/Sources/TidalAPI/Utils/TidalAPIError.swift similarity index 93% rename from Sources/TidalAPI/Utils/APIError.swift rename to Sources/TidalAPI/Utils/TidalAPIError.swift index 891d1fa2..4bccc1e4 100644 --- a/Sources/TidalAPI/Utils/APIError.swift +++ b/Sources/TidalAPI/Utils/TidalAPIError.swift @@ -1,6 +1,6 @@ import Foundation -public struct APIError: LocalizedError, Equatable { +public struct TidalAPIError: LocalizedError, Equatable { let fileID: String let line: UInt let column: UInt @@ -36,7 +36,7 @@ public struct APIError: LocalizedError, Equatable { } } -extension APIError { +extension TidalAPIError { init( fileID: StaticString = #fileID, line: UInt = #line,