ythnotify

1.0.1 • Public • Published

Youtube Twitch Notify

❯ Library for YouTube video upload and Twitch live detection


Install

# NPM
$ npm install ythnotify
# yarn
$ yarn add ythnotify

How to use?

❯ To use this module, you need a Youtube Data v3 API Key, Twitch API Secreat, and a Client ID.

Youtube API: Click here
Twitch API: Click here

Examples

const Yth = require("ythnotify")
const yth = new Yth.Client({
  youtube: {
    token: "API Key (Youtube Data V3 API) ",
    youtubers: ["https://www.youtube.com/channel/UCzRDCwJdqSSRwI4BgojVkIw"],
  },
  twitch: {
    secreat: "Secreat (Twitch API)",
    clientid: "Client ID (Twitch API)",
    streamers: ["https://www.twitch.tv/whitekj"],
  },
  interval: 60,
})

yth.on("YoutubeUpload", (data) => {
  console.log("New video detected! \n" + data)
})

yth.on("TwitchStreaming", (data) => {
  console.log("Start streaming! \n" + data)
})

Options

❯ General

Name Type Need Default Description
interval Number X 60 time to repeat

❯ Youtube

Name Type Need Default Description
token String O - Youtube Data v3 API's api key
youtubers String or Array O - List of YouTubers to detect uploads

❯ Twitch

Name Type Need Default Description
secreat String O - Twitch API secreat key
clientid String O - Twitch API Client ID
streamers String or Array O - List of Streamers to detect live

Used Code

Youtube Notify: Androz2091's DiscordYoutubeNotifier [ License: None ]

Authors

WhiteKJ, hands8142

License

This repository is MIT licensed.


If you have a problem or want to improve or add features, please make an issue or pull request. Thank you!

Readme

Keywords

Package Sidebar

Install

npm i ythnotify

Weekly Downloads

1

Version

1.0.1

License

MIT

Unpacked Size

34.9 kB

Total Files

11

Last publish

Collaborators

  • whitekj