@jellyfin/sdk 0.9.0 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -0
- package/lib/discovery/discovery-service.js +4 -9
- package/lib/discovery/recommended-server-discovery.js +17 -22
- package/lib/generated-client/api/activity-log-api.js +8 -11
- package/lib/generated-client/api/api-key-api.js +24 -31
- package/lib/generated-client/api/artists-api.js +24 -31
- package/lib/generated-client/api/audio-api.d.ts +12 -12
- package/lib/generated-client/api/audio-api.js +28 -37
- package/lib/generated-client/api/branding-api.js +21 -28
- package/lib/generated-client/api/channels-api.js +40 -51
- package/lib/generated-client/api/client-log-api.js +8 -11
- package/lib/generated-client/api/collection-api.js +24 -31
- package/lib/generated-client/api/configuration-api.js +40 -51
- package/lib/generated-client/api/dashboard-api.js +15 -20
- package/lib/generated-client/api/devices-api.js +40 -51
- package/lib/generated-client/api/display-preferences-api.js +16 -21
- package/lib/generated-client/api/dynamic-hls-api.d.ts +27 -27
- package/lib/generated-client/api/dynamic-hls-api.js +72 -91
- package/lib/generated-client/api/environment-api.js +48 -61
- package/lib/generated-client/api/filter-api.js +16 -21
- package/lib/generated-client/api/genres-api.js +16 -21
- package/lib/generated-client/api/hls-segment-api.js +37 -48
- package/lib/generated-client/api/image-api.js +269 -344
- package/lib/generated-client/api/instant-mix-api.js +64 -81
- package/lib/generated-client/api/item-lookup-api.js +88 -111
- package/lib/generated-client/api/item-refresh-api.js +8 -11
- package/lib/generated-client/api/item-update-api.js +24 -31
- package/lib/generated-client/api/items-api.js +32 -41
- package/lib/generated-client/api/library-api.js +200 -251
- package/lib/generated-client/api/library-structure-api.js +64 -81
- package/lib/generated-client/api/live-tv-api.js +326 -409
- package/lib/generated-client/api/localization-api.js +32 -41
- package/lib/generated-client/api/lyrics-api.js +48 -61
- package/lib/generated-client/api/media-info-api.js +40 -51
- package/lib/generated-client/api/movies-api.js +8 -11
- package/lib/generated-client/api/music-genres-api.js +16 -21
- package/lib/generated-client/api/package-api.js +48 -61
- package/lib/generated-client/api/persons-api.js +16 -21
- package/lib/generated-client/api/playlists-api.js +80 -101
- package/lib/generated-client/api/playstate-api.js +72 -91
- package/lib/generated-client/api/plugins-api.js +72 -91
- package/lib/generated-client/api/quick-connect-api.js +29 -38
- package/lib/generated-client/api/remote-image-api.js +24 -31
- package/lib/generated-client/api/scheduled-tasks-api.js +40 -51
- package/lib/generated-client/api/search-api.js +8 -11
- package/lib/generated-client/api/session-api.js +128 -161
- package/lib/generated-client/api/startup-api.js +56 -71
- package/lib/generated-client/api/studios-api.js +16 -21
- package/lib/generated-client/api/subtitle-api.js +78 -99
- package/lib/generated-client/api/suggestions-api.js +8 -11
- package/lib/generated-client/api/sync-play-api.js +168 -211
- package/lib/generated-client/api/system-api.js +77 -98
- package/lib/generated-client/api/time-sync-api.js +7 -10
- package/lib/generated-client/api/tmdb-api.js +8 -11
- package/lib/generated-client/api/trailers-api.js +8 -11
- package/lib/generated-client/api/trickplay-api.js +16 -21
- package/lib/generated-client/api/tv-shows-api.js +32 -41
- package/lib/generated-client/api/universal-audio-api.js +16 -21
- package/lib/generated-client/api/user-api.js +107 -136
- package/lib/generated-client/api/user-library-api.js +80 -101
- package/lib/generated-client/api/user-views-api.js +16 -21
- package/lib/generated-client/api/video-attachments-api.js +7 -10
- package/lib/generated-client/api/videos-api.d.ts +12 -12
- package/lib/generated-client/api/videos-api.js +52 -67
- package/lib/generated-client/api/years-api.js +16 -21
- package/lib/generated-client/common.js +8 -11
- package/lib/generated-client/models/search-hint.d.ts +1 -1
- package/lib/utils/api/image-urls-api.js +16 -4
- package/lib/versions.d.ts +1 -1
- package/lib/versions.js +1 -1
- package/package.json +10 -10
- package/lib/node_modules/tslib/tslib.es6.js +0 -33
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { __awaiter } from '../../node_modules/tslib/tslib.es6.js';
|
|
2
1
|
import globalAxios from 'axios';
|
|
3
2
|
import { assertParamExists, DUMMY_BASE_URL, setApiKeyToObject, setSearchParams, toPathString, serializeDataIfNeeded, createRequestFunction } from '../common.js';
|
|
4
3
|
import { BaseAPI, BASE_PATH } from '../base.js';
|
|
@@ -30,7 +29,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
30
29
|
* @param {*} [options] Override http request option.
|
|
31
30
|
* @throws {RequiredError}
|
|
32
31
|
*/
|
|
33
|
-
addItemToPlaylist:
|
|
32
|
+
addItemToPlaylist: async (playlistId, ids, userId, options = {}) => {
|
|
34
33
|
// verify required parameter 'playlistId' is not null or undefined
|
|
35
34
|
assertParamExists('addItemToPlaylist', 'playlistId', playlistId);
|
|
36
35
|
const localVarPath = `/Playlists/{playlistId}/Items`
|
|
@@ -41,11 +40,11 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
41
40
|
if (configuration) {
|
|
42
41
|
baseOptions = configuration.baseOptions;
|
|
43
42
|
}
|
|
44
|
-
const localVarRequestOptions =
|
|
43
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
|
|
45
44
|
const localVarHeaderParameter = {};
|
|
46
45
|
const localVarQueryParameter = {};
|
|
47
46
|
// authentication CustomAuthentication required
|
|
48
|
-
|
|
47
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
49
48
|
if (ids) {
|
|
50
49
|
localVarQueryParameter['ids'] = ids;
|
|
51
50
|
}
|
|
@@ -54,12 +53,12 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
54
53
|
}
|
|
55
54
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
56
55
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
57
|
-
localVarRequestOptions.headers =
|
|
56
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
58
57
|
return {
|
|
59
58
|
url: toPathString(localVarUrlObj),
|
|
60
59
|
options: localVarRequestOptions,
|
|
61
60
|
};
|
|
62
|
-
}
|
|
61
|
+
},
|
|
63
62
|
/**
|
|
64
63
|
* For backwards compatibility parameters can be sent via Query or Body, with Query having higher precedence. Query parameters are obsolete.
|
|
65
64
|
* @summary Creates a new playlist.
|
|
@@ -71,7 +70,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
71
70
|
* @param {*} [options] Override http request option.
|
|
72
71
|
* @throws {RequiredError}
|
|
73
72
|
*/
|
|
74
|
-
createPlaylist:
|
|
73
|
+
createPlaylist: async (name, ids, userId, mediaType, createPlaylistDto, options = {}) => {
|
|
75
74
|
const localVarPath = `/Playlists`;
|
|
76
75
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
77
76
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -79,11 +78,11 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
79
78
|
if (configuration) {
|
|
80
79
|
baseOptions = configuration.baseOptions;
|
|
81
80
|
}
|
|
82
|
-
const localVarRequestOptions =
|
|
81
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
|
|
83
82
|
const localVarHeaderParameter = {};
|
|
84
83
|
const localVarQueryParameter = {};
|
|
85
84
|
// authentication CustomAuthentication required
|
|
86
|
-
|
|
85
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
87
86
|
if (name !== undefined) {
|
|
88
87
|
localVarQueryParameter['name'] = name;
|
|
89
88
|
}
|
|
@@ -99,13 +98,13 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
99
98
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
100
99
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
101
100
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
102
|
-
localVarRequestOptions.headers =
|
|
101
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
103
102
|
localVarRequestOptions.data = serializeDataIfNeeded(createPlaylistDto, localVarRequestOptions, configuration);
|
|
104
103
|
return {
|
|
105
104
|
url: toPathString(localVarUrlObj),
|
|
106
105
|
options: localVarRequestOptions,
|
|
107
106
|
};
|
|
108
|
-
}
|
|
107
|
+
},
|
|
109
108
|
/**
|
|
110
109
|
*
|
|
111
110
|
* @summary Gets the original items of a playlist.
|
|
@@ -121,7 +120,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
121
120
|
* @param {*} [options] Override http request option.
|
|
122
121
|
* @throws {RequiredError}
|
|
123
122
|
*/
|
|
124
|
-
getPlaylistItems:
|
|
123
|
+
getPlaylistItems: async (playlistId, userId, startIndex, limit, fields, enableImages, enableUserData, imageTypeLimit, enableImageTypes, options = {}) => {
|
|
125
124
|
// verify required parameter 'playlistId' is not null or undefined
|
|
126
125
|
assertParamExists('getPlaylistItems', 'playlistId', playlistId);
|
|
127
126
|
const localVarPath = `/Playlists/{playlistId}/Items`
|
|
@@ -132,11 +131,11 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
132
131
|
if (configuration) {
|
|
133
132
|
baseOptions = configuration.baseOptions;
|
|
134
133
|
}
|
|
135
|
-
const localVarRequestOptions =
|
|
134
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
136
135
|
const localVarHeaderParameter = {};
|
|
137
136
|
const localVarQueryParameter = {};
|
|
138
137
|
// authentication CustomAuthentication required
|
|
139
|
-
|
|
138
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
140
139
|
if (userId !== undefined) {
|
|
141
140
|
localVarQueryParameter['userId'] = userId;
|
|
142
141
|
}
|
|
@@ -163,12 +162,12 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
163
162
|
}
|
|
164
163
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
165
164
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
166
|
-
localVarRequestOptions.headers =
|
|
165
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
167
166
|
return {
|
|
168
167
|
url: toPathString(localVarUrlObj),
|
|
169
168
|
options: localVarRequestOptions,
|
|
170
169
|
};
|
|
171
|
-
}
|
|
170
|
+
},
|
|
172
171
|
/**
|
|
173
172
|
*
|
|
174
173
|
* @summary Get a playlist user.
|
|
@@ -177,7 +176,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
177
176
|
* @param {*} [options] Override http request option.
|
|
178
177
|
* @throws {RequiredError}
|
|
179
178
|
*/
|
|
180
|
-
getPlaylistUser:
|
|
179
|
+
getPlaylistUser: async (playlistId, userId, options = {}) => {
|
|
181
180
|
// verify required parameter 'playlistId' is not null or undefined
|
|
182
181
|
assertParamExists('getPlaylistUser', 'playlistId', playlistId);
|
|
183
182
|
// verify required parameter 'userId' is not null or undefined
|
|
@@ -191,19 +190,19 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
191
190
|
if (configuration) {
|
|
192
191
|
baseOptions = configuration.baseOptions;
|
|
193
192
|
}
|
|
194
|
-
const localVarRequestOptions =
|
|
193
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
195
194
|
const localVarHeaderParameter = {};
|
|
196
195
|
const localVarQueryParameter = {};
|
|
197
196
|
// authentication CustomAuthentication required
|
|
198
|
-
|
|
197
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
199
198
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
200
199
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
201
|
-
localVarRequestOptions.headers =
|
|
200
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
202
201
|
return {
|
|
203
202
|
url: toPathString(localVarUrlObj),
|
|
204
203
|
options: localVarRequestOptions,
|
|
205
204
|
};
|
|
206
|
-
}
|
|
205
|
+
},
|
|
207
206
|
/**
|
|
208
207
|
*
|
|
209
208
|
* @summary Get a playlist\'s users.
|
|
@@ -211,7 +210,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
211
210
|
* @param {*} [options] Override http request option.
|
|
212
211
|
* @throws {RequiredError}
|
|
213
212
|
*/
|
|
214
|
-
getPlaylistUsers:
|
|
213
|
+
getPlaylistUsers: async (playlistId, options = {}) => {
|
|
215
214
|
// verify required parameter 'playlistId' is not null or undefined
|
|
216
215
|
assertParamExists('getPlaylistUsers', 'playlistId', playlistId);
|
|
217
216
|
const localVarPath = `/Playlists/{playlistId}/Users`
|
|
@@ -222,19 +221,19 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
222
221
|
if (configuration) {
|
|
223
222
|
baseOptions = configuration.baseOptions;
|
|
224
223
|
}
|
|
225
|
-
const localVarRequestOptions =
|
|
224
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
226
225
|
const localVarHeaderParameter = {};
|
|
227
226
|
const localVarQueryParameter = {};
|
|
228
227
|
// authentication CustomAuthentication required
|
|
229
|
-
|
|
228
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
230
229
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
231
230
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
232
|
-
localVarRequestOptions.headers =
|
|
231
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
233
232
|
return {
|
|
234
233
|
url: toPathString(localVarUrlObj),
|
|
235
234
|
options: localVarRequestOptions,
|
|
236
235
|
};
|
|
237
|
-
}
|
|
236
|
+
},
|
|
238
237
|
/**
|
|
239
238
|
*
|
|
240
239
|
* @summary Moves a playlist item.
|
|
@@ -244,7 +243,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
244
243
|
* @param {*} [options] Override http request option.
|
|
245
244
|
* @throws {RequiredError}
|
|
246
245
|
*/
|
|
247
|
-
moveItem:
|
|
246
|
+
moveItem: async (playlistId, itemId, newIndex, options = {}) => {
|
|
248
247
|
// verify required parameter 'playlistId' is not null or undefined
|
|
249
248
|
assertParamExists('moveItem', 'playlistId', playlistId);
|
|
250
249
|
// verify required parameter 'itemId' is not null or undefined
|
|
@@ -261,19 +260,19 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
261
260
|
if (configuration) {
|
|
262
261
|
baseOptions = configuration.baseOptions;
|
|
263
262
|
}
|
|
264
|
-
const localVarRequestOptions =
|
|
263
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
|
|
265
264
|
const localVarHeaderParameter = {};
|
|
266
265
|
const localVarQueryParameter = {};
|
|
267
266
|
// authentication CustomAuthentication required
|
|
268
|
-
|
|
267
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
269
268
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
270
269
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
271
|
-
localVarRequestOptions.headers =
|
|
270
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
272
271
|
return {
|
|
273
272
|
url: toPathString(localVarUrlObj),
|
|
274
273
|
options: localVarRequestOptions,
|
|
275
274
|
};
|
|
276
|
-
}
|
|
275
|
+
},
|
|
277
276
|
/**
|
|
278
277
|
*
|
|
279
278
|
* @summary Removes items from a playlist.
|
|
@@ -282,7 +281,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
282
281
|
* @param {*} [options] Override http request option.
|
|
283
282
|
* @throws {RequiredError}
|
|
284
283
|
*/
|
|
285
|
-
removeItemFromPlaylist:
|
|
284
|
+
removeItemFromPlaylist: async (playlistId, entryIds, options = {}) => {
|
|
286
285
|
// verify required parameter 'playlistId' is not null or undefined
|
|
287
286
|
assertParamExists('removeItemFromPlaylist', 'playlistId', playlistId);
|
|
288
287
|
const localVarPath = `/Playlists/{playlistId}/Items`
|
|
@@ -293,22 +292,22 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
293
292
|
if (configuration) {
|
|
294
293
|
baseOptions = configuration.baseOptions;
|
|
295
294
|
}
|
|
296
|
-
const localVarRequestOptions =
|
|
295
|
+
const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options };
|
|
297
296
|
const localVarHeaderParameter = {};
|
|
298
297
|
const localVarQueryParameter = {};
|
|
299
298
|
// authentication CustomAuthentication required
|
|
300
|
-
|
|
299
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
301
300
|
if (entryIds) {
|
|
302
301
|
localVarQueryParameter['entryIds'] = entryIds;
|
|
303
302
|
}
|
|
304
303
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
305
304
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
306
|
-
localVarRequestOptions.headers =
|
|
305
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
307
306
|
return {
|
|
308
307
|
url: toPathString(localVarUrlObj),
|
|
309
308
|
options: localVarRequestOptions,
|
|
310
309
|
};
|
|
311
|
-
}
|
|
310
|
+
},
|
|
312
311
|
/**
|
|
313
312
|
*
|
|
314
313
|
* @summary Remove a user from a playlist\'s users.
|
|
@@ -317,7 +316,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
317
316
|
* @param {*} [options] Override http request option.
|
|
318
317
|
* @throws {RequiredError}
|
|
319
318
|
*/
|
|
320
|
-
removeUserFromPlaylist:
|
|
319
|
+
removeUserFromPlaylist: async (playlistId, userId, options = {}) => {
|
|
321
320
|
// verify required parameter 'playlistId' is not null or undefined
|
|
322
321
|
assertParamExists('removeUserFromPlaylist', 'playlistId', playlistId);
|
|
323
322
|
// verify required parameter 'userId' is not null or undefined
|
|
@@ -331,19 +330,19 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
331
330
|
if (configuration) {
|
|
332
331
|
baseOptions = configuration.baseOptions;
|
|
333
332
|
}
|
|
334
|
-
const localVarRequestOptions =
|
|
333
|
+
const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options };
|
|
335
334
|
const localVarHeaderParameter = {};
|
|
336
335
|
const localVarQueryParameter = {};
|
|
337
336
|
// authentication CustomAuthentication required
|
|
338
|
-
|
|
337
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
339
338
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
340
339
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
341
|
-
localVarRequestOptions.headers =
|
|
340
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
342
341
|
return {
|
|
343
342
|
url: toPathString(localVarUrlObj),
|
|
344
343
|
options: localVarRequestOptions,
|
|
345
344
|
};
|
|
346
|
-
}
|
|
345
|
+
},
|
|
347
346
|
/**
|
|
348
347
|
*
|
|
349
348
|
* @summary Updates a playlist.
|
|
@@ -352,7 +351,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
352
351
|
* @param {*} [options] Override http request option.
|
|
353
352
|
* @throws {RequiredError}
|
|
354
353
|
*/
|
|
355
|
-
updatePlaylist:
|
|
354
|
+
updatePlaylist: async (playlistId, updatePlaylistDto, options = {}) => {
|
|
356
355
|
// verify required parameter 'playlistId' is not null or undefined
|
|
357
356
|
assertParamExists('updatePlaylist', 'playlistId', playlistId);
|
|
358
357
|
// verify required parameter 'updatePlaylistDto' is not null or undefined
|
|
@@ -365,21 +364,21 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
365
364
|
if (configuration) {
|
|
366
365
|
baseOptions = configuration.baseOptions;
|
|
367
366
|
}
|
|
368
|
-
const localVarRequestOptions =
|
|
367
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
|
|
369
368
|
const localVarHeaderParameter = {};
|
|
370
369
|
const localVarQueryParameter = {};
|
|
371
370
|
// authentication CustomAuthentication required
|
|
372
|
-
|
|
371
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
373
372
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
374
373
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
375
374
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
376
|
-
localVarRequestOptions.headers =
|
|
375
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
377
376
|
localVarRequestOptions.data = serializeDataIfNeeded(updatePlaylistDto, localVarRequestOptions, configuration);
|
|
378
377
|
return {
|
|
379
378
|
url: toPathString(localVarUrlObj),
|
|
380
379
|
options: localVarRequestOptions,
|
|
381
380
|
};
|
|
382
|
-
}
|
|
381
|
+
},
|
|
383
382
|
/**
|
|
384
383
|
*
|
|
385
384
|
* @summary Modify a user of a playlist\'s users.
|
|
@@ -389,7 +388,7 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
389
388
|
* @param {*} [options] Override http request option.
|
|
390
389
|
* @throws {RequiredError}
|
|
391
390
|
*/
|
|
392
|
-
updatePlaylistUser:
|
|
391
|
+
updatePlaylistUser: async (playlistId, userId, updatePlaylistUserDto, options = {}) => {
|
|
393
392
|
// verify required parameter 'playlistId' is not null or undefined
|
|
394
393
|
assertParamExists('updatePlaylistUser', 'playlistId', playlistId);
|
|
395
394
|
// verify required parameter 'userId' is not null or undefined
|
|
@@ -405,21 +404,21 @@ const PlaylistsApiAxiosParamCreator = function (configuration) {
|
|
|
405
404
|
if (configuration) {
|
|
406
405
|
baseOptions = configuration.baseOptions;
|
|
407
406
|
}
|
|
408
|
-
const localVarRequestOptions =
|
|
407
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
|
|
409
408
|
const localVarHeaderParameter = {};
|
|
410
409
|
const localVarQueryParameter = {};
|
|
411
410
|
// authentication CustomAuthentication required
|
|
412
|
-
|
|
411
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
413
412
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
414
413
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
415
414
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
416
|
-
localVarRequestOptions.headers =
|
|
415
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
417
416
|
localVarRequestOptions.data = serializeDataIfNeeded(updatePlaylistUserDto, localVarRequestOptions, configuration);
|
|
418
417
|
return {
|
|
419
418
|
url: toPathString(localVarUrlObj),
|
|
420
419
|
options: localVarRequestOptions,
|
|
421
420
|
};
|
|
422
|
-
}
|
|
421
|
+
},
|
|
423
422
|
};
|
|
424
423
|
};
|
|
425
424
|
/**
|
|
@@ -438,11 +437,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
438
437
|
* @param {*} [options] Override http request option.
|
|
439
438
|
* @throws {RequiredError}
|
|
440
439
|
*/
|
|
441
|
-
addItemToPlaylist(playlistId, ids, userId, options) {
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
445
|
-
});
|
|
440
|
+
async addItemToPlaylist(playlistId, ids, userId, options) {
|
|
441
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.addItemToPlaylist(playlistId, ids, userId, options);
|
|
442
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
446
443
|
},
|
|
447
444
|
/**
|
|
448
445
|
* For backwards compatibility parameters can be sent via Query or Body, with Query having higher precedence. Query parameters are obsolete.
|
|
@@ -455,11 +452,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
455
452
|
* @param {*} [options] Override http request option.
|
|
456
453
|
* @throws {RequiredError}
|
|
457
454
|
*/
|
|
458
|
-
createPlaylist(name, ids, userId, mediaType, createPlaylistDto, options) {
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
462
|
-
});
|
|
455
|
+
async createPlaylist(name, ids, userId, mediaType, createPlaylistDto, options) {
|
|
456
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.createPlaylist(name, ids, userId, mediaType, createPlaylistDto, options);
|
|
457
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
463
458
|
},
|
|
464
459
|
/**
|
|
465
460
|
*
|
|
@@ -476,11 +471,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
476
471
|
* @param {*} [options] Override http request option.
|
|
477
472
|
* @throws {RequiredError}
|
|
478
473
|
*/
|
|
479
|
-
getPlaylistItems(playlistId, userId, startIndex, limit, fields, enableImages, enableUserData, imageTypeLimit, enableImageTypes, options) {
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
483
|
-
});
|
|
474
|
+
async getPlaylistItems(playlistId, userId, startIndex, limit, fields, enableImages, enableUserData, imageTypeLimit, enableImageTypes, options) {
|
|
475
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getPlaylistItems(playlistId, userId, startIndex, limit, fields, enableImages, enableUserData, imageTypeLimit, enableImageTypes, options);
|
|
476
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
484
477
|
},
|
|
485
478
|
/**
|
|
486
479
|
*
|
|
@@ -490,11 +483,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
490
483
|
* @param {*} [options] Override http request option.
|
|
491
484
|
* @throws {RequiredError}
|
|
492
485
|
*/
|
|
493
|
-
getPlaylistUser(playlistId, userId, options) {
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
497
|
-
});
|
|
486
|
+
async getPlaylistUser(playlistId, userId, options) {
|
|
487
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getPlaylistUser(playlistId, userId, options);
|
|
488
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
498
489
|
},
|
|
499
490
|
/**
|
|
500
491
|
*
|
|
@@ -503,11 +494,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
503
494
|
* @param {*} [options] Override http request option.
|
|
504
495
|
* @throws {RequiredError}
|
|
505
496
|
*/
|
|
506
|
-
getPlaylistUsers(playlistId, options) {
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
510
|
-
});
|
|
497
|
+
async getPlaylistUsers(playlistId, options) {
|
|
498
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getPlaylistUsers(playlistId, options);
|
|
499
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
511
500
|
},
|
|
512
501
|
/**
|
|
513
502
|
*
|
|
@@ -518,11 +507,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
518
507
|
* @param {*} [options] Override http request option.
|
|
519
508
|
* @throws {RequiredError}
|
|
520
509
|
*/
|
|
521
|
-
moveItem(playlistId, itemId, newIndex, options) {
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
525
|
-
});
|
|
510
|
+
async moveItem(playlistId, itemId, newIndex, options) {
|
|
511
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.moveItem(playlistId, itemId, newIndex, options);
|
|
512
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
526
513
|
},
|
|
527
514
|
/**
|
|
528
515
|
*
|
|
@@ -532,11 +519,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
532
519
|
* @param {*} [options] Override http request option.
|
|
533
520
|
* @throws {RequiredError}
|
|
534
521
|
*/
|
|
535
|
-
removeItemFromPlaylist(playlistId, entryIds, options) {
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
539
|
-
});
|
|
522
|
+
async removeItemFromPlaylist(playlistId, entryIds, options) {
|
|
523
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.removeItemFromPlaylist(playlistId, entryIds, options);
|
|
524
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
540
525
|
},
|
|
541
526
|
/**
|
|
542
527
|
*
|
|
@@ -546,11 +531,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
546
531
|
* @param {*} [options] Override http request option.
|
|
547
532
|
* @throws {RequiredError}
|
|
548
533
|
*/
|
|
549
|
-
removeUserFromPlaylist(playlistId, userId, options) {
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
553
|
-
});
|
|
534
|
+
async removeUserFromPlaylist(playlistId, userId, options) {
|
|
535
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.removeUserFromPlaylist(playlistId, userId, options);
|
|
536
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
554
537
|
},
|
|
555
538
|
/**
|
|
556
539
|
*
|
|
@@ -560,11 +543,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
560
543
|
* @param {*} [options] Override http request option.
|
|
561
544
|
* @throws {RequiredError}
|
|
562
545
|
*/
|
|
563
|
-
updatePlaylist(playlistId, updatePlaylistDto, options) {
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
567
|
-
});
|
|
546
|
+
async updatePlaylist(playlistId, updatePlaylistDto, options) {
|
|
547
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.updatePlaylist(playlistId, updatePlaylistDto, options);
|
|
548
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
568
549
|
},
|
|
569
550
|
/**
|
|
570
551
|
*
|
|
@@ -575,11 +556,9 @@ const PlaylistsApiFp = function (configuration) {
|
|
|
575
556
|
* @param {*} [options] Override http request option.
|
|
576
557
|
* @throws {RequiredError}
|
|
577
558
|
*/
|
|
578
|
-
updatePlaylistUser(playlistId, userId, updatePlaylistUserDto, options) {
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
582
|
-
});
|
|
559
|
+
async updatePlaylistUser(playlistId, userId, updatePlaylistUserDto, options) {
|
|
560
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.updatePlaylistUser(playlistId, userId, updatePlaylistUserDto, options);
|
|
561
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
583
562
|
},
|
|
584
563
|
};
|
|
585
564
|
};
|