Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const Discord = require("discord.js"); //Requiring Discord.js
- const config = require(`./config.json`); //Requiring Config,json
- const client = new Discord.Client({intents: ["GUILDS","GUILD_MESSAGES"]}); //Intents
- client.on("messageCreate",message =>{
- if (message.content === "h!ping"){ //Trigger
- message.reply("Pong!") //Reply To The Trigger
- } //You Can Add More If You Want
- })
- console.log("Bot Is Ready") // Simple Code By Dhananjay
- client.login(config.token); // Bot Token In config.json | You Can Install dotenv And Use client.login("proccess.env.TOKEN") Then Make A .env File Then Put Like This TOKEN=YOURTOKEN
Advertisement
Add Comment
Please, Sign In to add comment