Regenerate API schema for track coauthors

This commit is contained in:
2026-09-25 02:15:32 +02:00
parent 03f5936944
commit 8a5b1bd353
2 changed files with 360 additions and 1 deletions
+358
View File
@@ -178,6 +178,40 @@ export interface paths {
patch?: never; patch?: never;
trace?: never; trace?: never;
}; };
"/coauthor-invitations/{id}/accept": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
get?: never;
put?: never;
/** Accept a pending coauthor invitation addressed to you */
post: operations["AcceptCoauthorInvitation"];
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/coauthor-invitations/{id}/reject": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
get?: never;
put?: never;
/** Reject a pending coauthor invitation addressed to you */
post: operations["RejectCoauthorInvitation"];
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/config/playback": { "/config/playback": {
parameters: { parameters: {
query?: never; query?: never;
@@ -609,6 +643,40 @@ export interface paths {
patch?: never; patch?: never;
trace?: never; trace?: never;
}; };
"/tracks/{id}/coauthors": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
get?: never;
put?: never;
/** Invite users to coauthor one of your tracks. Returns every invitation of the track with its status. A rejected invitation is reset to pending */
post: operations["InviteCoauthors"];
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/tracks/{id}/coauthors/{userId}": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
get?: never;
put?: never;
post?: never;
/** Remove a coauthor or pending invitation from a track. Allowed to the track owner and to the coauthor themself */
delete: operations["RemoveCoauthor"];
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/tracks/upload-urls": { "/tracks/upload-urls": {
parameters: { parameters: {
query?: never; query?: never;
@@ -643,6 +711,23 @@ export interface paths {
patch?: never; patch?: never;
trace?: never; trace?: never;
}; };
"/users/me/coauthor-invitations": {
parameters: {
query?: never;
header?: never;
path?: never;
cookie?: never;
};
/** Get your pending coauthor invitations with the track title and owner */
get: operations["GetCoauthorInvitations"];
put?: never;
post?: never;
delete?: never;
options?: never;
head?: never;
patch?: never;
trace?: never;
};
"/users/{id}": { "/users/{id}": {
parameters: { parameters: {
query?: never; query?: never;
@@ -843,6 +928,19 @@ export interface components {
genre: components["schemas"]["Genre"]; genre: components["schemas"]["Genre"];
incompatibleWith: components["schemas"]["Genre"][]; incompatibleWith: components["schemas"]["Genre"][];
}; };
CoauthorInvitationResponse: {
/** Format: uuid */
id: string;
/** Format: uuid */
trackId: string;
trackTitle: string;
artist: null | string;
ownerUserId: string;
/** Format: date-time */
invitedAt: string;
};
/** @enum {unknown} */
CoauthorStatus: "Pending" | "Accepted" | "Rejected";
CreateAlbumRequest: { CreateAlbumRequest: {
title: string; title: string;
description: null | string; description: null | string;
@@ -895,6 +993,9 @@ export interface components {
[key: string]: string[]; [key: string]: string[];
}; };
}; };
InviteCoauthorsRequest: {
userIds: (number | string)[];
};
ListeningStatsResponse: { ListeningStatsResponse: {
/** Format: int32 */ /** Format: int32 */
tracksThisWeek: number | string; tracksThisWeek: number | string;
@@ -936,6 +1037,19 @@ export interface components {
hasNextPage: boolean; hasNextPage: boolean;
hasPreviousPage: boolean; hasPreviousPage: boolean;
}; };
PaginatedResponseOfCoauthorInvitationResponse: {
items: components["schemas"]["CoauthorInvitationResponse"][];
/** Format: int32 */
pageNumber: number | string;
/** Format: int32 */
pageSize: number | string;
/** Format: int32 */
pageCount: number | string;
/** Format: int32 */
totalItemCount: number | string;
hasNextPage: boolean;
hasPreviousPage: boolean;
};
PaginatedResponseOfPlayListApplicationResponse: { PaginatedResponseOfPlayListApplicationResponse: {
items: components["schemas"]["PlayListApplicationResponse"][]; items: components["schemas"]["PlayListApplicationResponse"][];
/** Format: int32 */ /** Format: int32 */
@@ -1087,6 +1201,7 @@ export interface components {
tags: components["schemas"]["Genre"][]; tags: components["schemas"]["Genre"][];
isExplicit: boolean; isExplicit: boolean;
isPublished: boolean; isPublished: boolean;
coauthors: components["schemas"]["TrackCoauthorReference"][];
}; };
TrackAudioUpload: { TrackAudioUpload: {
/** Format: uuid */ /** Format: uuid */
@@ -1098,6 +1213,15 @@ export interface components {
contentType: string; contentType: string;
uploadUrl: string; uploadUrl: string;
}; };
TrackCoauthorInviteReference: {
userId: string;
name: string;
status: components["schemas"]["CoauthorStatus"];
};
TrackCoauthorReference: {
id: string;
name: string;
};
TrackStatusCountsResponse: { TrackStatusCountsResponse: {
/** Format: int32 */ /** Format: int32 */
total: number | string; total: number | string;
@@ -1213,6 +1337,8 @@ export interface components {
isExplicit: boolean; isExplicit: boolean;
isPublished: boolean; isPublished: boolean;
albums: components["schemas"]["TrackAlbumReference"][]; albums: components["schemas"]["TrackAlbumReference"][];
coauthors: components["schemas"]["TrackCoauthorReference"][];
coauthorInvites: components["schemas"]["TrackCoauthorInviteReference"][];
}; };
}; };
responses: never; responses: never;
@@ -1798,6 +1924,102 @@ export interface operations {
}; };
}; };
}; };
AcceptCoauthorInvitation: {
parameters: {
query?: never;
header?: never;
path: {
id: string;
};
cookie?: never;
};
requestBody?: never;
responses: {
/** @description No Content */
204: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Unauthorized */
401: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Forbidden */
403: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Not Found */
404: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Conflict */
409: {
headers: {
[name: string]: unknown;
};
content?: never;
};
};
};
RejectCoauthorInvitation: {
parameters: {
query?: never;
header?: never;
path: {
id: string;
};
cookie?: never;
};
requestBody?: never;
responses: {
/** @description No Content */
204: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Unauthorized */
401: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Forbidden */
403: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Not Found */
404: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Conflict */
409: {
headers: {
[name: string]: unknown;
};
content?: never;
};
};
};
GetPlaybackPublicConfig: { GetPlaybackPublicConfig: {
parameters: { parameters: {
query?: never; query?: never;
@@ -2822,6 +3044,7 @@ export interface operations {
pageSize?: number | string; pageSize?: number | string;
status?: components["schemas"]["ProcessingStatus"][]; status?: components["schemas"]["ProcessingStatus"][];
published?: boolean; published?: boolean;
includeCoauthored?: boolean;
}; };
header?: never; header?: never;
path: { path: {
@@ -2979,6 +3202,111 @@ export interface operations {
}; };
}; };
}; };
InviteCoauthors: {
parameters: {
query?: never;
header?: never;
path: {
id: string;
};
cookie?: never;
};
requestBody: {
content: {
"application/json": components["schemas"]["InviteCoauthorsRequest"];
};
};
responses: {
/** @description OK */
200: {
headers: {
[name: string]: unknown;
};
content: {
"application/json": components["schemas"]["TrackCoauthorInviteReference"][];
};
};
/** @description Bad Request */
400: {
headers: {
[name: string]: unknown;
};
content: {
"application/problem+json": components["schemas"]["HttpValidationProblemDetails"];
};
};
/** @description Unauthorized */
401: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Forbidden */
403: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Not Found */
404: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Conflict */
409: {
headers: {
[name: string]: unknown;
};
content?: never;
};
};
};
RemoveCoauthor: {
parameters: {
query?: never;
header?: never;
path: {
id: string;
userId: string;
};
cookie?: never;
};
requestBody?: never;
responses: {
/** @description No Content */
204: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Unauthorized */
401: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Forbidden */
403: {
headers: {
[name: string]: unknown;
};
content?: never;
};
/** @description Not Found */
404: {
headers: {
[name: string]: unknown;
};
content?: never;
};
};
};
RequestTrackUploadUrls: { RequestTrackUploadUrls: {
parameters: { parameters: {
query?: never; query?: never;
@@ -3057,6 +3385,36 @@ export interface operations {
}; };
}; };
}; };
GetCoauthorInvitations: {
parameters: {
query?: {
pageNumber?: number | string;
pageSize?: number | string;
};
header?: never;
path?: never;
cookie?: never;
};
requestBody?: never;
responses: {
/** @description OK */
200: {
headers: {
[name: string]: unknown;
};
content: {
"application/json": components["schemas"]["PaginatedResponseOfCoauthorInvitationResponse"];
};
};
/** @description Unauthorized */
401: {
headers: {
[name: string]: unknown;
};
content?: never;
};
};
};
GetUserById: { GetUserById: {
parameters: { parameters: {
query?: never; query?: never;
+2 -1
View File
@@ -24,7 +24,8 @@ const trackDto: components['schemas']['TrackApplicationResponse'] = {
ownerUserId: '42', ownerUserId: '42',
tags: [], tags: [],
isExplicit: true, isExplicit: true,
isPublished: true isPublished: true,
coauthors: []
}; };
describe('toTrack', () => { describe('toTrack', () => {