SuspiciousLookingOwl / scrape-yt

Simple lib to scrape information from youtube such as search results, video information, related videos, playlist information and up next video
https://www.npmjs.com/package/scrape-yt
MIT License
9 stars 3 forks source link

[ENHANCEMENT] add video prop - "isPrivate" #23

Closed moshfeu closed 3 years ago

moshfeu commented 3 years ago

Is your feature request related to a problem? Please describe. For some applications it required to know if the video is private

Describe the solution you'd like Add isPrivate property.

Describe alternatives you've considered 🤷‍♂️

Additional context https://github.com/CodeDotJS/youtube-playlist/blob/459eb95c05d438ffc42c4716c07a7b4bb94c9cc2/index.js#L18

SuspiciousLookingOwl commented 3 years ago

I probably won't add this anytime soon.

I'm considering rewriting the code for this library for v2.0.0 with (hopefully) no breaking changes, as the current code is so messy because this library was made specifically for my small discord bot back then, too lazy to refactor ever since.

I will add this when I started rewriting for 2.0.0.

As for now, I'm just focusing on bug fixes, but PR for new feature will be accepted *wink wink*.

SuspiciousLookingOwl commented 3 years ago

This will be available in v2.0.0 (which is still in progress), as well as isDeleted.

Although I might need to combine them both (isPrivateOrDeleted) since the only way to check whether the video is deleted or private (as far as I know at least) is by checking the title ("[Private video]" / "[Deleted video]" for english), and Youtube can sends different language depending on the location / settings, so there's no way to check unless if I cover the whole available language from Youtube to check which probably isn't gonna be efficient.