https://github.com/derhuerst/youtube-metadata-cli
Get metadata on YouTube videos.
https://github.com/derhuerst/youtube-metadata-cli
cli metadata playlist youtube youtube-dl
Last synced: about 1 year ago
JSON representation
Get metadata on YouTube videos.
- Host: GitHub
- URL: https://github.com/derhuerst/youtube-metadata-cli
- Owner: derhuerst
- License: isc
- Created: 2017-06-09T14:41:49.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-06-09T14:44:03.000Z (about 9 years ago)
- Last Synced: 2025-03-28T16:11:46.219Z (over 1 year ago)
- Topics: cli, metadata, playlist, youtube, youtube-dl
- Language: JavaScript
- Homepage: https://github.com/derhuerst/youtube-metadata-cli
- Size: 9.77 KB
- Stars: 7
- Watchers: 2
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: license.md
Awesome Lists containing this project
README
# youtube-metadata-cli
**Get metadata on YouTube videos.** Uses [the wonderful `youtube-dl`](http://rg3.github.io/youtube-dl/). Supports playlists.
[](https://www.npmjs.com/package/youtube-metadata-cli)
[](https://travis-ci.org/derhuerst/youtube-metadata-cli)

[](https://gitter.im/derhuerst)
## Installing
```shell
npm install -g youtube-metadata-cli
```
## Usage
```js
Usage:
youtube-metadata
Options:
--format -f Output format.
Default: csv
Available: csv,ndjson,url
Examples:
youtube-metadata --format url 'https://www.youtube.com/watch?v=IFtmB2U3Clo&list=PLJ7QPuvv91Jsf2mEnwtCaVyxkuLMkRJF6'
```
It will write one line of metadata per video.
`youtube-metadata-cli` can als be used from JavaScript:
```js
const getYoutubeMetadata = require('youtube-metadata-cli')
getYoutubeMetadata('https://www.youtube.com/watch?v=IFtmB2U3Clo&list=PLJ7QPuvv91Jsf2mEnwtCaVyxkuLMkRJF6')
.on('error', console.error)
.on('data', (meta) => {
console.log(meta.display_id, meta.title)
})
```
## Contributing
If you have a question or have difficulties using `youtube-metadata-cli`, please double-check your code and setup first. If you think you have found a bug or want to propose a feature, refer to [the issues page](https://github.com/derhuerst/youtube-metadata-cli/issues).