Youtube-Cache
A simple Node wrapper of youtube-cache
api used to fetch/store videos you fetch from youtube to save quota reuests.
Requiremnts
- Node 11.x+
- Valid api key
Examples
First let's download youtube-cache
package
NPM
npm i youtube-cache
Yarn
yarn add youtube cache
Create your api client with
const YoutubeCacheClient = ; const cache = "Your-Token-Here";
Fetch youtube video directly by id.
// Using awaittry const result = await cache; const track = resulttrack; console; // Wow we have our fetched video! catcherr // big bad wold // Using chain cache;
Query api by name
// Using await try const result = await cache; const tracks = resulttracks; // Array of Tracks! console; catcherr // error // Using chain cache;
You might say this is really good, but how do I store my videos I fetched from youtube on your api?
Pretty simple
// Using await try const result = await cache; // response object from api; console; catcherr // error // using chain cache;
Road map
Task | Implemeted | Implemented in api |
---|---|---|
Fetch Video By ID | ✅ | ✅ |
Query Video | ✅ | ✅ |
Store video | ✅ | ✅ |
Playlist support | ❌ | ❌ |
Youtube Api | ❌ | ❌ |
In future there will be way to query for playilsts and automaticly use youtube api from this package. Also ability to store multiples video from such playlist.
Access
You must be thinking this is really cool! How can I access it? Well you can message me on discord Cloud#9476
as this is invite only at this current moment.