James-Bennett-295 / npm-youtube-notifs

Receive events from youtube video uploads!

Home Page:https://www.npmjs.com/package/youtube-notifs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Receive events from YouTube video uploads!

View the documentation here.

Have any issues, questions, or suggestions? Open an issue on GitHub.

TypeScript example:

import { PollingNotifier, JsonStorage } from "youtube-notifs";

const notifier = new PollingNotifier({
    interval: 15,
    storage: new JsonStorage("youtube-notifs.json")
});

notifier.onNewVideos = (videos) => {
    for (const video of videos) {
        console.dir(video);
    }
}

notifier.subscribe("UCS0N5baNlQWJCUrhCEo8WlA");

notifier.start();

If using JavaScript, just replace the import line with the following:

const { PollingNotifier, JsonStorage } = require("youtube-notifs");

A program for receiving YouTube notifications on Discord using this package can be found here.

About

Receive events from youtube video uploads!

https://www.npmjs.com/package/youtube-notifs

License:MIT License


Languages

Language:TypeScript 100.0%