npm.io
1.0.0 • Published 3 years ago

@megatroncupcakes/get-youtube-id-by-url

Licence
MIT
Version
1.0.0
Deps
2
Size
13 kB
Vulns
0
Weekly
0

Get YouTube ID By Url (Node.js Library)

Get YouTube channel or video id by url!

Report Issues

Please report any bugs you discover at https://github.com/MegatronCupcakes/node-get-youtube-id-by-url/issues

Installation

Node.js 12.0.0 or newer is required.

With NPM
npm install @megatroncupcakes/get-youtube-id-by-url

Examples

import { channelId, videoId, channelIconById, channelIconByName } from '@megatroncupcakes/get-youtube-id-by-url'
Get YouTube Channel ID By Url
channelId('YouTube Channel Url').then((id) => {
  console.log(id)
})

Support URL format:

Get YouTube Video ID By Url
videoId('YouTube Video Url').then((id) => {
  console.log(id)
})

Support URL format:

Get YouTube Channel Icon By Channel ID
channelIconById('YouTube Channel ID').then((iconUrl) => {
  console.log(iconUrl)
})
Get YouTube Channel Icon By Channel Name
channelIconByName('YouTube Channel Name').then((iconUrl) => {
  console.log(iconUrl)
})

License

MIT

Keywords