@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 { DUMMY_BASE_URL, setApiKeyToObject, setSearchParams, toPathString, createRequestFunction } from '../common.js';
|
|
4
3
|
import { BaseAPI, BASE_PATH } from '../base.js';
|
|
@@ -27,7 +26,7 @@ const LocalizationApiAxiosParamCreator = function (configuration) {
|
|
|
27
26
|
* @param {*} [options] Override http request option.
|
|
28
27
|
* @throws {RequiredError}
|
|
29
28
|
*/
|
|
30
|
-
getCountries:
|
|
29
|
+
getCountries: async (options = {}) => {
|
|
31
30
|
const localVarPath = `/Localization/Countries`;
|
|
32
31
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
33
32
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -35,26 +34,26 @@ const LocalizationApiAxiosParamCreator = function (configuration) {
|
|
|
35
34
|
if (configuration) {
|
|
36
35
|
baseOptions = configuration.baseOptions;
|
|
37
36
|
}
|
|
38
|
-
const localVarRequestOptions =
|
|
37
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
39
38
|
const localVarHeaderParameter = {};
|
|
40
39
|
const localVarQueryParameter = {};
|
|
41
40
|
// authentication CustomAuthentication required
|
|
42
|
-
|
|
41
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
43
42
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
44
43
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
45
|
-
localVarRequestOptions.headers =
|
|
44
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
46
45
|
return {
|
|
47
46
|
url: toPathString(localVarUrlObj),
|
|
48
47
|
options: localVarRequestOptions,
|
|
49
48
|
};
|
|
50
|
-
}
|
|
49
|
+
},
|
|
51
50
|
/**
|
|
52
51
|
*
|
|
53
52
|
* @summary Gets known cultures.
|
|
54
53
|
* @param {*} [options] Override http request option.
|
|
55
54
|
* @throws {RequiredError}
|
|
56
55
|
*/
|
|
57
|
-
getCultures:
|
|
56
|
+
getCultures: async (options = {}) => {
|
|
58
57
|
const localVarPath = `/Localization/Cultures`;
|
|
59
58
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
60
59
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -62,26 +61,26 @@ const LocalizationApiAxiosParamCreator = function (configuration) {
|
|
|
62
61
|
if (configuration) {
|
|
63
62
|
baseOptions = configuration.baseOptions;
|
|
64
63
|
}
|
|
65
|
-
const localVarRequestOptions =
|
|
64
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
66
65
|
const localVarHeaderParameter = {};
|
|
67
66
|
const localVarQueryParameter = {};
|
|
68
67
|
// authentication CustomAuthentication required
|
|
69
|
-
|
|
68
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
70
69
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
71
70
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
72
|
-
localVarRequestOptions.headers =
|
|
71
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
73
72
|
return {
|
|
74
73
|
url: toPathString(localVarUrlObj),
|
|
75
74
|
options: localVarRequestOptions,
|
|
76
75
|
};
|
|
77
|
-
}
|
|
76
|
+
},
|
|
78
77
|
/**
|
|
79
78
|
*
|
|
80
79
|
* @summary Gets localization options.
|
|
81
80
|
* @param {*} [options] Override http request option.
|
|
82
81
|
* @throws {RequiredError}
|
|
83
82
|
*/
|
|
84
|
-
getLocalizationOptions:
|
|
83
|
+
getLocalizationOptions: async (options = {}) => {
|
|
85
84
|
const localVarPath = `/Localization/Options`;
|
|
86
85
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
87
86
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -89,26 +88,26 @@ const LocalizationApiAxiosParamCreator = function (configuration) {
|
|
|
89
88
|
if (configuration) {
|
|
90
89
|
baseOptions = configuration.baseOptions;
|
|
91
90
|
}
|
|
92
|
-
const localVarRequestOptions =
|
|
91
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
93
92
|
const localVarHeaderParameter = {};
|
|
94
93
|
const localVarQueryParameter = {};
|
|
95
94
|
// authentication CustomAuthentication required
|
|
96
|
-
|
|
95
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
97
96
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
98
97
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
99
|
-
localVarRequestOptions.headers =
|
|
98
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
100
99
|
return {
|
|
101
100
|
url: toPathString(localVarUrlObj),
|
|
102
101
|
options: localVarRequestOptions,
|
|
103
102
|
};
|
|
104
|
-
}
|
|
103
|
+
},
|
|
105
104
|
/**
|
|
106
105
|
*
|
|
107
106
|
* @summary Gets known parental ratings.
|
|
108
107
|
* @param {*} [options] Override http request option.
|
|
109
108
|
* @throws {RequiredError}
|
|
110
109
|
*/
|
|
111
|
-
getParentalRatings:
|
|
110
|
+
getParentalRatings: async (options = {}) => {
|
|
112
111
|
const localVarPath = `/Localization/ParentalRatings`;
|
|
113
112
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
114
113
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -116,19 +115,19 @@ const LocalizationApiAxiosParamCreator = function (configuration) {
|
|
|
116
115
|
if (configuration) {
|
|
117
116
|
baseOptions = configuration.baseOptions;
|
|
118
117
|
}
|
|
119
|
-
const localVarRequestOptions =
|
|
118
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
120
119
|
const localVarHeaderParameter = {};
|
|
121
120
|
const localVarQueryParameter = {};
|
|
122
121
|
// authentication CustomAuthentication required
|
|
123
|
-
|
|
122
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
124
123
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
125
124
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
126
|
-
localVarRequestOptions.headers =
|
|
125
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
127
126
|
return {
|
|
128
127
|
url: toPathString(localVarUrlObj),
|
|
129
128
|
options: localVarRequestOptions,
|
|
130
129
|
};
|
|
131
|
-
}
|
|
130
|
+
},
|
|
132
131
|
};
|
|
133
132
|
};
|
|
134
133
|
/**
|
|
@@ -144,11 +143,9 @@ const LocalizationApiFp = function (configuration) {
|
|
|
144
143
|
* @param {*} [options] Override http request option.
|
|
145
144
|
* @throws {RequiredError}
|
|
146
145
|
*/
|
|
147
|
-
getCountries(options) {
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
151
|
-
});
|
|
146
|
+
async getCountries(options) {
|
|
147
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getCountries(options);
|
|
148
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
152
149
|
},
|
|
153
150
|
/**
|
|
154
151
|
*
|
|
@@ -156,11 +153,9 @@ const LocalizationApiFp = function (configuration) {
|
|
|
156
153
|
* @param {*} [options] Override http request option.
|
|
157
154
|
* @throws {RequiredError}
|
|
158
155
|
*/
|
|
159
|
-
getCultures(options) {
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
163
|
-
});
|
|
156
|
+
async getCultures(options) {
|
|
157
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getCultures(options);
|
|
158
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
164
159
|
},
|
|
165
160
|
/**
|
|
166
161
|
*
|
|
@@ -168,11 +163,9 @@ const LocalizationApiFp = function (configuration) {
|
|
|
168
163
|
* @param {*} [options] Override http request option.
|
|
169
164
|
* @throws {RequiredError}
|
|
170
165
|
*/
|
|
171
|
-
getLocalizationOptions(options) {
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
175
|
-
});
|
|
166
|
+
async getLocalizationOptions(options) {
|
|
167
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getLocalizationOptions(options);
|
|
168
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
176
169
|
},
|
|
177
170
|
/**
|
|
178
171
|
*
|
|
@@ -180,11 +173,9 @@ const LocalizationApiFp = function (configuration) {
|
|
|
180
173
|
* @param {*} [options] Override http request option.
|
|
181
174
|
* @throws {RequiredError}
|
|
182
175
|
*/
|
|
183
|
-
getParentalRatings(options) {
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
187
|
-
});
|
|
176
|
+
async getParentalRatings(options) {
|
|
177
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getParentalRatings(options);
|
|
178
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
188
179
|
},
|
|
189
180
|
};
|
|
190
181
|
};
|
|
@@ -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';
|
|
@@ -28,7 +27,7 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
28
27
|
* @param {*} [options] Override http request option.
|
|
29
28
|
* @throws {RequiredError}
|
|
30
29
|
*/
|
|
31
|
-
deleteLyrics:
|
|
30
|
+
deleteLyrics: async (itemId, options = {}) => {
|
|
32
31
|
// verify required parameter 'itemId' is not null or undefined
|
|
33
32
|
assertParamExists('deleteLyrics', 'itemId', itemId);
|
|
34
33
|
const localVarPath = `/Audio/{itemId}/Lyrics`
|
|
@@ -39,19 +38,19 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
39
38
|
if (configuration) {
|
|
40
39
|
baseOptions = configuration.baseOptions;
|
|
41
40
|
}
|
|
42
|
-
const localVarRequestOptions =
|
|
41
|
+
const localVarRequestOptions = { method: 'DELETE', ...baseOptions, ...options };
|
|
43
42
|
const localVarHeaderParameter = {};
|
|
44
43
|
const localVarQueryParameter = {};
|
|
45
44
|
// authentication CustomAuthentication required
|
|
46
|
-
|
|
45
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
47
46
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
48
47
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
49
|
-
localVarRequestOptions.headers =
|
|
48
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
50
49
|
return {
|
|
51
50
|
url: toPathString(localVarUrlObj),
|
|
52
51
|
options: localVarRequestOptions,
|
|
53
52
|
};
|
|
54
|
-
}
|
|
53
|
+
},
|
|
55
54
|
/**
|
|
56
55
|
*
|
|
57
56
|
* @summary Downloads a remote lyric.
|
|
@@ -60,7 +59,7 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
60
59
|
* @param {*} [options] Override http request option.
|
|
61
60
|
* @throws {RequiredError}
|
|
62
61
|
*/
|
|
63
|
-
downloadRemoteLyrics:
|
|
62
|
+
downloadRemoteLyrics: async (itemId, lyricId, options = {}) => {
|
|
64
63
|
// verify required parameter 'itemId' is not null or undefined
|
|
65
64
|
assertParamExists('downloadRemoteLyrics', 'itemId', itemId);
|
|
66
65
|
// verify required parameter 'lyricId' is not null or undefined
|
|
@@ -74,19 +73,19 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
74
73
|
if (configuration) {
|
|
75
74
|
baseOptions = configuration.baseOptions;
|
|
76
75
|
}
|
|
77
|
-
const localVarRequestOptions =
|
|
76
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
|
|
78
77
|
const localVarHeaderParameter = {};
|
|
79
78
|
const localVarQueryParameter = {};
|
|
80
79
|
// authentication CustomAuthentication required
|
|
81
|
-
|
|
80
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
82
81
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
83
82
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
84
|
-
localVarRequestOptions.headers =
|
|
83
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
85
84
|
return {
|
|
86
85
|
url: toPathString(localVarUrlObj),
|
|
87
86
|
options: localVarRequestOptions,
|
|
88
87
|
};
|
|
89
|
-
}
|
|
88
|
+
},
|
|
90
89
|
/**
|
|
91
90
|
*
|
|
92
91
|
* @summary Gets an item\'s lyrics.
|
|
@@ -94,7 +93,7 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
94
93
|
* @param {*} [options] Override http request option.
|
|
95
94
|
* @throws {RequiredError}
|
|
96
95
|
*/
|
|
97
|
-
getLyrics:
|
|
96
|
+
getLyrics: async (itemId, options = {}) => {
|
|
98
97
|
// verify required parameter 'itemId' is not null or undefined
|
|
99
98
|
assertParamExists('getLyrics', 'itemId', itemId);
|
|
100
99
|
const localVarPath = `/Audio/{itemId}/Lyrics`
|
|
@@ -105,19 +104,19 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
105
104
|
if (configuration) {
|
|
106
105
|
baseOptions = configuration.baseOptions;
|
|
107
106
|
}
|
|
108
|
-
const localVarRequestOptions =
|
|
107
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
109
108
|
const localVarHeaderParameter = {};
|
|
110
109
|
const localVarQueryParameter = {};
|
|
111
110
|
// authentication CustomAuthentication required
|
|
112
|
-
|
|
111
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
113
112
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
114
113
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
115
|
-
localVarRequestOptions.headers =
|
|
114
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
116
115
|
return {
|
|
117
116
|
url: toPathString(localVarUrlObj),
|
|
118
117
|
options: localVarRequestOptions,
|
|
119
118
|
};
|
|
120
|
-
}
|
|
119
|
+
},
|
|
121
120
|
/**
|
|
122
121
|
*
|
|
123
122
|
* @summary Gets the remote lyrics.
|
|
@@ -125,7 +124,7 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
125
124
|
* @param {*} [options] Override http request option.
|
|
126
125
|
* @throws {RequiredError}
|
|
127
126
|
*/
|
|
128
|
-
getRemoteLyrics:
|
|
127
|
+
getRemoteLyrics: async (lyricId, options = {}) => {
|
|
129
128
|
// verify required parameter 'lyricId' is not null or undefined
|
|
130
129
|
assertParamExists('getRemoteLyrics', 'lyricId', lyricId);
|
|
131
130
|
const localVarPath = `/Providers/Lyrics/{lyricId}`
|
|
@@ -136,19 +135,19 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
136
135
|
if (configuration) {
|
|
137
136
|
baseOptions = configuration.baseOptions;
|
|
138
137
|
}
|
|
139
|
-
const localVarRequestOptions =
|
|
138
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
140
139
|
const localVarHeaderParameter = {};
|
|
141
140
|
const localVarQueryParameter = {};
|
|
142
141
|
// authentication CustomAuthentication required
|
|
143
|
-
|
|
142
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
144
143
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
145
144
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
146
|
-
localVarRequestOptions.headers =
|
|
145
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
147
146
|
return {
|
|
148
147
|
url: toPathString(localVarUrlObj),
|
|
149
148
|
options: localVarRequestOptions,
|
|
150
149
|
};
|
|
151
|
-
}
|
|
150
|
+
},
|
|
152
151
|
/**
|
|
153
152
|
*
|
|
154
153
|
* @summary Search remote lyrics.
|
|
@@ -156,7 +155,7 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
156
155
|
* @param {*} [options] Override http request option.
|
|
157
156
|
* @throws {RequiredError}
|
|
158
157
|
*/
|
|
159
|
-
searchRemoteLyrics:
|
|
158
|
+
searchRemoteLyrics: async (itemId, options = {}) => {
|
|
160
159
|
// verify required parameter 'itemId' is not null or undefined
|
|
161
160
|
assertParamExists('searchRemoteLyrics', 'itemId', itemId);
|
|
162
161
|
const localVarPath = `/Audio/{itemId}/RemoteSearch/Lyrics`
|
|
@@ -167,19 +166,19 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
167
166
|
if (configuration) {
|
|
168
167
|
baseOptions = configuration.baseOptions;
|
|
169
168
|
}
|
|
170
|
-
const localVarRequestOptions =
|
|
169
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options };
|
|
171
170
|
const localVarHeaderParameter = {};
|
|
172
171
|
const localVarQueryParameter = {};
|
|
173
172
|
// authentication CustomAuthentication required
|
|
174
|
-
|
|
173
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
175
174
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
176
175
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
177
|
-
localVarRequestOptions.headers =
|
|
176
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
178
177
|
return {
|
|
179
178
|
url: toPathString(localVarUrlObj),
|
|
180
179
|
options: localVarRequestOptions,
|
|
181
180
|
};
|
|
182
|
-
}
|
|
181
|
+
},
|
|
183
182
|
/**
|
|
184
183
|
*
|
|
185
184
|
* @summary Upload an external lyric file.
|
|
@@ -189,7 +188,7 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
189
188
|
* @param {*} [options] Override http request option.
|
|
190
189
|
* @throws {RequiredError}
|
|
191
190
|
*/
|
|
192
|
-
uploadLyrics:
|
|
191
|
+
uploadLyrics: async (itemId, fileName, body, options = {}) => {
|
|
193
192
|
// verify required parameter 'itemId' is not null or undefined
|
|
194
193
|
assertParamExists('uploadLyrics', 'itemId', itemId);
|
|
195
194
|
// verify required parameter 'fileName' is not null or undefined
|
|
@@ -202,24 +201,24 @@ const LyricsApiAxiosParamCreator = function (configuration) {
|
|
|
202
201
|
if (configuration) {
|
|
203
202
|
baseOptions = configuration.baseOptions;
|
|
204
203
|
}
|
|
205
|
-
const localVarRequestOptions =
|
|
204
|
+
const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options };
|
|
206
205
|
const localVarHeaderParameter = {};
|
|
207
206
|
const localVarQueryParameter = {};
|
|
208
207
|
// authentication CustomAuthentication required
|
|
209
|
-
|
|
208
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration);
|
|
210
209
|
if (fileName !== undefined) {
|
|
211
210
|
localVarQueryParameter['fileName'] = fileName;
|
|
212
211
|
}
|
|
213
212
|
localVarHeaderParameter['Content-Type'] = 'text/plain';
|
|
214
213
|
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
215
214
|
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
216
|
-
localVarRequestOptions.headers =
|
|
215
|
+
localVarRequestOptions.headers = { ...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers };
|
|
217
216
|
localVarRequestOptions.data = serializeDataIfNeeded(body, localVarRequestOptions, configuration);
|
|
218
217
|
return {
|
|
219
218
|
url: toPathString(localVarUrlObj),
|
|
220
219
|
options: localVarRequestOptions,
|
|
221
220
|
};
|
|
222
|
-
}
|
|
221
|
+
},
|
|
223
222
|
};
|
|
224
223
|
};
|
|
225
224
|
/**
|
|
@@ -236,11 +235,9 @@ const LyricsApiFp = function (configuration) {
|
|
|
236
235
|
* @param {*} [options] Override http request option.
|
|
237
236
|
* @throws {RequiredError}
|
|
238
237
|
*/
|
|
239
|
-
deleteLyrics(itemId, options) {
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
243
|
-
});
|
|
238
|
+
async deleteLyrics(itemId, options) {
|
|
239
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.deleteLyrics(itemId, options);
|
|
240
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
244
241
|
},
|
|
245
242
|
/**
|
|
246
243
|
*
|
|
@@ -250,11 +247,9 @@ const LyricsApiFp = function (configuration) {
|
|
|
250
247
|
* @param {*} [options] Override http request option.
|
|
251
248
|
* @throws {RequiredError}
|
|
252
249
|
*/
|
|
253
|
-
downloadRemoteLyrics(itemId, lyricId, options) {
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
257
|
-
});
|
|
250
|
+
async downloadRemoteLyrics(itemId, lyricId, options) {
|
|
251
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.downloadRemoteLyrics(itemId, lyricId, options);
|
|
252
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
258
253
|
},
|
|
259
254
|
/**
|
|
260
255
|
*
|
|
@@ -263,11 +258,9 @@ const LyricsApiFp = function (configuration) {
|
|
|
263
258
|
* @param {*} [options] Override http request option.
|
|
264
259
|
* @throws {RequiredError}
|
|
265
260
|
*/
|
|
266
|
-
getLyrics(itemId, options) {
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
270
|
-
});
|
|
261
|
+
async getLyrics(itemId, options) {
|
|
262
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getLyrics(itemId, options);
|
|
263
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
271
264
|
},
|
|
272
265
|
/**
|
|
273
266
|
*
|
|
@@ -276,11 +269,9 @@ const LyricsApiFp = function (configuration) {
|
|
|
276
269
|
* @param {*} [options] Override http request option.
|
|
277
270
|
* @throws {RequiredError}
|
|
278
271
|
*/
|
|
279
|
-
getRemoteLyrics(lyricId, options) {
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
283
|
-
});
|
|
272
|
+
async getRemoteLyrics(lyricId, options) {
|
|
273
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getRemoteLyrics(lyricId, options);
|
|
274
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
284
275
|
},
|
|
285
276
|
/**
|
|
286
277
|
*
|
|
@@ -289,11 +280,9 @@ const LyricsApiFp = function (configuration) {
|
|
|
289
280
|
* @param {*} [options] Override http request option.
|
|
290
281
|
* @throws {RequiredError}
|
|
291
282
|
*/
|
|
292
|
-
searchRemoteLyrics(itemId, options) {
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
296
|
-
});
|
|
283
|
+
async searchRemoteLyrics(itemId, options) {
|
|
284
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.searchRemoteLyrics(itemId, options);
|
|
285
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
297
286
|
},
|
|
298
287
|
/**
|
|
299
288
|
*
|
|
@@ -304,11 +293,9 @@ const LyricsApiFp = function (configuration) {
|
|
|
304
293
|
* @param {*} [options] Override http request option.
|
|
305
294
|
* @throws {RequiredError}
|
|
306
295
|
*/
|
|
307
|
-
uploadLyrics(itemId, fileName, body, options) {
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
311
|
-
});
|
|
296
|
+
async uploadLyrics(itemId, fileName, body, options) {
|
|
297
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.uploadLyrics(itemId, fileName, body, options);
|
|
298
|
+
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
312
299
|
},
|
|
313
300
|
};
|
|
314
301
|
};
|