Code Monkey home page Code Monkey logo

discord-youtube-stream's Introduction

Discord-YouTube-Stream

Features

Features I have implemented/changed:

  • Playing YouTube videos and livestreams (Not every video works)
  • 1 Command argument instead of 2 (because the bot joins now the voice channel in wich you are)

New commands

  • $play <video-name/link>
  • $live <video-name/link>
  • $site <url (website)>
  • $leave
  • $help

image

Installation

Replace API key, bot token and acceptedAuthors ID

StreamBot/src/config.json:

"token": "SELF BOT ACCOUNT TOKEN HERE",
"youtube_api_key": "YOUR YOUTUBE API KEY HERE",
"acceptedAuthors": ["USER_ID_HERE"],

Click here for a tutorial to get the API key

Install packages

npm install -g typescript
npm install @dank074/discord-video-stream
npm install ytdl
npm install googleapis 

Build and run bot

npm run build 
npm run start 

All features can be accessed by anyone! Except the $site command wich can only be used by the config.acceptedAuthors users!

To change that remove this code part from the index.ts file or move it wherever you want

if (!config.acceptedAuthors.includes(msg.author.id)) {
  await msg.channel.send("This feature is currently not available!");
  return;
} 

discord-youtube-stream's People

Contributors

max1mde avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.