@khang07/zing-mp3-api 1.3.6 → 1.3.7
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 +388 -328
- package/dist/cjs/index.cjs +67 -60
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/esm/index.js +67 -61
- package/dist/esm/index.js.map +1 -1
- package/dist/types/index.d.ts +6 -6
- package/dist/types/types/response.d.ts +5 -5
- package/package.json +3 -2
package/dist/cjs/index.cjs
CHANGED
|
@@ -20,6 +20,7 @@ const isURL = (value) => {
|
|
|
20
20
|
return false;
|
|
21
21
|
}
|
|
22
22
|
};
|
|
23
|
+
const ensureCookies = async (instance) => await instance.get('/');
|
|
23
24
|
class Client {
|
|
24
25
|
static BASE_URL = 'https://zingmp3.vn/';
|
|
25
26
|
static VERSION_URL_V1 = '1.6.34';
|
|
@@ -49,11 +50,18 @@ class Client {
|
|
|
49
50
|
maxHighWaterMark;
|
|
50
51
|
userAgent;
|
|
51
52
|
jar;
|
|
52
|
-
constructor(options
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
53
|
+
constructor(options) {
|
|
54
|
+
const mergedOptions = {
|
|
55
|
+
maxLoad: 1024 * 1024,
|
|
56
|
+
maxHighWaterMark: 16 * 1024,
|
|
57
|
+
userAgent: 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3',
|
|
58
|
+
jar: new cookies.Cookies(),
|
|
59
|
+
...options
|
|
60
|
+
};
|
|
61
|
+
this.maxLoad = mergedOptions.maxLoad;
|
|
62
|
+
this.maxHighWaterMark = mergedOptions.maxHighWaterMark;
|
|
63
|
+
this.userAgent = mergedOptions.userAgent;
|
|
64
|
+
this.jar = mergedOptions.jar;
|
|
57
65
|
this.instance = axios.create({
|
|
58
66
|
baseURL: Client.BASE_URL,
|
|
59
67
|
params: {
|
|
@@ -61,14 +69,12 @@ class Client {
|
|
|
61
69
|
apiKey: Client.API_KEY_V1,
|
|
62
70
|
ctime: this.ctime
|
|
63
71
|
},
|
|
64
|
-
maxRate: this.maxLoad
|
|
65
|
-
headers: {
|
|
66
|
-
'User-Agent': this.userAgent
|
|
67
|
-
}
|
|
72
|
+
maxRate: this.maxLoad
|
|
68
73
|
});
|
|
69
74
|
this.instance.interceptors.request.use(async (options) => {
|
|
70
75
|
const base = options.baseURL ?? '';
|
|
71
76
|
const url = new node_url.URL(options.url ?? '/', base).toString();
|
|
77
|
+
options.headers.set('User-Agent', this.userAgent);
|
|
72
78
|
const additionalHeaders = this.jar.applyToHeaders(url);
|
|
73
79
|
for (const [key, value] of Object.entries(additionalHeaders))
|
|
74
80
|
options.headers.set(key, value);
|
|
@@ -82,9 +88,19 @@ class Client {
|
|
|
82
88
|
return response.data;
|
|
83
89
|
});
|
|
84
90
|
}
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
91
|
+
setOptions(options) {
|
|
92
|
+
const mergedOptions = {
|
|
93
|
+
maxLoad: this.maxLoad,
|
|
94
|
+
maxHighWaterMark: this.maxHighWaterMark,
|
|
95
|
+
userAgent: this.userAgent,
|
|
96
|
+
jar: this.jar,
|
|
97
|
+
...options
|
|
98
|
+
};
|
|
99
|
+
this.maxLoad = mergedOptions.maxLoad;
|
|
100
|
+
this.maxHighWaterMark = mergedOptions.maxHighWaterMark;
|
|
101
|
+
this.userAgent = mergedOptions.userAgent;
|
|
102
|
+
this.jar = mergedOptions.jar;
|
|
103
|
+
this.instance.defaults.maxRate = mergedOptions.maxLoad;
|
|
88
104
|
}
|
|
89
105
|
async video(videoID) {
|
|
90
106
|
const value = videoID instanceof node_url.URL ? videoID.toString() : videoID;
|
|
@@ -92,7 +108,7 @@ class Client {
|
|
|
92
108
|
throw new lapse.Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');
|
|
93
109
|
try {
|
|
94
110
|
videoID = isURL(value) ? Client.getIDFromURL(value) : value;
|
|
95
|
-
void await this.
|
|
111
|
+
void await ensureCookies(this.instance);
|
|
96
112
|
const response = await this.instance.get(Client.API_VIDEO_PATH, {
|
|
97
113
|
params: {
|
|
98
114
|
id: videoID,
|
|
@@ -100,7 +116,7 @@ class Client {
|
|
|
100
116
|
}
|
|
101
117
|
});
|
|
102
118
|
if (response.err !== 0)
|
|
103
|
-
throw new lapse.Lapse('Video could not be found', 'ERROR_VIDEO_NOT_FOUND', response.err
|
|
119
|
+
throw new lapse.Lapse('Video could not be found', 'ERROR_VIDEO_NOT_FOUND', response.err);
|
|
104
120
|
const videoURL = response.data?.streaming?.hls?.['720p'] || response.data?.streaming?.hls?.['360p'];
|
|
105
121
|
if (!videoURL || !videoURL.length)
|
|
106
122
|
throw new lapse.Lapse('Streaming URL not found', 'ERROR_STREAM_URL_NOT_FOUND');
|
|
@@ -114,9 +130,8 @@ class Client {
|
|
|
114
130
|
return source;
|
|
115
131
|
}
|
|
116
132
|
catch (error) {
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
throw new lapse.Lapse('Failed to fetch video stream', 'ERROR_VIDEO_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
133
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Failed to fetch video stream', 'ERROR_VIDEO_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
134
|
+
throw lapse$1;
|
|
120
135
|
}
|
|
121
136
|
}
|
|
122
137
|
videoSync(videoID) {
|
|
@@ -165,7 +180,7 @@ class Client {
|
|
|
165
180
|
throw new lapse.Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');
|
|
166
181
|
try {
|
|
167
182
|
musicID = isURL(value) ? Client.getIDFromURL(value) : value;
|
|
168
|
-
void await this.
|
|
183
|
+
void await ensureCookies(this.instance);
|
|
169
184
|
const response = await this.instance.get(Client.API_MUSIC_PATH, {
|
|
170
185
|
params: {
|
|
171
186
|
id: musicID,
|
|
@@ -176,7 +191,7 @@ class Client {
|
|
|
176
191
|
if (response.err === -1150) {
|
|
177
192
|
const retry = async (step, before) => {
|
|
178
193
|
if (step > 3)
|
|
179
|
-
throw new lapse.Lapse('Music requested by VIP, PRI', 'ERROR_MUSIC_VIP_ONLY', before ? before.err : void 0
|
|
194
|
+
throw new lapse.Lapse('Music requested by VIP, PRI', 'ERROR_MUSIC_VIP_ONLY', before ? before.err : void 0);
|
|
180
195
|
const retryData = await this.instance.get(Client.EXTRA_API_MUSIC_PATH, {
|
|
181
196
|
params: {
|
|
182
197
|
id: musicID,
|
|
@@ -202,9 +217,8 @@ class Client {
|
|
|
202
217
|
return source;
|
|
203
218
|
}
|
|
204
219
|
catch (error) {
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
throw new lapse.Lapse('Failed to fetch music stream', 'ERROR_MUSIC_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
220
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Failed to fetch music stream', 'ERROR_MUSIC_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
221
|
+
throw lapse$1;
|
|
208
222
|
}
|
|
209
223
|
}
|
|
210
224
|
musicSync(musicID) {
|
|
@@ -251,7 +265,7 @@ class Client {
|
|
|
251
265
|
throw new lapse.Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');
|
|
252
266
|
try {
|
|
253
267
|
playlistID = isURL(value) ? Client.getIDFromURL(value) : value;
|
|
254
|
-
void await this.
|
|
268
|
+
void await ensureCookies(this.instance);
|
|
255
269
|
const response = await this.instance.get(Client.API_PLAYLIST_PATH, {
|
|
256
270
|
params: {
|
|
257
271
|
id: playlistID,
|
|
@@ -263,9 +277,8 @@ class Client {
|
|
|
263
277
|
return refined.createPlayList(response.data);
|
|
264
278
|
}
|
|
265
279
|
catch (error) {
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
throw new lapse.Lapse('Failed to fetch playlist', 'ERROR_PLAYLIST_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
280
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Failed to fetch playlist', 'ERROR_PLAYLIST_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
281
|
+
throw lapse$1;
|
|
269
282
|
}
|
|
270
283
|
}
|
|
271
284
|
async artist(aliasID) {
|
|
@@ -274,7 +287,7 @@ class Client {
|
|
|
274
287
|
throw new lapse.Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');
|
|
275
288
|
try {
|
|
276
289
|
aliasID = isURL(value) ? Client.getIDFromURL(value) : value;
|
|
277
|
-
void await this.
|
|
290
|
+
void await ensureCookies(this.instance);
|
|
278
291
|
const response = await this.instance.get(Client.API_ARTIST_PATH, {
|
|
279
292
|
params: {
|
|
280
293
|
alias: aliasID,
|
|
@@ -282,15 +295,14 @@ class Client {
|
|
|
282
295
|
}
|
|
283
296
|
});
|
|
284
297
|
if (response.err === -108)
|
|
285
|
-
throw new lapse.Lapse('Artist not found', 'ERROR_ARTIST_NOT_FOUND', response.err
|
|
298
|
+
throw new lapse.Lapse('Artist not found', 'ERROR_ARTIST_NOT_FOUND', response.err);
|
|
286
299
|
if (response.err !== 0)
|
|
287
|
-
throw new lapse.Lapse('Could not fetch artist', 'ERROR_ARTIST_FETCH', response.err
|
|
300
|
+
throw new lapse.Lapse('Could not fetch artist', 'ERROR_ARTIST_FETCH', response.err);
|
|
288
301
|
return refined.createArtist(response.data);
|
|
289
302
|
}
|
|
290
303
|
catch (error) {
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
throw new lapse.Lapse('Failed to fetch artist', 'ERROR_ARTIST_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
304
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Failed to fetch artist', 'ERROR_ARTIST_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
305
|
+
throw lapse$1;
|
|
294
306
|
}
|
|
295
307
|
}
|
|
296
308
|
async mediaDetails(mediaID) {
|
|
@@ -299,7 +311,7 @@ class Client {
|
|
|
299
311
|
throw new lapse.Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');
|
|
300
312
|
try {
|
|
301
313
|
mediaID = isURL(value) ? Client.getIDFromURL(value) : value;
|
|
302
|
-
void await this.
|
|
314
|
+
void await ensureCookies(this.instance);
|
|
303
315
|
const response = await this.instance.get(Client.API_MEDIA_DETAILS_PATH, {
|
|
304
316
|
params: {
|
|
305
317
|
id: mediaID,
|
|
@@ -307,22 +319,21 @@ class Client {
|
|
|
307
319
|
}
|
|
308
320
|
});
|
|
309
321
|
if (response.err === -1023)
|
|
310
|
-
throw new lapse.Lapse('Media not found', 'ERROR_MEDIA_NOT_FOUND', response.err
|
|
322
|
+
throw new lapse.Lapse('Media not found', 'ERROR_MEDIA_NOT_FOUND', response.err);
|
|
311
323
|
if (response.err !== 0)
|
|
312
|
-
throw new lapse.Lapse('Could not fetch media', 'ERROR_MEDIA_FETCH', response.err
|
|
324
|
+
throw new lapse.Lapse('Could not fetch media', 'ERROR_MEDIA_FETCH', response.err);
|
|
313
325
|
return refined.createMedia(response.data);
|
|
314
326
|
}
|
|
315
327
|
catch (error) {
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
throw new lapse.Lapse('Failed to fetch media', 'ERROR_MEDIA_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
328
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Failed to fetch media', 'ERROR_MEDIA_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
329
|
+
throw lapse$1;
|
|
319
330
|
}
|
|
320
331
|
}
|
|
321
332
|
async searchMusic(query) {
|
|
322
333
|
if (typeof query !== 'string' || !query.trim().length)
|
|
323
334
|
throw new lapse.Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');
|
|
324
335
|
try {
|
|
325
|
-
void await this.
|
|
336
|
+
void await ensureCookies(this.instance);
|
|
326
337
|
const response = await this.instance.get(Client.API_SEARCH_PATH, {
|
|
327
338
|
params: {
|
|
328
339
|
q: query,
|
|
@@ -333,20 +344,19 @@ class Client {
|
|
|
333
344
|
}
|
|
334
345
|
});
|
|
335
346
|
if (response.err !== 0)
|
|
336
|
-
throw new lapse.Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err
|
|
337
|
-
return response.data.items.map(refined.createSearchMedia);
|
|
347
|
+
throw new lapse.Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err);
|
|
348
|
+
return (response.data.items ?? []).map(refined.createSearchMedia);
|
|
338
349
|
}
|
|
339
350
|
catch (error) {
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
throw new lapse.Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
351
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
352
|
+
throw lapse$1;
|
|
343
353
|
}
|
|
344
354
|
}
|
|
345
355
|
async searchVideo(query) {
|
|
346
356
|
if (typeof query !== 'string' || !query.trim().length)
|
|
347
357
|
throw new lapse.Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');
|
|
348
358
|
try {
|
|
349
|
-
void await this.
|
|
359
|
+
void await ensureCookies(this.instance);
|
|
350
360
|
const response = await this.instance.get(Client.API_SEARCH_PATH, {
|
|
351
361
|
params: {
|
|
352
362
|
q: query,
|
|
@@ -357,20 +367,19 @@ class Client {
|
|
|
357
367
|
}
|
|
358
368
|
});
|
|
359
369
|
if (response.err !== 0)
|
|
360
|
-
throw new lapse.Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err
|
|
361
|
-
return response.data.items.map(refined.createSearchMedia);
|
|
370
|
+
throw new lapse.Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err);
|
|
371
|
+
return (response.data.items ?? []).map(refined.createSearchMedia);
|
|
362
372
|
}
|
|
363
373
|
catch (error) {
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
throw new lapse.Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
374
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
375
|
+
throw lapse$1;
|
|
367
376
|
}
|
|
368
377
|
}
|
|
369
378
|
async searchList(query) {
|
|
370
379
|
if (typeof query !== 'string' || !query.trim().length)
|
|
371
380
|
throw new lapse.Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');
|
|
372
381
|
try {
|
|
373
|
-
void await this.
|
|
382
|
+
void await ensureCookies(this.instance);
|
|
374
383
|
const response = await this.instance.get(Client.API_SEARCH_PATH, {
|
|
375
384
|
params: {
|
|
376
385
|
q: query,
|
|
@@ -381,20 +390,19 @@ class Client {
|
|
|
381
390
|
}
|
|
382
391
|
});
|
|
383
392
|
if (response.err !== 0)
|
|
384
|
-
throw new lapse.Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err
|
|
393
|
+
throw new lapse.Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err);
|
|
385
394
|
return response.data.items.map(refined.createSearchPlayList);
|
|
386
395
|
}
|
|
387
396
|
catch (error) {
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
throw new lapse.Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
397
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
398
|
+
throw lapse$1;
|
|
391
399
|
}
|
|
392
400
|
}
|
|
393
401
|
async searchArtist(query) {
|
|
394
402
|
if (typeof query !== 'string' || !query.trim().length)
|
|
395
403
|
throw new lapse.Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');
|
|
396
404
|
try {
|
|
397
|
-
void await this.
|
|
405
|
+
void await ensureCookies(this.instance);
|
|
398
406
|
const response = await this.instance.get(Client.API_SEARCH_PATH, {
|
|
399
407
|
params: {
|
|
400
408
|
q: query,
|
|
@@ -405,13 +413,12 @@ class Client {
|
|
|
405
413
|
}
|
|
406
414
|
});
|
|
407
415
|
if (response.err !== 0)
|
|
408
|
-
throw new lapse.Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err
|
|
416
|
+
throw new lapse.Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err);
|
|
409
417
|
return response.data.items.map(refined.createSearchArtist);
|
|
410
418
|
}
|
|
411
419
|
catch (error) {
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
throw new lapse.Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
420
|
+
const lapse$1 = error instanceof lapse.Lapse ? error : new lapse.Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);
|
|
421
|
+
throw lapse$1;
|
|
415
422
|
}
|
|
416
423
|
}
|
|
417
424
|
}
|
package/dist/cjs/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../esm/index.js"],"sourcesContent":["import axios from 'axios';\nimport m3u8stream from 'm3u8stream';\nimport { PassThrough } from 'node:stream';\nimport { URL } from 'node:url';\nimport { Cookies } from './utils/cookies.js';\nimport { createSignature } from './utils/encrypt.js';\nimport { Lapse } from './utils/lapse.js';\nimport { createArtist, createMedia, createSearchMedia, createPlayList, createSearchArtist, createSearchPlayList } from './utils/refined.js';\nimport { Readable } from 'node:stream';\nconst isURL = (value) => {\n try {\n new URL(value);\n return true;\n }\n catch {\n return false;\n }\n};\nclass Client {\n static BASE_URL = 'https://zingmp3.vn/';\n static VERSION_URL_V1 = '1.6.34';\n static VERSION_URL_V2 = '1.13.13';\n static SECRET_KEY_V1 = '2aa2d1c561e809b267f3638c4a307aab';\n static SECRET_KEY_V2 = '10a01dcf33762d3a204cb96429918ff6';\n static API_KEY_V1 = '88265e23d4284f25963e6eedac8fbfa3';\n static API_KEY_V2 = '38e8643fb0dc04e8d65b99994d3dafff';\n static API_VIDEO_PATH = '/api/v2/page/get/video';\n static API_MUSIC_PATH = '/api/v2/song/get/streaming';\n static EXTRA_API_MUSIC_PATH = '/api/song/get-song-info';\n static API_SEARCH_PATH = '/api/v2/search';\n static API_PLAYLIST_PATH = '/api/v2/page/get/playlist';\n static API_MEDIA_DETAILS_PATH = '/api/v2/song/get/info';\n static API_ARTIST_PATH = '/api/v2/page/get/artist';\n static getIDFromURL(url) {\n if (typeof url !== 'string' || !url.trim().length)\n throw new Lapse('URL must be a non-empty string', 'ERROR_INVALID_URL');\n const match = url.match(/\\/([A-Z0-9]{8})\\.html(?:\\?|#|$)/i) || url.match(/^https?:\\/\\/zingmp3\\.vn\\/([^/?#]+)\\/?(?:[?#].*)?$/i);\n if (!match)\n throw new Lapse('Could not extract ID from URL', 'ERROR_INVALID_URL');\n return match[1];\n }\n ctime = Math.floor(Date.now() / 1000).toString();\n instance;\n maxLoad;\n maxHighWaterMark;\n userAgent;\n jar;\n constructor(options = {}) {\n this.maxLoad = options.maxLoad ?? 1024 * 1024;\n this.maxHighWaterMark = options.maxHighWaterMark ?? 16 * 1024;\n this.userAgent = options?.userAgent ?? 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3';\n this.jar = options.jar instanceof Cookies ? options.jar : new Cookies();\n this.instance = axios.create({\n baseURL: Client.BASE_URL,\n params: {\n version: Client.VERSION_URL_V1,\n apiKey: Client.API_KEY_V1,\n ctime: this.ctime\n },\n maxRate: this.maxLoad,\n headers: {\n 'User-Agent': this.userAgent\n }\n });\n this.instance.interceptors.request.use(async (options) => {\n const base = options.baseURL ?? '';\n const url = new URL(options.url ?? '/', base).toString();\n const additionalHeaders = this.jar.applyToHeaders(url);\n for (const [key, value] of Object.entries(additionalHeaders))\n options.headers.set(key, value);\n return options;\n });\n this.instance.interceptors.response.use((response) => {\n const setCookie = response.headers['set-cookie'];\n const requestUrl = response.request?.res?.responseUrl ?? response.config.url;\n if (requestUrl && Array.isArray(setCookie))\n this.jar.setCookies(setCookie, requestUrl);\n return response.data;\n });\n }\n async ensureCookies() {\n if (this.jar.getCookies(Client.BASE_URL).length === 0)\n void await this.instance.get('/');\n }\n async video(videoID) {\n const value = videoID instanceof URL ? videoID.toString() : videoID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n videoID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_VIDEO_PATH, {\n params: {\n id: videoID,\n sig: createSignature(Client.API_VIDEO_PATH, 'ctime=' + this.ctime + 'id=' + videoID + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Video could not be found', 'ERROR_VIDEO_NOT_FOUND', response.err, response);\n const videoURL = response.data?.streaming?.hls?.['720p'] || response.data?.streaming?.hls?.['360p'];\n if (!videoURL || !videoURL.length)\n throw new Lapse('Streaming URL not found', 'ERROR_STREAM_URL_NOT_FOUND');\n const source = m3u8stream(videoURL, {\n highWaterMark: this.maxHighWaterMark\n });\n source.once('error', (error) => {\n const lapse = new Lapse('Stream download failed', 'ERROR_STREAM_DOWNLOAD', void 0, error);\n source.destroy(lapse);\n });\n return source;\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Failed to fetch video stream', 'ERROR_VIDEO_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n videoSync(videoID) {\n const video = new PassThrough({ highWaterMark: this.maxHighWaterMark });\n let copySource;\n let closed = false;\n let sourceDestroyed = false;\n const destroy = () => {\n if (!copySource || sourceDestroyed)\n return;\n sourceDestroyed = true;\n if (!copySource)\n return;\n copySource.unpipe(video);\n if (!copySource.destroyed)\n copySource.destroy();\n };\n const closer = () => {\n closed = true;\n destroy();\n };\n video.once('close', closer);\n video.once('error', closer);\n void this.video(videoID)\n .then((source) => {\n copySource = source;\n source.once('error', (error) => {\n const lapse = error instanceof Lapse ? error : new Lapse('Stream download failed', 'ERROR_STREAM_DOWNLOAD', void 0, error);\n video.destroy(lapse);\n });\n if (closed || video.destroyed) {\n destroy();\n return;\n }\n source.pipe(video);\n })\n .catch((error) => {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch video stream', 'ERROR_VIDEO_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n video.destroy(lapse);\n });\n return video;\n }\n async music(musicID) {\n const value = musicID instanceof URL ? musicID.toString() : musicID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n musicID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_MUSIC_PATH, {\n params: {\n id: musicID,\n sig: createSignature(Client.API_MUSIC_PATH, 'ctime=' + this.ctime + 'id=' + musicID + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n let musicURL = response.data?.[320] && response.data[320] !== 'VIP' ? response.data[320] : response.data?.[128];\n if (response.err === -1150) {\n const retry = async (step, before) => {\n if (step > 3)\n throw new Lapse('Music requested by VIP, PRI', 'ERROR_MUSIC_VIP_ONLY', before ? before.err : void 0, before);\n const retryData = await this.instance.get(Client.EXTRA_API_MUSIC_PATH, {\n params: {\n id: musicID,\n api_key: Client.API_KEY_V2,\n sig: createSignature('/song/get-song-info', 'ctime=' + this.ctime + 'id=' + musicID, Client.SECRET_KEY_V2),\n version: void 0,\n apiKey: void 0\n }\n });\n if (retryData.err === 0)\n return retryData.data?.streaming?.default?.[128];\n return retry(step + 1, retryData);\n };\n musicURL = await retry(0);\n }\n if (!musicURL || !musicURL.length)\n throw new Lapse('Streaming URL not found', 'ERROR_STREAM_URL_NOT_FOUND');\n const source = await this.instance.get(musicURL, { responseType: 'stream' });\n source.once('error', (error) => {\n const lapse = new Lapse('Stream download failed', 'ERROR_STREAM_DOWNLOAD', void 0, error);\n source.destroy(lapse);\n });\n return source;\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Failed to fetch music stream', 'ERROR_MUSIC_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n musicSync(musicID) {\n const music = new PassThrough({ highWaterMark: this.maxHighWaterMark });\n let copySource;\n let closed = false;\n let sourceDestroyed = false;\n const destroy = () => {\n if (!copySource || sourceDestroyed)\n return;\n sourceDestroyed = true;\n copySource.unpipe(music);\n if (!copySource.destroyed)\n copySource.destroy();\n };\n const closer = () => {\n closed = true;\n destroy();\n };\n music.once('close', closer);\n music.once('error', closer);\n void this.music(musicID)\n .then((source) => {\n copySource = source;\n source.once('error', (error) => {\n const lapse = error instanceof Lapse ? error : new Lapse('Stream download failed', 'ERROR_STREAM_DOWNLOAD', void 0, error);\n music.destroy(lapse);\n });\n if (closed || music.destroyed) {\n destroy();\n return;\n }\n source.pipe(music);\n })\n .catch((error) => {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch music stream', 'ERROR_MUSIC_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n music.destroy(lapse);\n });\n return music;\n }\n async playlist(playlistID) {\n const value = playlistID instanceof URL ? playlistID.toString() : playlistID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n playlistID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_PLAYLIST_PATH, {\n params: {\n id: playlistID,\n sig: createSignature(Client.API_PLAYLIST_PATH, 'ctime=' + this.ctime + 'id=' + playlistID + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Could not find playlist', 'ERROR_PLAYLIST_NOT_FOUND', response.err, response);\n return createPlayList(response.data);\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Failed to fetch playlist', 'ERROR_PLAYLIST_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n async artist(aliasID) {\n const value = aliasID instanceof URL ? aliasID.toString() : aliasID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n aliasID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_ARTIST_PATH, {\n params: {\n alias: aliasID,\n sig: createSignature(Client.API_ARTIST_PATH, 'ctime=' + this.ctime + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err === -108)\n throw new Lapse('Artist not found', 'ERROR_ARTIST_NOT_FOUND', response.err, response);\n if (response.err !== 0)\n throw new Lapse('Could not fetch artist', 'ERROR_ARTIST_FETCH', response.err, response);\n return createArtist(response.data);\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Failed to fetch artist', 'ERROR_ARTIST_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n async mediaDetails(mediaID) {\n const value = mediaID instanceof URL ? mediaID.toString() : mediaID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n mediaID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_MEDIA_DETAILS_PATH, {\n params: {\n id: mediaID,\n sig: createSignature(Client.API_MEDIA_DETAILS_PATH, 'ctime=' + this.ctime + 'id=' + mediaID + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err === -1023)\n throw new Lapse('Media not found', 'ERROR_MEDIA_NOT_FOUND', response.err, response);\n if (response.err !== 0)\n throw new Lapse('Could not fetch media', 'ERROR_MEDIA_FETCH', response.err, response);\n return createMedia(response.data);\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Failed to fetch media', 'ERROR_MEDIA_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n async searchMusic(query) {\n if (typeof query !== 'string' || !query.trim().length)\n throw new Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');\n try {\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_SEARCH_PATH, {\n params: {\n q: query,\n type: 'song',\n page: 1,\n count: 20,\n sig: createSignature(Client.API_SEARCH_PATH, 'count=20ctime=' + this.ctime + 'page=1type=songversion=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err, response);\n return response.data.items.map(createSearchMedia);\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n async searchVideo(query) {\n if (typeof query !== 'string' || !query.trim().length)\n throw new Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');\n try {\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_SEARCH_PATH, {\n params: {\n q: query,\n type: 'video',\n page: 1,\n count: 20,\n sig: createSignature(Client.API_SEARCH_PATH, 'count=20ctime=' + this.ctime + 'page=1type=videoversion=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err, response);\n return response.data.items.map(createSearchMedia);\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n async searchList(query) {\n if (typeof query !== 'string' || !query.trim().length)\n throw new Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');\n try {\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_SEARCH_PATH, {\n params: {\n q: query,\n type: 'playlist',\n page: 1,\n count: 20,\n sig: createSignature(Client.API_SEARCH_PATH, 'count=20ctime=' + this.ctime + 'page=1type=playlistversion=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err, response);\n return response.data.items.map(createSearchPlayList);\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n async searchArtist(query) {\n if (typeof query !== 'string' || !query.trim().length)\n throw new Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');\n try {\n void await this.ensureCookies();\n const response = await this.instance.get(Client.API_SEARCH_PATH, {\n params: {\n q: query,\n type: 'artist',\n page: 1,\n count: 20,\n sig: createSignature(Client.API_SEARCH_PATH, 'count=20ctime=' + this.ctime + 'page=1type=artistversion=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err, response);\n return response.data.items.map(createSearchArtist);\n }\n catch (error) {\n if (error instanceof Lapse)\n throw error;\n throw new Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n }\n }\n}\nconst client = new Client();\nexport { client as default, Client };\n//# sourceMappingURL=index.js.map"],"names":["URL","Lapse","Cookies","createSignature","lapse","PassThrough","createPlayList","createArtist","createMedia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AC,6BAA6B,EAAE,qBAAqB,EAAE,QAAQ,CAAC,GAAG,EAAE,QAAQ,CAAC;AAC7G,YAAY,OAAO,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,GAAG,CAACU,0BAAkB,CAAC;AAC9D,QAAQ;AACR,QAAQ,OAAO,KAAK,EAAE;AACtB,YAAY,IAAI,KAAK,YAAYV,WAAK;AACtC,gBAAgB,MAAM,KAAK;AAC3B,YAAY,MAAM,IAAIA,WAAK,CAAC,2BAA2B,EAAE,oBAAoB,EAAE,KAAK,CAAC,YAAY,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,QAAQ,EAAE,MAAM,GAAG,KAAK,CAAC,EAAE,KAAK,CAAC;AAClJ,QAAQ;AACR,IAAI;AACJ;AACK,MAAC,MAAM,GAAG,IAAI,MAAM;;;;;"}
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../esm/index.js"],"sourcesContent":["import axios from 'axios';\nimport m3u8stream from 'm3u8stream';\nimport { PassThrough } from 'node:stream';\nimport { URL } from 'node:url';\nimport { Cookies } from './utils/cookies.js';\nimport { createSignature } from './utils/encrypt.js';\nimport { Lapse } from './utils/lapse.js';\nimport { createArtist, createMedia, createSearchMedia, createPlayList, createSearchArtist, createSearchPlayList } from './utils/refined.js';\nconst isURL = (value) => {\n try {\n new URL(value);\n return true;\n }\n catch {\n return false;\n }\n};\nconst ensureCookies = async (instance) => await instance.get('/');\nclass Client {\n static BASE_URL = 'https://zingmp3.vn/';\n static VERSION_URL_V1 = '1.6.34';\n static VERSION_URL_V2 = '1.13.13';\n static SECRET_KEY_V1 = '2aa2d1c561e809b267f3638c4a307aab';\n static SECRET_KEY_V2 = '10a01dcf33762d3a204cb96429918ff6';\n static API_KEY_V1 = '88265e23d4284f25963e6eedac8fbfa3';\n static API_KEY_V2 = '38e8643fb0dc04e8d65b99994d3dafff';\n static API_VIDEO_PATH = '/api/v2/page/get/video';\n static API_MUSIC_PATH = '/api/v2/song/get/streaming';\n static EXTRA_API_MUSIC_PATH = '/api/song/get-song-info';\n static API_SEARCH_PATH = '/api/v2/search';\n static API_PLAYLIST_PATH = '/api/v2/page/get/playlist';\n static API_MEDIA_DETAILS_PATH = '/api/v2/song/get/info';\n static API_ARTIST_PATH = '/api/v2/page/get/artist';\n static getIDFromURL(url) {\n if (typeof url !== 'string' || !url.trim().length)\n throw new Lapse('URL must be a non-empty string', 'ERROR_INVALID_URL');\n const match = url.match(/\\/([A-Z0-9]{8})\\.html(?:\\?|#|$)/i) || url.match(/^https?:\\/\\/zingmp3\\.vn\\/([^/?#]+)\\/?(?:[?#].*)?$/i);\n if (!match)\n throw new Lapse('Could not extract ID from URL', 'ERROR_INVALID_URL');\n return match[1];\n }\n ctime = Math.floor(Date.now() / 1000).toString();\n instance;\n maxLoad;\n maxHighWaterMark;\n userAgent;\n jar;\n constructor(options) {\n const mergedOptions = {\n maxLoad: 1024 * 1024,\n maxHighWaterMark: 16 * 1024,\n userAgent: 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3',\n jar: new Cookies(),\n ...options\n };\n this.maxLoad = mergedOptions.maxLoad;\n this.maxHighWaterMark = mergedOptions.maxHighWaterMark;\n this.userAgent = mergedOptions.userAgent;\n this.jar = mergedOptions.jar;\n this.instance = axios.create({\n baseURL: Client.BASE_URL,\n params: {\n version: Client.VERSION_URL_V1,\n apiKey: Client.API_KEY_V1,\n ctime: this.ctime\n },\n maxRate: this.maxLoad\n });\n this.instance.interceptors.request.use(async (options) => {\n const base = options.baseURL ?? '';\n const url = new URL(options.url ?? '/', base).toString();\n options.headers.set('User-Agent', this.userAgent);\n const additionalHeaders = this.jar.applyToHeaders(url);\n for (const [key, value] of Object.entries(additionalHeaders))\n options.headers.set(key, value);\n return options;\n });\n this.instance.interceptors.response.use((response) => {\n const setCookie = response.headers['set-cookie'];\n const requestUrl = response.request?.res?.responseUrl ?? response.config.url;\n if (requestUrl && Array.isArray(setCookie))\n this.jar.setCookies(setCookie, requestUrl);\n return response.data;\n });\n }\n setOptions(options) {\n const mergedOptions = {\n maxLoad: this.maxLoad,\n maxHighWaterMark: this.maxHighWaterMark,\n userAgent: this.userAgent,\n jar: this.jar,\n ...options\n };\n this.maxLoad = mergedOptions.maxLoad;\n this.maxHighWaterMark = mergedOptions.maxHighWaterMark;\n this.userAgent = mergedOptions.userAgent;\n this.jar = mergedOptions.jar;\n this.instance.defaults.maxRate = mergedOptions.maxLoad;\n }\n async video(videoID) {\n const value = videoID instanceof URL ? videoID.toString() : videoID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n videoID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_VIDEO_PATH, {\n params: {\n id: videoID,\n sig: createSignature(Client.API_VIDEO_PATH, 'ctime=' + this.ctime + 'id=' + videoID + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Video could not be found', 'ERROR_VIDEO_NOT_FOUND', response.err);\n const videoURL = response.data?.streaming?.hls?.['720p'] || response.data?.streaming?.hls?.['360p'];\n if (!videoURL || !videoURL.length)\n throw new Lapse('Streaming URL not found', 'ERROR_STREAM_URL_NOT_FOUND');\n const source = m3u8stream(videoURL, {\n highWaterMark: this.maxHighWaterMark\n });\n source.once('error', (error) => {\n const lapse = new Lapse('Stream download failed', 'ERROR_STREAM_DOWNLOAD', void 0, error);\n source.destroy(lapse);\n });\n return source;\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch video stream', 'ERROR_VIDEO_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n videoSync(videoID) {\n const video = new PassThrough({ highWaterMark: this.maxHighWaterMark });\n let copySource;\n let closed = false;\n let sourceDestroyed = false;\n const destroy = () => {\n if (!copySource || sourceDestroyed)\n return;\n sourceDestroyed = true;\n if (!copySource)\n return;\n copySource.unpipe(video);\n if (!copySource.destroyed)\n copySource.destroy();\n };\n const closer = () => {\n closed = true;\n destroy();\n };\n video.once('close', closer);\n video.once('error', closer);\n void this.video(videoID)\n .then((source) => {\n copySource = source;\n source.once('error', (error) => {\n const lapse = error instanceof Lapse ? error : new Lapse('Stream download failed', 'ERROR_STREAM_DOWNLOAD', void 0, error);\n video.destroy(lapse);\n });\n if (closed || video.destroyed) {\n destroy();\n return;\n }\n source.pipe(video);\n })\n .catch((error) => {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch video stream', 'ERROR_VIDEO_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n video.destroy(lapse);\n });\n return video;\n }\n async music(musicID) {\n const value = musicID instanceof URL ? musicID.toString() : musicID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n musicID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_MUSIC_PATH, {\n params: {\n id: musicID,\n sig: createSignature(Client.API_MUSIC_PATH, 'ctime=' + this.ctime + 'id=' + musicID + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n let musicURL = response.data?.[320] && response.data[320] !== 'VIP' ? response.data[320] : response.data?.[128];\n if (response.err === -1150) {\n const retry = async (step, before) => {\n if (step > 3)\n throw new Lapse('Music requested by VIP, PRI', 'ERROR_MUSIC_VIP_ONLY', before ? before.err : void 0);\n const retryData = await this.instance.get(Client.EXTRA_API_MUSIC_PATH, {\n params: {\n id: musicID,\n api_key: Client.API_KEY_V2,\n sig: createSignature('/song/get-song-info', 'ctime=' + this.ctime + 'id=' + musicID, Client.SECRET_KEY_V2),\n version: void 0,\n apiKey: void 0\n }\n });\n if (retryData.err === 0)\n return retryData.data?.streaming?.default?.[128];\n return retry(step + 1, retryData);\n };\n musicURL = await retry(0);\n }\n if (!musicURL || !musicURL.length)\n throw new Lapse('Streaming URL not found', 'ERROR_STREAM_URL_NOT_FOUND');\n const source = await this.instance.get(musicURL, { responseType: 'stream' });\n source.once('error', (error) => {\n const lapse = new Lapse('Stream download failed', 'ERROR_STREAM_DOWNLOAD', void 0, error);\n source.destroy(lapse);\n });\n return source;\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch music stream', 'ERROR_MUSIC_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n musicSync(musicID) {\n const music = new PassThrough({ highWaterMark: this.maxHighWaterMark });\n let copySource;\n let closed = false;\n let sourceDestroyed = false;\n const destroy = () => {\n if (!copySource || sourceDestroyed)\n return;\n sourceDestroyed = true;\n copySource.unpipe(music);\n if (!copySource.destroyed)\n copySource.destroy();\n };\n const closer = () => {\n closed = true;\n destroy();\n };\n music.once('close', closer);\n music.once('error', closer);\n void this.music(musicID)\n .then((source) => {\n copySource = source;\n source.once('error', (error) => {\n const lapse = error instanceof Lapse ? error : new Lapse('Stream download failed', 'ERROR_STREAM_DOWNLOAD', void 0, error);\n music.destroy(lapse);\n });\n if (closed || music.destroyed) {\n destroy();\n return;\n }\n source.pipe(music);\n })\n .catch((error) => {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch music stream', 'ERROR_MUSIC_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n music.destroy(lapse);\n });\n return music;\n }\n async playlist(playlistID) {\n const value = playlistID instanceof URL ? playlistID.toString() : playlistID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n playlistID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_PLAYLIST_PATH, {\n params: {\n id: playlistID,\n sig: createSignature(Client.API_PLAYLIST_PATH, 'ctime=' + this.ctime + 'id=' + playlistID + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Could not find playlist', 'ERROR_PLAYLIST_NOT_FOUND', response.err, response);\n return createPlayList(response.data);\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch playlist', 'ERROR_PLAYLIST_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n async artist(aliasID) {\n const value = aliasID instanceof URL ? aliasID.toString() : aliasID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n aliasID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_ARTIST_PATH, {\n params: {\n alias: aliasID,\n sig: createSignature(Client.API_ARTIST_PATH, 'ctime=' + this.ctime + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err === -108)\n throw new Lapse('Artist not found', 'ERROR_ARTIST_NOT_FOUND', response.err);\n if (response.err !== 0)\n throw new Lapse('Could not fetch artist', 'ERROR_ARTIST_FETCH', response.err);\n return createArtist(response.data);\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch artist', 'ERROR_ARTIST_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n async mediaDetails(mediaID) {\n const value = mediaID instanceof URL ? mediaID.toString() : mediaID;\n if (typeof value !== 'string' || !value.trim().length)\n throw new Lapse('ID must be a non-empty string', 'ERROR_INVALID_ID');\n try {\n mediaID = isURL(value) ? Client.getIDFromURL(value) : value;\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_MEDIA_DETAILS_PATH, {\n params: {\n id: mediaID,\n sig: createSignature(Client.API_MEDIA_DETAILS_PATH, 'ctime=' + this.ctime + 'id=' + mediaID + 'version=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err === -1023)\n throw new Lapse('Media not found', 'ERROR_MEDIA_NOT_FOUND', response.err);\n if (response.err !== 0)\n throw new Lapse('Could not fetch media', 'ERROR_MEDIA_FETCH', response.err);\n return createMedia(response.data);\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Failed to fetch media', 'ERROR_MEDIA_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n async searchMusic(query) {\n if (typeof query !== 'string' || !query.trim().length)\n throw new Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');\n try {\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_SEARCH_PATH, {\n params: {\n q: query,\n type: 'song',\n page: 1,\n count: 20,\n sig: createSignature(Client.API_SEARCH_PATH, 'count=20ctime=' + this.ctime + 'page=1type=songversion=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err);\n return (response.data.items ?? []).map(createSearchMedia);\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n async searchVideo(query) {\n if (typeof query !== 'string' || !query.trim().length)\n throw new Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');\n try {\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_SEARCH_PATH, {\n params: {\n q: query,\n type: 'video',\n page: 1,\n count: 20,\n sig: createSignature(Client.API_SEARCH_PATH, 'count=20ctime=' + this.ctime + 'page=1type=videoversion=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err);\n return (response.data.items ?? []).map(createSearchMedia);\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n async searchList(query) {\n if (typeof query !== 'string' || !query.trim().length)\n throw new Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');\n try {\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_SEARCH_PATH, {\n params: {\n q: query,\n type: 'playlist',\n page: 1,\n count: 20,\n sig: createSignature(Client.API_SEARCH_PATH, 'count=20ctime=' + this.ctime + 'page=1type=playlistversion=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err);\n return response.data.items.map(createSearchPlayList);\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n async searchArtist(query) {\n if (typeof query !== 'string' || !query.trim().length)\n throw new Lapse('Query must be a non-empty string', 'ERROR_INVALID_QUERY');\n try {\n void await ensureCookies(this.instance);\n const response = await this.instance.get(Client.API_SEARCH_PATH, {\n params: {\n q: query,\n type: 'artist',\n page: 1,\n count: 20,\n sig: createSignature(Client.API_SEARCH_PATH, 'count=20ctime=' + this.ctime + 'page=1type=artistversion=' + Client.VERSION_URL_V1, Client.SECRET_KEY_V1)\n }\n });\n if (response.err !== 0)\n throw new Lapse('Search could not be fetched', 'ERROR_SEARCH_FAILED', response.err);\n return response.data.items.map(createSearchArtist);\n }\n catch (error) {\n const lapse = error instanceof Lapse ? error : new Lapse('Search could not be fetch', 'ERROR_SEARCH_FETCH', axios.isAxiosError(error) ? error.response?.status : void 0, error);\n throw lapse;\n }\n }\n}\nconst client = new Client();\nexport { client as default, Client };\n//# sourceMappingURL=index.js.map"],"names":["URL","Lapse","Cookies","createSignature","lapse","PassThrough","createPlayList","createArtist","createMedia","createSearchMedia","createSearchPlayList","createSearchArtist"],"mappings":";;;;;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