const Discord = require("discord.js");
const client = new Discord.Client({
intents: [Discord.Intents.FLAGS.GUILDS, Discord.Intents.FLAGS.GUILD_MEMBERS, Discord.Intents.FLAGS.GUILD_BANS, Discord.Intents.FLAGS.GUILD_MESSAGES, Discord.Intents.FLAGS.DIRECT_MESSAGES]
}); // DISCORD.JS V13
client.on("messageCreate", message => {
if(message.content = "!ping") {
message.channel.send("pong!")
}
})
client.on('ready', () => {
console.log(`Logged in as ${client.user.tag}!`);
});
client.login('YOUR_TOKEN')
const Discord = require("discord.js");
const client = new Discord.Client({
intents: [Discord.Intents.FLAGS.GUILDS, Discord.Intents.GUILD_VOICE_STATES, Discord.Intents.FLAGS.GUILD_MEMBERS, Discord.Intents.FLAGS.GUILD_BANS, Discord.Intents.FLAGS.GUILD_MESSAGES, Discord.Intents.FLAGS.DIRECT_MESSAGES]
});
// discord.js v13