Added option to pass html body data directly to video_basic_info | video_info | stream functions.
 Fixed Playlist ID regexp to allow multiple playlist ID support.
 Added Dezer advanced search
 Improved Deezer Share Link handling.
 Added cookiesHeaders options to update cookies when using external https request module.
 Added Artists badge in YouTubeChannel Class.
This commit is contained in:
Killer069
2021-11-01 15:43:52 +05:30
committed by GitHub
10 changed files with 54 additions and 34 deletions

View File

@@ -178,3 +178,13 @@ let resource = createAudioResource(source.stream, {
inputType : source.type
}) // This creates resource for playing
```
#### cookieHeaders(headersCookie : `string[]`)
_This is function to update youtube cookies when using external https module._
```js
const res = ... // You need to get response.
play.cookieHeaders(res.headers['set-cookie']) // Updates YouTube Cookies if cookies exists.
```

View File

@@ -50,6 +50,7 @@ let id = extractID(url)
_This are the info options that can be passed as a parameter in `video_info` and `video_basic_info`_
- proxy : Optional parameter to add support of proxies. As of now, HTTPS proxies are only supported. So make sure to get HTTPS proxies only.
- htmldata : `boolean` Set this to true if you are passing a html body as first parameter.
```js
const video = await video_basic_info(url, { proxy : ['url'] }) // Accepts a url which has port in it.
@@ -59,6 +60,10 @@ const video = await video_basic_info(url, {proxy : [{
port : 8080
}]
}) // Or add a json containing hostname and port.
// Use any https package to use proxy and then do this
const video = await video_basic_info(body, { htmldata : true }) // You can use video_info function also.
```
### video_basic_info(url : `string`, options? : [`InfoOptions`](https://github.com/play-dl/play-dl/tree/main/docs/YouTube#infooptions))