Build a Twitch.tv Chat Bot in 10 Minutes with Node.js – Tutorial – 2019!



Download Node.js – https://nodejs.org/en/
Node.js Tutorial – https://youtu.be/Do_Hsb_Hs3c
Tmi.js Documentation – https://docs.tmijs.org/v1.2.1/Twitch-API.html
Generate OAuth Token – http://twitchapps.com/tmi/

Learn how to build a twitch.tv chat bot in a short time! I would love to see what you guys come up with so please tweet me your repos.

Instagram- @devcoffee_
Twitter – @dev_coffee

https://www.instagram.com/devcoffee_/

source

47 comments

  • Charles Spencer Chaplin 8 months ago

    how to make custom gamble games? or something like that?

  • Thom Benjamin 8 months ago

    Is it possible to make a Twitch Plays Pokemon with this?

  • Calli_Twitch 8 months ago

    Sehr geil! hat alles super Funktoniert ! jede deiner Videos bringe mich ein schritt voran ! danke !!!!

    Schaut Gerne mal Vorbei!!!

    @t

  • Zxy 8 months ago

    [10:17] info: Connecting to irc-ws.chat.twitch.tv on port 80..
    [10:17] info: Sending authentication to server..
    [10:17] error: Improperly formatted auth
    (node:3584) UnhandledPromiseRejectionWarning: Improperly formatted auth
    (node:3584) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
    (node:3584) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process
    with a non-zero exit code.

  • corey bondoc 8 months ago

    How do I set up timers for twitch bot? Also, can you make a video about the counting. I currently have a command in streamelements that counts when my dog does something during stream and would like to have it in the bot that i made.

  • Rohit Sharma YT 8 months ago

    Amazing video dev🚩🙏🚩

  • Preston Roberts 8 months ago

    >>>>>

  • Basement Blueprint 8 months ago

    @dev coffee I am looking to hire someone to program a chat bot for me. Any chance you have interest in join a project?

  • J Ignacio Miranda 8 months ago

    I dont know why the name of my boy is the name of my channel 🙁

  • Kurama 8 months ago

    Hi, dude! Thx for this video. I have a problem. I did the same as you, but bot's name is fully equals to the name of the channel 🙁 I mean the field indentitiy[username] just ingored. What should I do?

  • Thierry Gibbons 8 months ago

    how do I fix when it says "tmi.js.client is not a constructor" when I try and run node index.js ??

  • LumusCode 8 months ago

    I have error in client.on('connected', function(adress, port) {
    client.action('bot_sofia', 'Olá, bot_sofia agora está conectado')
    }) //(node:15023) UnhandledPromiseRejectionWarning: Cannot send anonymous messages.
    (node:15023) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catc
    h block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
    (node:15023) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate t
    he Node.js process with a non-zero exit code.

  • LonlyGamerX 8 months ago

    great tutorial can u make a video on how to make a command that add commands to your bot like !commands [command] [respond] and how to make a command that has a chance of selecting a or b depend like when you type !flipcoin you have 50/50 chance of getting either heads or tails.

  • Миха Миха 8 months ago

    More if statements!

  • Robin Bækken 8 months ago

    I'm trying to make a chat bot right now, but the twitchapps website doesn't work anymore.. What am I supposed to do?

  • Kevin Rosario 8 months ago

    Can you make a video on database connectivity? And github that one?

  • Smokrez 8 months ago

    I have the same program as him on a 64-bit Windows 10, but I can't set it up so it has green/purple/yellow letters at the top. How do I set that up? I created a folder, and called it "SmokrezBot", then dragged it into the program, but it doesn't look the same as yours.

  • TorTor Films 8 months ago

    How do you add it to watch multiple channels

  • Péter Ábele 8 months ago

    Hi! is it a way, that the bot can interact with obs?
    For example if one of the moderators types "!replay" the obs saves the replay buffer and 1 sec later it plays it?

  • Eren Özkur 8 months ago

    where is the download link?

  • JariiTV 8 months ago

    How can we make it so if someone uses command !lurk the bot would automatically lurk the channels while they are live.

  • Acolyte of Torbjörn 8 months ago

    WARNING! HEADS UP! tmi.js was no longer being supported until recently. A fork of the project called twitch-js was made by the community to keep it moving forward, the syntax and EVERYTHING in this video will be exactly the same (minus substituting twitch-js for any occurence of tmi.js) but tmi.js has now been picked up by a single new developer (AlcaDesign). At this stage tmi.js is probably not fully supported with all current twitch functions while the twitch-js project is going strong. Use twitch-js.

  • ouroboricform 8 months ago

    I'm having issues with doing a randomized quotes thing. it works on repl.it but when I take the bot to twitch it tends to just say the same quote over and over again.

  • Daniel Bradbury 8 months ago

    TypeError: tmi.client is not a constructor

    Help?

  • Артем Баранов 8 months ago

    Hey, nice tutorial, it worked out well for me!
    But it seems like this bot has a delay when you try to interact with him right after previous interaction. I have a little delay, like 20 secs, between succesful attempts to talk with bot.
    I thought maybe this is a twitch feature and they do not allow to poll chats too frequently, but it seems like WizeBot has no problem answering on any message.
    Do you have a solution for it? Or maybe iam the only person to have this issue?

  • Moonowl 8 months ago

    do you know why mine says not permitted

  • El Prof 8 months ago

    ….Just went through your older video and now I see this one is up, lol. Obviously I'm watching this one too, just in case anything's different.

  • Srevix 8 months ago

    Hey, What If I want to connect multiple accounts? How does it work?

  • SelfmadeGermany 8 months ago

    Hello from Germany, my Bot can't show the Ban reason.
    My Bot is MOD – Console tell me null or n/a … What is wrong ?

  • BrAM 8 months ago

    Cool, i will learn how to code soon im so hyped i love these types of videos! New subscriber bro

  • Der_Fernfahrer 8 months ago

    Can you tell me why the reason for a Ban is not transmitted ?
    Every time someone is banned with – /ban USERNAME REASON – appears to me – n/a – or – null – in reason

  • sittal 8 months ago

    Super easy to follow, mind throwing your project on GitHub? Great work!

  • laurens dujardin 8 months ago

    witch text editor are you using

  • Mista T 8 months ago

    Hey man great tut! How would you deploy something like this?

  • Steve M 8 months ago

    Please do show how to hook into a database, that would be really helpful!

  • Side 8 months ago

    if you do "npm init -y" it will automate the first prompt.

  • Code Cast 8 months ago

    Good shit Turner

  • Jaku 8 months ago

    Any reason why you used tmi.js instead of twitchJS? tmi.js hasn't really been getting maintained and twitchJS is a fork of tmi.js and has had some nice updates.

  • Ben 8 months ago

    I made a little chat poll bot in NodeJS and also react. Learn all the things at once!

  • Oti 8 months ago

    please go into detail and do more cool stuff

  • Yusbel Rojas 8 months ago

    The quality is low

  • JavaScript Mastery 8 months ago

    Hi, nice tutorial, I just started JavaScript channel myself! Nice to connect with other creators.

  • MrChrisMoo 8 months ago

    kinda blurry.

  • Sean Yeomans 8 months ago

    Good stuff, I am going to start my twitchbot today 🙂

    also, it may help retrain your brain to call ! = 'bang'
    https://english.stackexchange.com/questions/62918/why-is-the-exclamation-mark-called-a-bang

  • My YouTube Channel 8 months ago

    Hey Chris, I think you've switched to Vue from ReactJS, but I just wanted to thank you for your two "ReactJS in 15-ish minutes" videos. They got me started on React (which I love). I had a hard time with the ReactJS mental model until I found your videos. Thanks for those, and happy trails bud.

  • Jan P 8 months ago

    Great to see a new video of yours. Am already familiar with twitch bots, but good to have you back. I hope you can stick with your new years resolution for a while 🤣

  • MrChrisMoo 8 months ago

    Glad to have you back, hopefully everything is ok.

Comments are closed.