2021-11-26 13:22:36 +05:30
# Play-dl
2021-12-15 17:09:57 +01:00
A **light-weight** YouTube, SoundCloud, Spotify and Deezer streaming and searching library.
- Search by video, playlist/album, channel/artist
- Stream audio from YouTube and SoundCloud
2021-11-26 13:22:36 +05:30
2021-08-24 11:27:29 +05:30
# Why play-dl ?
2021-08-22 18:49:25 +05:30
2021-12-15 17:09:57 +01:00
[ytdl-core ](https://github.com/fent/node-ytdl-core ) has some issues with miniget and also stream abort issues. On the other hand, [youtube-dl ](https://github.com/ytdl-org/youtube-dl ) is a perfect alternative but it takes time to launch. Hence, play-dl is created to avoid these issues along with providing comparatively faster performance than others.
2021-08-22 18:49:25 +05:30
2021-12-15 17:09:57 +01:00
[](https://discord.gg/8H3xWcv3D7)
[](https://www.npmjs.com/package/play-dl)
2021-09-21 13:49:27 +05:30
2021-09-21 13:30:42 +05:30
## Support
2021-12-15 17:09:57 +01:00
You can contact us for support on our [chat server ](https://discord.gg/8H3xWcv3D7 ).
2021-09-21 13:30:42 +05:30
2021-08-22 18:49:25 +05:30
### Installation
2021-08-24 11:27:29 +05:30
2021-12-15 17:09:57 +01:00
**Node.js 16.0.0 or newer is required.**
2021-08-24 11:27:29 +05:30
```bash
2021-08-22 18:49:25 +05:30
npm install play-dl@latest
2021-12-15 17:09:57 +01:00
pnpm add play-dl@latest
yarn add play-dl@latest
2021-08-22 18:49:25 +05:30
```
2021-09-09 12:11:11 +05:30
### Importing
2021-09-21 13:00:38 +05:30
2021-12-15 17:09:57 +01:00
**TypeScript:**
```ts
import play from 'play-dl'; // Everything
import { video_basic_info, stream } from 'play-dl'; // Individual functions
```
**CommonJS modules:**
```js
const play = require('play-dl'); // Everything
// Individual functions by using destructuring
const { video_basic_info, stream } = require('play-dl');
```
**ES6 modules:**
2021-09-09 12:11:11 +05:30
```ts
2021-12-15 17:09:57 +01:00
import * as play from 'play-dl'; // Everything
2021-09-09 12:11:11 +05:30
2021-12-15 17:09:57 +01:00
import { video_basic_info, stream } from 'play-dl'; // Individual functions
2021-09-09 12:11:11 +05:30
```
2021-11-21 14:58:46 +05:30
2021-11-23 11:08:36 +05:30
### [Documentation](https://play-dl.github.io/modules.html)
### [Examples](./examples)
2021-11-23 11:21:43 +05:30
### [Instructions](./instructions)