title
DiscordJS Tutorial - Create a Discord Bot from Scratch

description
https://skl.sh/designcourse20 - First 500 people to sign up will get their first 2 months free! -- I've had a lot of requests to cover Discord.js, so here it is! I'm going to show you how to get up and running while assuming you're an absolute newbie. Then, I will show you how to create a bot that kicks people, pulls a random "fail" GIF from an API, and sends it to the chat after performing the kick. Enjoy? Sub up! - - - - - - - - - - - - - - - - - - - - - - Subscribe for NEW VIDEOS! My site: https://designcourse.com My personal FB account: http://fb.com/logodesigner Coursetro FB: http://fb.com/coursetro Coursetro's Twitter: http://twitter.com/designcoursecom Join my Discord! https://discord.gg/a27CKAF ^-Chat with me and others - - - - - - - - - - - - - - - - - - - - - - Who is Gary Simon? Well, I'm a full stack developer with 2+ decades experience and I teach people how to design and code. I've created around 100+ courses for big brands like LinkedIn, Lynda.com, Pluralsight and Envato Network. Now, I focus all of my time and energy on this channel and my website Coursetro.com. Come to my discord server or add me on social media and say Hi!

detail
{'title': 'DiscordJS Tutorial - Create a Discord Bot from Scratch', 'heatmap': [{'end': 382.891, 'start': 330.133, 'weight': 0.771}, {'end': 766.586, 'start': 714.802, 'weight': 0.771}, {'end': 911.773, 'start': 881.394, 'weight': 1}, {'end': 1148.776, 'start': 1094.959, 'weight': 0.739}, {'end': 1217.343, 'start': 1185.651, 'weight': 0.739}], 'summary': 'This tutorial on creating a discord bot using discord.js covers topics like kick commands, bot installation, setting up, dynamic bot commands, and integrating the giphy api, while also mentioning a special skillshare offer for subscribers.', 'chapters': [{'end': 85.875, 'segs': [{'end': 85.875, 'src': 'embed', 'start': 0.129, 'weight': 0, 'content': [{'end': 6.517, 'text': "Today, I'm going to show you how to create a Discord bot and one that allows you to create a custom kick command.", 'start': 0.129, 'duration': 6.388}, {'end': 12.443, 'text': "So kick and we'll put it at test dummy, some random username that I created and hit enter.", 'start': 6.597, 'duration': 5.846}, {'end': 18.631, 'text': "It will kick it and also show a hilarious gif that's pulling from a public API.", 'start': 13.104, 'duration': 5.527}, {'end': 24.622, 'text': "Oh, and hey, I'd like to mention this video's sponsor, Skillshare.com.", 'start': 21.539, 'duration': 3.083}, {'end': 33.13, 'text': "Now it's a brand new year, here in 2019, and Skillshare will help keep you learning and thriving, as they offer 25, 000 different classes in coding,", 'start': 24.842, 'duration': 8.288}, {'end': 34.671, 'text': 'design, business and more.', 'start': 33.13, 'duration': 1.541}, {'end': 40.417, 'text': "For instance, you're about to watch my Discord JS tutorial, but you could watch this full JavaScript course at Skillshare.", 'start': 34.771, 'duration': 5.646}, {'end': 44.738, 'text': 'Skillshare is also super affordable with a subscription that only costs 10 bucks a month.', 'start': 40.657, 'duration': 4.081}, {'end': 50.94, 'text': "But if you're one of the first 500 of my subscribers to click the link below here in the description, you get the first two months free.", 'start': 44.998, 'duration': 5.942}, {'end': 51.84, 'text': 'So take advantage.', 'start': 51.12, 'duration': 0.72}, {'end': 54.261, 'text': "Hey everyone, what's up? Gary Simon of Corsetro.", 'start': 52.14, 'duration': 2.121}, {'end': 59.563, 'text': "So today I'm going to be addressing something that's been in demand.", 'start': 54.621, 'duration': 4.942}, {'end': 64.944, 'text': 'people have been asking me quite frequently how to create a discord bot with discord.js.', 'start': 59.563, 'duration': 5.381}, {'end': 70.628, 'text': "I'm going to make the assumption that some of you who are watching this perhaps aren't developers.", 'start': 65.705, 'duration': 4.923}, {'end': 74.289, 'text': "But you know, you're dealing with JavaScript as it's called.", 'start': 71.568, 'duration': 2.721}, {'end': 80.252, 'text': "So I'm going to going to spend more time, kind of help, help you understand.", 'start': 74.349, 'duration': 5.903}, {'end': 85.875, 'text': 'you know what JavaScript is and in explaining, you know just a little bit more than what I would normally do.', 'start': 80.252, 'duration': 5.623}], 'summary': 'Tutorial on creating a discord bot with custom kick command and skillshare sponsorship, offering 25,000 classes for $10/month.', 'duration': 85.746, 'max_score': 0.129, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0129.jpg'}], 'start': 0.129, 'title': 'Creating discord bot with kick command', 'summary': 'Explains the process of creating a discord bot with a custom kick command using discord js. the tutorial also includes a sponsorship mention by skillshare, offering 25,000 classes for $10 a month with a special offer of the first two months free for the first 500 subscribers.', 'chapters': [{'end': 85.875, 'start': 0.129, 'title': 'Creating discord bot with kick command', 'summary': 'Explains how to create a discord bot with a custom kick command, featuring a tutorial on discord js and a sponsorship mention by skillshare, which offers 25,000 classes in coding, design, business, and more, with a subscription cost of 10 bucks a month and a special offer of the first two months free for the first 500 subscribers.', 'duration': 85.746, 'highlights': ['The tutorial covers creating a Discord bot with a custom kick command and showcasing a hilarious gif from a public API.', 'Skillshare, the sponsor, offers 25,000 classes in coding, design, business, and more, with a subscription cost of 10 bucks a month.', "The first 500 subscribers to click the provided link in the description can get the first two months free on Skillshare's platform.", 'The tutorial aims to help those who are not developers but are dealing with JavaScript, providing additional explanations and insights into JavaScript.']}], 'duration': 85.746, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0129.jpg', 'highlights': ['The tutorial covers creating a Discord bot with a custom kick command and showcasing a hilarious gif from a public API.', 'Skillshare, the sponsor, offers 25,000 classes in coding, design, business, and more, with a subscription cost of 10 bucks a month.', "The first 500 subscribers to click the provided link in the description can get the first two months free on Skillshare's platform.", 'The tutorial aims to help those who are not developers but are dealing with JavaScript, providing additional explanations and insights into JavaScript.']}, {'end': 413.685, 'segs': [{'end': 132.678, 'src': 'embed', 'start': 86.635, 'weight': 0, 'content': [{'end': 90.317, 'text': "So the bot that we're gonna create will check permissions.", 'start': 86.635, 'duration': 3.682}, {'end': 96.7, 'text': "So it'll check whether or not you have the ability or the permissions to kick or ban people.", 'start': 90.497, 'duration': 6.203}, {'end': 108.146, 'text': 'And if so, it will then kick the person that you specify And it will also send in a GIF from an API called Giphy.', 'start': 97.361, 'duration': 10.785}, {'end': 111.687, 'text': "And it's free to use just for testing purposes.", 'start': 108.206, 'duration': 3.481}, {'end': 115.269, 'text': 'And yeah, you could do some really fun stuff with this.', 'start': 112.388, 'duration': 2.881}, {'end': 123.533, 'text': 'And this is definitely not a comprehensive sort of tutorial because Discord.js allows you to do many, many things.', 'start': 116.189, 'duration': 7.344}, {'end': 127.735, 'text': 'But I will help you try to understand how to read the documentation, which is the most important thing.', 'start': 123.893, 'duration': 3.842}, {'end': 132.678, 'text': "All right, so make sure you just subscribe if you haven't yet, and let's go ahead and get started.", 'start': 128.175, 'duration': 4.503}], 'summary': 'Bot checks permissions, kicks/bans, sends gif from giphy api. discord.js tutorial.', 'duration': 46.043, 'max_score': 86.635, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw086635.jpg'}, {'end': 255.046, 'src': 'embed', 'start': 228.474, 'weight': 1, 'content': [{'end': 234.017, 'text': "that's where I store my code projects for apps and websites and all that stuff and Discord bots right?", 'start': 228.474, 'duration': 5.543}, {'end': 242.12, 'text': "So if you're not sure, if you have Node, just Node-V, it'll tell you a version number.", 'start': 234.537, 'duration': 7.583}, {'end': 244.041, 'text': "If not, it'll say it's unrecognized.", 'start': 242.24, 'duration': 1.801}, {'end': 246.442, 'text': 'In that case, you need to install Node.', 'start': 244.781, 'duration': 1.661}, {'end': 255.046, 'text': 'So you just go to Downloads here and you could choose a macOS installer or Windows installer and get these installed.', 'start': 247.202, 'duration': 7.844}], 'summary': 'Store code projects for apps, websites, and discord bots. check node version with node-v. install node if unrecognized. choose macos or windows installer from downloads.', 'duration': 26.572, 'max_score': 228.474, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0228474.jpg'}, {'end': 382.891, 'src': 'heatmap', 'start': 330.133, 'weight': 0.771, 'content': [{'end': 334.318, 'text': "So if I type in, let's see, npm init.", 'start': 330.133, 'duration': 4.185}, {'end': 339.342, 'text': "it's going to give us a series of prompts like what are we calling it?", 'start': 335.339, 'duration': 4.003}, {'end': 340.323, 'text': 'in parentheses?', 'start': 339.342, 'duration': 0.981}, {'end': 343.866, 'text': "it'll be the default thing, the value, if you hit enter.", 'start': 340.323, 'duration': 3.543}, {'end': 344.967, 'text': "so i'm just going to hit enter.", 'start': 343.866, 'duration': 1.101}, {'end': 347.589, 'text': "for all these, it's not important.", 'start': 344.967, 'duration': 2.622}, {'end': 348.469, 'text': 'is this okay?', 'start': 347.589, 'duration': 0.88}, {'end': 349.871, 'text': 'yes, okay.', 'start': 348.469, 'duration': 1.402}, {'end': 351.472, 'text': 'so what just happened?', 'start': 349.871, 'duration': 1.601}, {'end': 362.641, 'text': "is i if we, if we open up this folder either in your windows file viewer or whatever, or your code editor for me i'm going to use,", 'start': 351.472, 'duration': 11.169}, {'end': 368.884, 'text': "i'm going to type code period And that command will work if you have Microsoft Visual Studio Code.", 'start': 362.641, 'duration': 6.243}, {'end': 370.685, 'text': "It's a free code editor from Microsoft.", 'start': 368.924, 'duration': 1.761}, {'end': 373.286, 'text': "It's what I use.", 'start': 371.325, 'duration': 1.961}, {'end': 375.127, 'text': "There's a lot of other alternatives that you can use.", 'start': 373.306, 'duration': 1.821}, {'end': 376.268, 'text': 'You can use Notepad even.', 'start': 375.147, 'duration': 1.121}, {'end': 382.891, 'text': 'But as we can see, we have this package.json file, which the npm init command created.', 'start': 377.308, 'duration': 5.583}], 'summary': 'Using npm init creates a package.json file for the project.', 'duration': 52.758, 'max_score': 330.133, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0330133.jpg'}], 'start': 86.635, 'title': 'Creating and installing a discord bot', 'summary': 'Covers creating a discord bot with permission checking, using the giphy api, and emphasizes the importance of documentation and subscribing to the tutorial. it also explains the process of installing node.js and discord.js using npm, highlighting the steps to check for node.js installation, install node.js if not present, create a directory for the discord bot, and use npm to create a package.json file.', 'chapters': [{'end': 180.524, 'start': 86.635, 'title': 'Creating a discord bot with permission checking', 'summary': 'Discusses creating a discord bot that checks permissions to kick or ban users, sends a gif using the giphy api, and emphasizes the importance of reading documentation and subscribing to the tutorial. it also directs users to the discord.js documentation and a guide for setting up the bot.', 'duration': 93.889, 'highlights': ["The bot will check permissions to kick or ban people and then execute the specified action. The bot will check users' permissions to kick or ban and then carry out the action.", 'It will also send a GIF from the Giphy API for testing purposes. The bot will send a GIF from the Giphy API for testing purposes.', 'Emphasizes the importance of reading the Discord.js documentation and subscribing to the tutorial. Emphasizes the importance of reading the Discord.js documentation and subscribing to the tutorial.', 'Directs users to the Discord.js documentation and a guide for setting up the bot. Directs users to the Discord.js documentation and a guide for setting up the bot.']}, {'end': 413.685, 'start': 181.344, 'title': 'Installing node.js and discord.js with npm', 'summary': 'Explains the process of installing node.js and discord.js using npm, highlighting the steps to check for node.js installation, install node.js if not present, create a directory for the discord bot, and use npm to create a package.json file.', 'duration': 232.341, 'highlights': ["The first step is to check for Node.js installation by typing 'node -v' in the command line, which will display the version number if installed and 'unrecognized' if not present.", 'If Node.js is not installed, the user needs to download and install the macOS or Windows installer from the Node.js website.', "After installing Node.js, it is essential to reload the command line and recheck the installation using 'node -v'.", 'Next, the process involves installing Discord.js using NPM, which is achieved by creating a directory for the Discord bot and using NPM to create a package.json file for the project.']}], 'duration': 327.05, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw086635.jpg', 'highlights': ['The bot will check permissions to kick or ban people and then execute the specified action.', "The first step is to check for Node.js installation by typing 'node -v' in the command line, which will display the version number if installed and 'unrecognized' if not present.", 'It will also send a GIF from the Giphy API for testing purposes.', 'Emphasizes the importance of reading the Discord.js documentation and subscribing to the tutorial.']}, {'end': 657.295, 'segs': [{'end': 439.575, 'src': 'embed', 'start': 414.926, 'weight': 0, 'content': [{'end': 422.53, 'text': "But once we create this file, what we can do is we can type in npm and we'll do install or shorthand is I.", 'start': 414.926, 'duration': 7.604}, {'end': 436.694, 'text': 'And then, well, how do we install discord JS? Well, again, if you forget in the future, come back here and we want to install discord JS right here.', 'start': 424.028, 'duration': 12.666}, {'end': 439.575, 'text': 'So this is the command install discord.js.', 'start': 437.454, 'duration': 2.121}], 'summary': "To install discord.js, type 'npm install discord.js' after creating a file.", 'duration': 24.649, 'max_score': 414.926, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0414926.jpg'}, {'end': 495.873, 'src': 'embed', 'start': 468.505, 'weight': 1, 'content': [{'end': 475.069, 'text': "So what happens now is if we go back here, we'll see we have this node modules folder.", 'start': 468.505, 'duration': 6.564}, {'end': 481.79, 'text': 'And inside of here we have Discord.js along with any other codependencies that it might use.', 'start': 475.609, 'duration': 6.181}, {'end': 486.031, 'text': "So you don't really want to go into these files.", 'start': 483.35, 'duration': 2.681}, {'end': 487.391, 'text': "You don't have to touch them.", 'start': 486.311, 'duration': 1.08}, {'end': 490.312, 'text': 'But this lets you know that it is there.', 'start': 488.331, 'duration': 1.981}, {'end': 495.873, 'text': 'And as you can see in our package.json file, we do have under dependencies Discord.js.', 'start': 490.952, 'duration': 4.921}], 'summary': 'The project contains the node modules folder with discord.js and other dependencies, as indicated in the package.json file.', 'duration': 27.368, 'max_score': 468.505, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0468505.jpg'}, {'end': 582.511, 'src': 'embed', 'start': 515.24, 'weight': 2, 'content': [{'end': 522.563, 'text': 'which means simply just to download it from GitHub and then run npm install and it will install any dependencies that are listed in here,', 'start': 515.24, 'duration': 7.323}, {'end': 526.385, 'text': 'so that you can essentially just pick right back up where you left off with your project.', 'start': 522.563, 'duration': 3.822}, {'end': 533.247, 'text': "OK, I don't want to digress too much, but I'm making the assumption that you know you're the people watching this,", 'start': 527.185, 'duration': 6.062}, {'end': 535.768, 'text': 'or some of them are absolutely beginners to this stuff.', 'start': 533.247, 'duration': 2.521}, {'end': 538.569, 'text': "So that's why I'm spending more time than usual explaining it.", 'start': 535.788, 'duration': 2.781}, {'end': 541.19, 'text': "OK, so now it's installed.", 'start': 539.229, 'duration': 1.961}, {'end': 542.81, 'text': 'Now, what do we do?', 'start': 541.85, 'duration': 0.96}, {'end': 546.791, 'text': 'I again, like I mentioned the first part of this tutorial.', 'start': 543.33, 'duration': 3.461}, {'end': 553.373, 'text': "we're going to be referring back to, or maybe not referring back to, the guide, but it's following the guide here essentially.", 'start': 546.791, 'duration': 6.582}, {'end': 556.275, 'text': 'You could set up a linter.', 'start': 555.094, 'duration': 1.181}, {'end': 558.376, 'text': "And if you don't know what that is, you can click this and find that out.", 'start': 556.295, 'duration': 2.081}, {'end': 560.057, 'text': "I'm not going to do that.", 'start': 558.436, 'duration': 1.621}, {'end': 563.139, 'text': 'The next step is to set up a bot application.', 'start': 560.457, 'duration': 2.682}, {'end': 563.899, 'text': 'All right.', 'start': 563.579, 'duration': 0.32}, {'end': 574.286, 'text': 'So I go to the Discord website, hover over the developers drop down menu, and then click on the developers portal link.', 'start': 564, 'duration': 10.286}, {'end': 575.587, 'text': 'I guess we can just go right there.', 'start': 574.326, 'duration': 1.261}, {'end': 577.108, 'text': 'All right.', 'start': 576.787, 'duration': 0.321}, {'end': 582.511, 'text': 'And we want to click on the applications link.', 'start': 577.968, 'duration': 4.543}], 'summary': 'Tutorial on setting up a bot application, including installing dependencies and following a guide.', 'duration': 67.271, 'max_score': 515.24, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0515240.jpg'}], 'start': 414.926, 'title': 'Installing discord.js and setting up a bot application on discord', 'summary': "Explains installing discord.js using npm, with the command 'npm install discord.js --save', and setting up a bot application on discord, covering cloning a folder from github, installing dependencies, creating a new application, and configuring settings.", 'chapters': [{'end': 495.873, 'start': 414.926, 'title': 'Installing discord.js via npm', 'summary': "Explains how to install discord.js using npm, including adding it as a dependency in the package json file and the creation of the node modules folder, with the key point that the command 'npm install discord.js --save' adds discord.js as a dependency in the package.json file.", 'duration': 80.947, 'highlights': ["The command to install discord.js as a dependency is 'npm install discord.js --save', and it adds Discord.js under dependencies in the package.json file.", 'Creating a node modules folder with Discord.js and any other codependencies after running the install command.', 'Explaining that the node modules folder contains Discord.js and other codependencies, without needing to modify them.']}, {'end': 657.295, 'start': 497.233, 'title': 'Setting up a bot application on discord', 'summary': 'Discusses the process of setting up a bot application on discord, including cloning a folder from github, installing dependencies, creating a new application, and configuring its settings.', 'duration': 160.062, 'highlights': ['The process involves cloning a folder from GitHub and running npm install to install any dependencies, enabling the user to easily resume their project in case of system failure or on a different machine.', 'The chapter provides detailed steps for creating a new application on Discord, including setting up an avatar and providing a description for the bot, with an example of selecting an avatar image.', 'It emphasizes spending more time explaining for beginners, ensuring a clear understanding of the steps involved in setting up the bot application on Discord.', 'The tutorial also mentions the option of setting up a linter and refers to a guide for further information, catering to both beginners and experienced users.', 'The speaker discusses the significance of setting up a bot application and provides insights into its functionalities, aiming to guide users through the entire process.']}], 'duration': 242.369, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0414926.jpg', 'highlights': ["The command to install discord.js as a dependency is 'npm install discord.js --save', and it adds Discord.js under dependencies in the package.json file.", 'Creating a node modules folder with Discord.js and any other codependencies after running the install command.', 'The process involves cloning a folder from GitHub and running npm install to install any dependencies, enabling the user to easily resume their project in case of system failure or on a different machine.', 'The chapter provides detailed steps for creating a new application on Discord, including setting up an avatar and providing a description for the bot, with an example of selecting an avatar image.', 'The tutorial also mentions the option of setting up a linter and refers to a guide for further information, catering to both beginners and experienced users.', 'The speaker discusses the significance of setting up a bot application and provides insights into its functionalities, aiming to guide users through the entire process.']}, {'end': 1262.517, 'segs': [{'end': 703.696, 'src': 'embed', 'start': 657.755, 'weight': 1, 'content': [{'end': 660.176, 'text': "The client ID is something that you're gonna want to know.", 'start': 657.755, 'duration': 2.421}, {'end': 665.399, 'text': 'So next, we have to click on bot, and then we click on add bot.', 'start': 661.016, 'duration': 4.383}, {'end': 667.48, 'text': 'All right, so add a bot to this app.', 'start': 665.979, 'duration': 1.501}, {'end': 674.125, 'text': 'Adding a bot user gives your app visible life in Discord.', 'start': 667.52, 'duration': 6.605}, {'end': 674.885, 'text': 'Okay, blah, blah, blah.', 'start': 674.185, 'duration': 0.7}, {'end': 675.426, 'text': 'Yes, do it.', 'start': 674.905, 'duration': 0.521}, {'end': 678.187, 'text': 'Okay, so a wild bot has appeared.', 'start': 676.366, 'duration': 1.821}, {'end': 679.107, 'text': 'All right.', 'start': 678.207, 'duration': 0.9}, {'end': 686.029, 'text': "So now down here, the thing that's pretty important before we get to this section actually is your token.", 'start': 680.187, 'duration': 5.842}, {'end': 691.251, 'text': "I'm glad they put click to reveal token instead of just showing my token.", 'start': 686.769, 'duration': 4.482}, {'end': 698.353, 'text': "Because if somebody sees and has access to your token, it's basically like having access to the username and password.", 'start': 692.171, 'duration': 6.182}, {'end': 700.914, 'text': 'to any of your online accounts.', 'start': 699.353, 'duration': 1.561}, {'end': 703.696, 'text': "So you don't want to give and show people this token.", 'start': 701.255, 'duration': 2.441}], 'summary': 'Adding a bot user gives your app visible life in discord. token security is crucial.', 'duration': 45.941, 'max_score': 657.755, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0657755.jpg'}, {'end': 766.586, 'src': 'heatmap', 'start': 714.802, 'weight': 0.771, 'content': [{'end': 718.724, 'text': 'And if you want to use it, click on this website or this link rather.', 'start': 714.802, 'duration': 3.922}, {'end': 719.144, 'text': 'And I.', 'start': 718.744, 'duration': 0.4}, {'end': 723.127, 'text': 'We have a link down here that we can use.', 'start': 720.785, 'duration': 2.342}, {'end': 727.369, 'text': 'So these are permissions that we want to give to the bot.', 'start': 723.247, 'duration': 4.122}, {'end': 731.972, 'text': 'So you can manage the server, roles, manage channels, kick and ban members.', 'start': 727.809, 'duration': 4.163}, {'end': 734.553, 'text': "We're making a kick ban bot kind of.", 'start': 732.452, 'duration': 2.101}, {'end': 736.995, 'text': 'So read messages.', 'start': 735.074, 'duration': 1.921}, {'end': 739.616, 'text': 'We can send messages.', 'start': 738.015, 'duration': 1.601}, {'end': 741.377, 'text': 'We can do all that lovely stuff.', 'start': 739.696, 'duration': 1.681}, {'end': 743.578, 'text': 'And you can tag people.', 'start': 742.058, 'duration': 1.52}, {'end': 746.741, 'text': 'or switch all these on if you wish.', 'start': 744.719, 'duration': 2.022}, {'end': 749.985, 'text': 'You also need to put in your client ID.', 'start': 748.123, 'duration': 1.862}, {'end': 756.417, 'text': "So if we go into Right here, we'll have our client ID.", 'start': 750.025, 'duration': 6.392}, {'end': 758.158, 'text': 'We paste that in there.', 'start': 757.137, 'duration': 1.021}, {'end': 760.621, 'text': 'And there we go.', 'start': 759.479, 'duration': 1.142}, {'end': 766.586, 'text': 'So this is the link that we can use to add the bot to the server.', 'start': 760.801, 'duration': 5.785}], 'summary': 'Creating a kick ban bot with permissions including managing server, roles, channels, kicking and banning members. can also read and send messages, tag people, and requires client id for adding to server.', 'duration': 51.784, 'max_score': 714.802, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0714802.jpg'}, {'end': 911.773, 'src': 'heatmap', 'start': 881.394, 'weight': 1, 'content': [{'end': 884.076, 'text': "So I'm going to go back to mine here.", 'start': 881.394, 'duration': 2.682}, {'end': 885.117, 'text': 'Go to bot.', 'start': 884.536, 'duration': 0.581}, {'end': 886.538, 'text': "I'm going to copy the token.", 'start': 885.237, 'duration': 1.301}, {'end': 890, 'text': "And I'm going to paste it in here.", 'start': 888.719, 'duration': 1.281}, {'end': 892.321, 'text': "Except I'm not going to.", 'start': 890.98, 'duration': 1.341}, {'end': 893.302, 'text': "I'm going to do this off screen.", 'start': 892.341, 'duration': 0.961}, {'end': 894.723, 'text': 'I want you guys using my stuff.', 'start': 893.322, 'duration': 1.401}, {'end': 899.706, 'text': 'So once you paste that in, just go ahead and save that file.', 'start': 895.823, 'duration': 3.883}, {'end': 902.988, 'text': 'and go back to your index.js or something like that.', 'start': 900.686, 'duration': 2.302}, {'end': 909.332, 'text': "Okay, so that's the only two things you need to do there in the config.json file.", 'start': 903.988, 'duration': 5.344}, {'end': 911.773, 'text': 'Of course, you can add more things if you wish.', 'start': 909.352, 'duration': 2.421}], 'summary': 'Instructions for configuring a bot: copy token, paste in config.json, and save file.', 'duration': 30.379, 'max_score': 881.394, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0881394.jpg'}, {'end': 963.161, 'src': 'embed', 'start': 933.888, 'weight': 0, 'content': [{'end': 941.992, 'text': 'though they eventually get to the part where you create a configuration file right down here, just as we did in this section.', 'start': 933.888, 'duration': 8.104}, {'end': 950.636, 'text': "okay, so i, after that, let's go ahead and let's actually get, uh, logged in using our token.", 'start': 941.992, 'duration': 8.644}, {'end': 959.199, 'text': 'so to do that, The very first line, we have to actually use or create an instance of Discord.js,', 'start': 950.636, 'duration': 8.563}, {'end': 963.161, 'text': "which we use to install and it's located right here in a node modules folder.", 'start': 959.199, 'duration': 3.962}], 'summary': 'Creating a configuration file and logging in using a token with discord.js.', 'duration': 29.273, 'max_score': 933.888, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0933888.jpg'}, {'end': 1148.776, 'src': 'heatmap', 'start': 1094.959, 'weight': 0.739, 'content': [{'end': 1096.119, 'text': "But again, you don't want to do that.", 'start': 1094.959, 'duration': 1.16}, {'end': 1098.279, 'text': "We're just going to say token right there.", 'start': 1096.159, 'duration': 2.12}, {'end': 1101.4, 'text': "We're grabbing the token property from config.json.", 'start': 1098.299, 'duration': 3.101}, {'end': 1113.108, 'text': "Okay, so now if we want to run this, what we can do is we can use the terminal that's built into Visual Studio Code.", 'start': 1102.58, 'duration': 10.528}, {'end': 1116.951, 'text': 'So view and we can go to terminal.', 'start': 1113.168, 'duration': 3.783}, {'end': 1132.944, 'text': "it shows up down here and we can type in node and then the name of our index.js file assuming you called it the same thing index.js and you'll see console log ready fires right here.", 'start': 1118.411, 'duration': 14.533}, {'end': 1140.513, 'text': 'So also one thing to note is every time you make a change up to here, we can hit control C.', 'start': 1133.891, 'duration': 6.622}, {'end': 1148.776, 'text': 'To get out of it, you have to rerun the node.index.js, just to warn you.', 'start': 1140.513, 'duration': 8.263}], 'summary': 'Using visual studio code, run index.js and access token property from config.json.', 'duration': 53.817, 'max_score': 1094.959, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01094959.jpg'}, {'end': 1177.928, 'src': 'embed', 'start': 1149.357, 'weight': 3, 'content': [{'end': 1153.358, 'text': "You can't just make changes while it's running and think that those are gonna be updated.", 'start': 1149.357, 'duration': 4.001}, {'end': 1156.459, 'text': "So now let's actually make it do something.", 'start': 1154.218, 'duration': 2.241}, {'end': 1168.964, 'text': "So it will say client on message, And in the next parameter, we're going to receive information back from Discord and we'll call it message.", 'start': 1156.859, 'duration': 12.105}, {'end': 1171.725, 'text': 'All right.', 'start': 1171.445, 'duration': 0.28}, {'end': 1174.686, 'text': 'And then I will execute code inside of here.', 'start': 1171.785, 'duration': 2.901}, {'end': 1177.928, 'text': "So if this is confusing, don't worry.", 'start': 1175.326, 'duration': 2.602}], 'summary': 'Explanation of receiving information from discord and executing code inside a client message event.', 'duration': 28.571, 'max_score': 1149.357, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01149357.jpg'}, {'end': 1217.343, 'src': 'heatmap', 'start': 1185.651, 'weight': 0.739, 'content': [{'end': 1191.173, 'text': "We're going to console log our message dot content.", 'start': 1185.651, 'duration': 5.522}, {'end': 1193.214, 'text': "all right, so let's give that a shot.", 'start': 1191.173, 'duration': 2.041}, {'end': 1194.174, 'text': "we'll rerun this.", 'start': 1193.214, 'duration': 0.96}, {'end': 1200.817, 'text': 'just hit the up arrow, uh key on the keyboard to run the previous command and now it says ready.', 'start': 1194.174, 'duration': 6.643}, {'end': 1212.262, 'text': "so now, if i go back to my discord server here and i just type in any message like uh, actually i don't want to do it in my general chat,", 'start': 1200.817, 'duration': 11.445}, {'end': 1213.122, 'text': "i'll go to my seek.", 'start': 1212.262, 'duration': 0.86}, {'end': 1214.523, 'text': "we'll just do here test.", 'start': 1213.122, 'duration': 1.401}, {'end': 1217.343, 'text': "We'll see it just showed up down here.", 'start': 1215.52, 'duration': 1.823}], 'summary': 'Console logged message content and tested in discord server, showing it appeared as expected.', 'duration': 31.692, 'max_score': 1185.651, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01185651.jpg'}], 'start': 657.755, 'title': 'Creating and setting up a discord bot', 'summary': "Covers the process of setting up and creating a discord bot, emphasizing the significance of client id and token security, setting permissions, adding the bot to the server, creating configuration files, and implementing bot functionality using discord.js. it also demonstrates the use of 'client.on message' to log messages from discord.", 'chapters': [{'end': 703.696, 'start': 657.755, 'title': 'Setting up discord bot', 'summary': 'Explains the process of setting up a bot in discord, emphasizing the significance of client id and token security.', 'duration': 45.941, 'highlights': ['The client ID is crucial for setting up a bot in Discord, providing a unique identifier for the bot.', 'The importance of safeguarding the token is stressed as it is likened to sharing username and password for online accounts.']}, {'end': 1262.517, 'start': 704.096, 'title': 'Creating a discord bot', 'summary': "Covers the process of creating a discord bot, including setting permissions, adding the bot to the server, creating configuration files, and implementing bot functionality using discord.js, with a recommendation to refer to the documentation for further details. it also demonstrates the use of 'client.on message' to log messages from discord.", 'duration': 558.421, 'highlights': ['The chapter covers the process of creating a Discord bot, including setting permissions, adding the bot to the server, creating configuration files, and implementing bot functionality using Discord.js, with a recommendation to refer to the documentation for further details. The chapter provides a step-by-step guide to creating a Discord bot, including setting permissions, adding the bot to the server, creating configuration files, and implementing bot functionality using Discord.js. It also recommends referring to the documentation for further details.', "It demonstrates the use of 'client.on message' to log messages from Discord. The transcript demonstrates the use of 'client.on message' to log messages from Discord, showcasing the functionality of the bot in response to user messages."]}], 'duration': 604.762, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw0657755.jpg', 'highlights': ['The chapter provides a step-by-step guide to creating a Discord bot, including setting permissions, adding the bot to the server, creating configuration files, and implementing bot functionality using Discord.js.', 'The client ID is crucial for setting up a bot in Discord, providing a unique identifier for the bot.', 'The importance of safeguarding the token is stressed as it is likened to sharing username and password for online accounts.', "It demonstrates the use of 'client.on message' to log messages from Discord, showcasing the functionality of the bot in response to user messages."]}, {'end': 1860.949, 'segs': [{'end': 1308.69, 'src': 'embed', 'start': 1284.691, 'weight': 0, 'content': [{'end': 1291.894, 'text': 'So how, for instance, would we make it so that it might respond to something that somebody says?', 'start': 1284.691, 'duration': 7.203}, {'end': 1300.838, 'text': 'All right, so what we can do is, instead of just console logging this oops, I meant to put.', 'start': 1292.515, 'duration': 8.323}, {'end': 1301.979, 'text': 'I had to comment that out.', 'start': 1300.838, 'duration': 1.141}, {'end': 1308.69, 'text': "All right, so let's make it so that, you know, right now we're just console logging and that's pretty boring.", 'start': 1302.725, 'duration': 5.965}], 'summary': 'Discussion on enhancing user interaction through responsive programming.', 'duration': 23.999, 'max_score': 1284.691, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01284691.jpg'}, {'end': 1563.35, 'src': 'embed', 'start': 1527.054, 'weight': 2, 'content': [{'end': 1541.294, 'text': "we have a method that will kick the member right dot kick and then we'll say then and we'll pass in the member, And then, once they've been kicked,", 'start': 1527.054, 'duration': 14.24}, {'end': 1544.756, 'text': 'then we can make something happen in here if we wish.', 'start': 1541.294, 'duration': 3.462}, {'end': 1545.796, 'text': 'All right.', 'start': 1545.496, 'duration': 0.3}, {'end': 1550.518, 'text': "So we'll just say message channel send.", 'start': 1545.856, 'duration': 4.662}, {'end': 1556.001, 'text': "And we'll put in, you can actually put any emoticons here.", 'start': 1552.479, 'duration': 3.522}, {'end': 1560.383, 'text': 'So you could just say, oops, wave.', 'start': 1556.101, 'duration': 4.282}, {'end': 1563.35, 'text': 'All right.', 'start': 1563.01, 'duration': 0.34}], 'summary': 'A method to kick a member and send a message with emoticons is discussed.', 'duration': 36.296, 'max_score': 1527.054, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01527054.jpg'}, {'end': 1690.559, 'src': 'embed', 'start': 1663.018, 'weight': 3, 'content': [{'end': 1670.545, 'text': "what we'll do is right now, anybody can use this command to kick anybody out because it's not checking for permissions.", 'start': 1663.018, 'duration': 7.527}, {'end': 1677.351, 'text': 'Only people who have the permissions to be able to kick and ban, like my moderators and myself, should be able to run kick right?', 'start': 1671.146, 'duration': 6.205}, {'end': 1679.473, 'text': 'So we have to put a check on that.', 'start': 1677.912, 'duration': 1.561}, {'end': 1683.036, 'text': "So what we'll do is let me come down here.", 'start': 1680.034, 'duration': 3.002}, {'end': 1690.559, 'text': "uh, control c, i'm going to stop it because i don't want people using it, so no longer will the bot work when you, when you turn it off.", 'start': 1684.077, 'duration': 6.482}], 'summary': 'Implement permission checks to restrict kicking and banning users, stopping unauthorized usage.', 'duration': 27.541, 'max_score': 1663.018, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01663018.jpg'}, {'end': 1838.45, 'src': 'embed', 'start': 1796.331, 'weight': 1, 'content': [{'end': 1797.372, 'text': "I'm gonna try to kick somebody.", 'start': 1796.331, 'duration': 1.041}, {'end': 1806.72, 'text': "All right, so if I type in kick at, we'll just do Michael, watch it work.", 'start': 1798.713, 'duration': 8.007}, {'end': 1810.662, 'text': "it's not going to work.", 'start': 1809.662, 'duration': 1}, {'end': 1824.829, 'text': "But if I try, let's see here, if I go back to mine and I type in kick and I say test dummy again, it works.", 'start': 1811.423, 'duration': 13.406}, {'end': 1832.572, 'text': 'So now we have permission-based bot commands that we can issue to it.', 'start': 1825.269, 'duration': 7.303}, {'end': 1834.413, 'text': 'All right, so now.', 'start': 1833.192, 'duration': 1.221}, {'end': 1838.45, 'text': "Let's say, for instance, we want to make it even more interesting.", 'start': 1835.567, 'duration': 2.883}], 'summary': 'Testing permission-based bot commands successful.', 'duration': 42.119, 'max_score': 1796.331, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01796331.jpg'}], 'start': 1262.657, 'title': 'Building interactive and dynamic bots', 'summary': 'Covers building a bot that listens to messages, displays response time, and can be more interactive, as well as creating a dynamic bot command using javascript, discord.js, and permissions, enabling it to respond to specific messages, kick members, and enforce permission-based commands.', 'chapters': [{'end': 1308.69, 'start': 1262.657, 'title': 'Creating an interactive bot', 'summary': 'Demonstrates building a bot that listens to messages in a server, displaying message content and response time, with the potential to be more interactive.', 'duration': 46.033, 'highlights': ['The bot can display the content of any message sent in the server, showing a response time of 300 milliseconds, providing real-time feedback on message activity.', 'The current bot behavior is static and non-interactive, as it only logs message content without any meaningful action or response.', "The chapter explores enhancing the bot's functionality to enable it to respond to specific messages, shifting from static logging to interactive engagement."]}, {'end': 1860.949, 'start': 1309.171, 'title': 'Creating a dynamic bot command', 'summary': 'Demonstrates the process of creating a dynamic bot command using javascript, discord.js, and permissions, enabling the bot to respond to specific messages, kick members, and enforce permission-based commands.', 'duration': 551.778, 'highlights': ['The chapter demonstrates the process of creating a dynamic bot command using JavaScript, Discord.js, and permissions. The transcript provides a detailed explanation of creating a dynamic bot command in JavaScript using Discord.js and implementing permissions to restrict command usage.', 'Enabling the bot to respond to specific messages and kick members based on message content and mentions. The process involves defining specific message content to trigger bot actions, such as kicking members based on mentioned usernames in the message content.', 'Implementing permission-based commands to restrict bot actions to administrators and moderators. The chapter demonstrates how to enforce permission-based commands by restricting bot actions to specific roles, such as administrators and moderators, using Discord.js.']}], 'duration': 598.292, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01262657.jpg', 'highlights': ["The chapter explores enhancing the bot's functionality to enable it to respond to specific messages, shifting from static logging to interactive engagement.", 'The chapter demonstrates the process of creating a dynamic bot command using JavaScript, Discord.js, and permissions.', 'Enabling the bot to respond to specific messages and kick members based on message content and mentions.', 'Implementing permission-based commands to restrict bot actions to administrators and moderators.']}, {'end': 2361.111, 'segs': [{'end': 1921.817, 'src': 'embed', 'start': 1860.949, 'weight': 0, 'content': [{'end': 1870.455, 'text': 'but what we need to do is we need to tie into some sort of public image or photograph API that allows us to search and return images.', 'start': 1860.949, 'duration': 9.506}, {'end': 1873.876, 'text': "So there's a bunch of them out there, and I only tried one of them.", 'start': 1871.275, 'duration': 2.601}, {'end': 1877.438, 'text': "The first one I found, and it works, and it's called Giphy.", 'start': 1873.896, 'duration': 3.542}, {'end': 1879.5, 'text': 'So if I go back here.', 'start': 1878.299, 'duration': 1.201}, {'end': 1885.044, 'text': 'And I type in Giphy API or something like that.', 'start': 1882.401, 'duration': 2.643}, {'end': 1886.205, 'text': 'All right.', 'start': 1885.905, 'duration': 0.3}, {'end': 1888.328, 'text': 'We have developers.giphy.', 'start': 1886.606, 'duration': 1.722}, {'end': 1894.674, 'text': "And it's going to tell you basically you need to create an account.", 'start': 1889.429, 'duration': 5.245}, {'end': 1899.099, 'text': "And then once you do that, it's free, by the way.", 'start': 1895.655, 'duration': 3.444}, {'end': 1902.243, 'text': 'And then you click create an app.', 'start': 1900.381, 'duration': 1.862}, {'end': 1903.784, 'text': 'I might as well just log in.', 'start': 1902.563, 'duration': 1.221}, {'end': 1904.806, 'text': 'All right.', 'start': 1904.565, 'duration': 0.241}, {'end': 1905.907, 'text': "So I'm already logged in.", 'start': 1904.846, 'duration': 1.061}, {'end': 1907.389, 'text': "Here's my API key.", 'start': 1906.288, 'duration': 1.101}, {'end': 1911.175, 'text': "I'm going to make sure to blur that out.", 'start': 1908.11, 'duration': 3.065}, {'end': 1913.037, 'text': "But you're going to want this.", 'start': 1912.076, 'duration': 0.961}, {'end': 1919.507, 'text': 'So when we go to type in Giphy, JavaScript, GitHub, maybe.', 'start': 1914.119, 'duration': 5.388}, {'end': 1921.817, 'text': 'Here it is.', 'start': 1921.417, 'duration': 0.4}], 'summary': 'Explore using giphy api to search and return images for javascript projects.', 'duration': 60.868, 'max_score': 1860.949, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01860949.jpg'}, {'end': 2115.551, 'src': 'embed', 'start': 2018.651, 'weight': 2, 'content': [{'end': 2020.471, 'text': "We want to call it, we'll call it something else.", 'start': 2018.651, 'duration': 1.82}, {'end': 2022.652, 'text': 'Giphy because clients already defined up here.', 'start': 2020.631, 'duration': 2.021}, {'end': 2030.905, 'text': 'Okay I already went through the documentation to learn how to interface with Giphy.', 'start': 2023.612, 'duration': 7.293}, {'end': 2038.708, 'text': 'So again, you can go back to your own documentation, the documentation for Giphy to figure out more stuff that you can do.', 'start': 2031.946, 'duration': 6.762}, {'end': 2053.69, 'text': "So what we'll do is, once a user has been kicked, which it occurs right here, So it says member kick, then all right,", 'start': 2040.088, 'duration': 13.602}, {'end': 2055.409, 'text': "we're going to need to use Giphy to search.", 'start': 2053.69, 'duration': 1.719}, {'end': 2056.931, 'text': 'All right.', 'start': 2056.63, 'duration': 0.301}, {'end': 2062.192, 'text': "So Giphy, we'll just type in Giphy dot search Giphy.", 'start': 2056.991, 'duration': 5.201}, {'end': 2065.253, 'text': "It's so weird saying that, um, we're going to search for gifts.", 'start': 2062.232, 'duration': 3.021}, {'end': 2070.254, 'text': "That's one of the, um, parameters that the search method uses.", 'start': 2065.413, 'duration': 4.841}, {'end': 2076.235, 'text': 'And then the next parameter we can put in an object queue.', 'start': 2070.333, 'duration': 5.902}, {'end': 2084.681, 'text': 'is. and then right here, this this value is the search term.', 'start': 2079.056, 'duration': 5.625}, {'end': 2088.684, 'text': "so i'm just going to say fail like a fail gif, right.", 'start': 2084.681, 'duration': 4.003}, {'end': 2104.085, 'text': 'so then we take the response and then do something.', 'start': 2088.684, 'duration': 15.401}, {'end': 2111.649, 'text': "When you search for these GIFs, it's going to return up to 25 to 100 different results.", 'start': 2104.405, 'duration': 7.244}, {'end': 2115.551, 'text': 'We only want one, and we want one that is random.', 'start': 2112.689, 'duration': 2.862}], 'summary': 'Using giphy to search for a random fail gif after a user has been kicked.', 'duration': 96.9, 'max_score': 2018.651, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw02018651.jpg'}, {'end': 2319.666, 'src': 'embed', 'start': 2278.053, 'weight': 5, 'content': [{'end': 2281.356, 'text': 'And we want to get just the GIF URL.', 'start': 2278.053, 'duration': 3.303}, {'end': 2288.3, 'text': 'So that happens to be images, fixedheight.url.', 'start': 2282.016, 'duration': 6.284}, {'end': 2290.122, 'text': 'And there we go.', 'start': 2288.36, 'duration': 1.762}, {'end': 2292.031, 'text': 'And that is it.', 'start': 2291.451, 'duration': 0.58}, {'end': 2294.793, 'text': "You can also do, it's a good idea to catch.", 'start': 2292.772, 'duration': 2.021}, {'end': 2304.138, 'text': "If there's an error, you can catch the error and you can just do message channel send.", 'start': 2295.253, 'duration': 8.885}, {'end': 2308.32, 'text': "We can say, I don't know, error.", 'start': 2305.578, 'duration': 2.742}, {'end': 2311.402, 'text': 'Like that.', 'start': 2310.981, 'duration': 0.421}, {'end': 2314.143, 'text': 'Okay All right.', 'start': 2312.002, 'duration': 2.141}, {'end': 2314.763, 'text': "And that's good.", 'start': 2314.183, 'duration': 0.58}, {'end': 2319.666, 'text': "So let's try this and we'll rerun this.", 'start': 2315.083, 'duration': 4.583}], 'summary': 'Retrieve the gif url using images, fixedheight.url. implement error handling.', 'duration': 41.613, 'max_score': 2278.053, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw02278053.jpg'}], 'start': 1860.949, 'title': 'Integrating giphy api in javascript', 'summary': 'Covers the process of integrating the giphy api in javascript to search and return images, requiring the creation of an account, obtaining a free api key, and installing it through specific commands. it also demonstrates how to implement giphy api to send random fail gifs in response to a user being kicked from a discord server using code examples and explanations.', 'chapters': [{'end': 1945.759, 'start': 1860.949, 'title': 'Integrating giphy api for image search', 'summary': 'Discusses the process of integrating the giphy api to search and return images, requiring the creation of an account and obtaining an api key, which is free, and then installing and using it through specific commands and instructions.', 'duration': 84.81, 'highlights': ['The process involves tying into a public image or photograph API, specifically using the Giphy API for image search.', 'Creation of an account is necessary to obtain a free API key for accessing the Giphy API.', 'Detailed instructions are provided for installation and usage of the Giphy API, including specific commands and information.']}, {'end': 2361.111, 'start': 1946.4, 'title': 'Implementing giphy in javascript', 'summary': 'Demonstrates how to integrate giphy api in javascript to search for and send random fail gifs in response to a user being kicked from a discord server, using code examples and explanations.', 'duration': 414.711, 'highlights': ['The code example demonstrates how to use the Giphy API in JavaScript to search for and send a random fail gif in response to a user being kicked from a Discord server.', 'The response from searching for GIFs can return up to 25 to 100 different results, but the code ensures that only one random gif is selected.', 'The implementation includes handling potential errors by catching them and sending an error message if necessary.']}], 'duration': 500.162, 'thumbnail': 'https://coursnap.oss-ap-southeast-1.aliyuncs.com/video-capture/We2ijSkByw0/pics/We2ijSkByw01860949.jpg', 'highlights': ['Creation of an account is necessary to obtain a free API key for accessing the Giphy API.', 'The process involves tying into a public image or photograph API, specifically using the Giphy API for image search.', 'Detailed instructions are provided for installation and usage of the Giphy API, including specific commands and information.', 'The code example demonstrates how to use the Giphy API in JavaScript to search for and send a random fail gif in response to a user being kicked from a Discord server.', 'The response from searching for GIFs can return up to 25 to 100 different results, but the code ensures that only one random gif is selected.', 'The implementation includes handling potential errors by catching them and sending an error message if necessary.']}], 'highlights': ['The tutorial covers creating a Discord bot with a custom kick command and showcasing a hilarious gif from a public API.', 'The bot will check permissions to kick or ban people and then execute the specified action.', "The command to install discord.js as a dependency is 'npm install discord.js --save', and it adds Discord.js under dependencies in the package.json file.", 'The chapter provides a step-by-step guide to creating a Discord bot, including setting permissions, adding the bot to the server, creating configuration files, and implementing bot functionality using Discord.js.', "The chapter explores enhancing the bot's functionality to enable it to respond to specific messages, shifting from static logging to interactive engagement.", 'Creation of an account is necessary to obtain a free API key for accessing the Giphy API.']}