-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 8586218
Showing
96 changed files
with
5,212 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
DISCORD_TOKEN= | ||
MONGO_URL= | ||
REDIS_URL= | ||
REDIS_PASS= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
node_modules | ||
yarn.lock | ||
.env | ||
/dist | ||
logs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
const axios = require("axios"); | ||
const getRandomUA = require("../../utils/functions/getRandomUA"); | ||
const { MessageEmbed } = require("discord.js"); | ||
module.exports = { | ||
name: "advice", | ||
run: async (message) => { | ||
const { data } = await axios("https://api.adviceslip.com/advice", { | ||
headers: { | ||
"User-Agent": getRandomUA(), | ||
}, | ||
}); | ||
const jokeEmbed = new MessageEmbed() | ||
.setColor(3092790) | ||
.setDescription(data.slip.advice); | ||
message.reply({ embeds: [jokeEmbed] }); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
const { MessageEmbed } = require("discord.js"); | ||
|
||
module.exports = { | ||
name: "avatar", | ||
aliases: ["av", "pfp"], | ||
cooldown: 3000, | ||
run: async (message, args) => { | ||
const user = | ||
message.mentions.users.first() || | ||
(args[0] && (await message.client.users.fetch(args[0]))) || | ||
message.author; | ||
const url = user.displayAvatarURL({ dynamic: true, size: 512 }); | ||
const avEmbed = new MessageEmbed() | ||
.setTitle(`Avatar of *${user.tag}*`) | ||
.setImage(url) | ||
.setURL(url) | ||
.setColor(3092790); | ||
message.reply({ embeds: [avEmbed] }); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
const axios = require("axios"); | ||
const getRandomUA = require("../../utils/functions/getRandomUA"); | ||
const { MessageEmbed } = require("discord.js"); | ||
module.exports = { | ||
name: "fact", | ||
run: async (message) => { | ||
const { data } = await axios( | ||
"https://useless-facts.sameerkumar.website/api", | ||
{ | ||
headers: { | ||
"User-Agent": getRandomUA(), | ||
}, | ||
} | ||
); | ||
const jokeEmbed = new MessageEmbed() | ||
.setColor(3092790) | ||
.setDescription(data.data); | ||
message.reply({ embeds: [jokeEmbed] }); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
const axios = require("axios"); | ||
const getRandomUA = require("../../utils/functions/getRandomUA"); | ||
const { MessageEmbed } = require("discord.js"); | ||
module.exports = { | ||
name: "joke", | ||
run: async (message) => { | ||
const { data } = await axios( | ||
"https://official-joke-api.appspot.com/jokes/random", | ||
{ | ||
headers: { | ||
"User-Agent": getRandomUA(), | ||
}, | ||
} | ||
); | ||
const jokeEmbed = new MessageEmbed() | ||
.setColor(3092790) | ||
.setDescription(`**${data.setup}**\n${data.punchline}`); | ||
message.reply({ embeds: [jokeEmbed] }); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
const axios = require("axios"); | ||
const { MessageEmbed } = require("discord.js"); | ||
const getRandomUA = require("../../utils/functions/getRandomUA"); | ||
|
||
module.exports = { | ||
name: "meme", | ||
cooldown: 3000, | ||
run: async (message) => { | ||
const { data } = await axios( | ||
"https://meme-api.herokuapp.com/gimme/wholesomememes/3", | ||
{ | ||
headers: { | ||
"User-Agent": getRandomUA(), | ||
}, | ||
} | ||
); | ||
const memesArray = data.memes.filter((meme) => meme.nsfw === false); | ||
const memeData = memesArray[0]; | ||
const memeEmbed = new MessageEmbed() | ||
.setColor(3092790) | ||
.setAuthor(`${message.client.user?.username} Memes`) | ||
.setImage(memeData.url) | ||
.setDescription(`**[${memeData.title}](${memeData.url})**`) | ||
.setFooter(`👍 ${memeData.ups}`) | ||
.setTimestamp(); | ||
message.reply({ embeds: [memeEmbed] }); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
const axios = require("axios"); | ||
const getRandomUA = require("../../utils/functions/getRandomUA"); | ||
const { MessageEmbed } = require("discord.js"); | ||
module.exports = { | ||
name: "neko", | ||
run: async (message) => { | ||
const { data } = await axios("https://neko-love.xyz/api/v1/neko", { | ||
headers: { | ||
"User-Agent": getRandomUA(), | ||
}, | ||
}); | ||
const jokeEmbed = new MessageEmbed() | ||
.setColor(3092790) | ||
.setImage(data.url); | ||
message.reply({ embeds: [jokeEmbed] }); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
module.exports = { | ||
name: "roast", | ||
cooldown: 3000, | ||
run: async (message, args) => { | ||
const user = | ||
message.mentions.users.first() || | ||
(args[0] && (await message.client.users.fetch(args[0]))) || | ||
message.author; | ||
const answers = [ | ||
"Sup normie?", | ||
"Hey idiot", | ||
"whats up noob", | ||
"Did i ask?", | ||
"I dont care", | ||
"Another idiot", | ||
"The king of loosers", | ||
"BOOMER", | ||
"Novice", | ||
"Normie be like", | ||
"Sup edot", | ||
"Man you should see a mental doctor", | ||
"I am calling FBI now", | ||
"I gotta say you are pretty dumb", | ||
]; | ||
const answer = answers[Math.floor(Math.random() * answers.length)]; | ||
|
||
message.reply(`${user.username}, ${answer}`); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
const axios = require("axios"); | ||
const getRandomUA = require("../../utils/functions/getRandomUA"); | ||
|
||
module.exports = { | ||
name: "kidnap", | ||
run: async (message, args) => { | ||
const user = | ||
message.mentions.users.first() || | ||
(args[0] && (await message.client.users.fetch(args[0]))) || | ||
message.author; | ||
const { data } = await axios("https://nekobot.xyz/api/imagegen", { | ||
params: { | ||
type: "kidnap", | ||
image: user.displayAvatarURL(), | ||
}, | ||
headers: { | ||
"User-Agent": getRandomUA(), | ||
}, | ||
}); | ||
console.log(data); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
const { Util, MessageEmbed } = require("discord.js"); | ||
const errorMessageEmbed = require("../../utils/embeds/errorEmbed"); | ||
module.exports = { | ||
name: "emojiinfo", | ||
aliases: ["einfo", "aboutemoji"], | ||
cooldown: 3000, | ||
description: "give users ping", | ||
category: "misc", | ||
run: async (message, [emote]) => { | ||
const { id } = Util.parseEmoji(emote); | ||
if (!id) { | ||
return errorMessageEmbed( | ||
message, | ||
"Please enter valid emoji/emoji id" | ||
); | ||
} | ||
const emoji = message.guild.emojis.cache.get(id); | ||
if (!emoji) { | ||
return errorMessageEmbed( | ||
message, | ||
"The mentioned emoji doesnot exist in this server, enter an emoji from this server!" | ||
); | ||
} | ||
const anim = emoji.animated ? "Yes" : "No"; | ||
const author = await emoji.fetchAuthor(); | ||
const date = (new Date(emoji.createdTimestamp) / 1000).toFixed(); | ||
const emojiInfoEmbed = new MessageEmbed() | ||
.setAuthor("Emoji Information") | ||
.setColor(3092790) | ||
.setDescription( | ||
`:white_small_square: **Name :**${emoji.name} \n :white_small_square: **Id :**${emoji.id}\n :white_small_square: **Animated :** ${anim}\n :white_small_square: **Added by :** ${author.tag} - ${author.id}\n:white_small_square: **Added on :** <t:${date}:R> \n :white_small_square: **Usage :** \`${emote}\` ` | ||
) | ||
.setImage(emoji.url) | ||
.setTimestamp(); | ||
message.reply({ embeds: [emojiInfoEmbed] }); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
const { MessageEmbed } = require("discord.js"); | ||
const errorMessageEmbed = require("../../utils/embeds/errorEmbed"); | ||
|
||
module.exports = { | ||
name: "roleinfo", | ||
aliases: ["rolei", "ri", "aboutrole"], | ||
cooldown: 3000, | ||
description: "give users ping", | ||
category: "misc", | ||
run: async (message, [id]) => { | ||
const role = | ||
message.mentions.roles.first() || message.guild.roles.cache.get(id); | ||
if (!role) { | ||
return errorMessageEmbed( | ||
message, | ||
"Please enter a valid role/ role id" | ||
); | ||
} | ||
const timestamp = `<t:${( | ||
new Date(role.createdTimestamp) / 1000 | ||
).toFixed()}:R>`; | ||
const managed = role.managed ? "Yes" : "No"; | ||
const hoist = role.hoist ? "Yes" : "No"; | ||
const mention = role.mentionable ? "Yes" : "No"; | ||
const permissions = role.permissions.toArray().join(", "); | ||
const roleinfoEmbed = new MessageEmbed() | ||
.setColor(role.hexColor) | ||
.setTimestamp() | ||
.setAuthor("Role information") | ||
.setDescription( | ||
`:white_small_square: **Name :** ${role.name} \n:white_small_square: **Id :** ${role.id} \n :white_small_square: **Color :** ${role.hexColor} \n :white_small_square: **Created on :** ${timestamp} \n :white_small_square: **Managed :** ${managed} \n :white_small_square: **Displayed seperately :** ${hoist} \n :white_small_square: **Members :** ${role.members.size} \n :white_small_square: **Mentionable :** ${mention} \n :white_small_square: **Permissions :** \`\`\`${permissions}\`\`\` ` | ||
); | ||
message.reply({ embeds: [roleinfoEmbed] }); | ||
}, | ||
}; |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
const { default: axios } = require("axios"); | ||
const { MessageEmbed } = require("discord.js"); | ||
const errorMessageEmbed = require("../../utils/embeds/errorEmbed"); | ||
|
||
module.exports = { | ||
name: "userinfo", | ||
aliases: ["ui", "aboutuser"], | ||
cooldown: 3000, | ||
description: "give users ping", | ||
category: "misc", | ||
run: async (message, [id]) => { | ||
const user = | ||
message.mentions.users.first() || | ||
message.client.users.cache.get(id) || | ||
message.author; | ||
if (!user) { | ||
return errorMessageEmbed( | ||
message, | ||
"Please mentions a valid user/user id" | ||
); | ||
} | ||
const member = message.guild.members.cache.get(user.id); | ||
const { data } = await axios.get( | ||
`https://discord.com/api/users/${user.id}`, | ||
{ | ||
headers: { | ||
Authorization: `Bot ${message.client.token}`, | ||
}, | ||
} | ||
); | ||
const time = `<t:${( | ||
new Date(member.joinedTimestamp) / 1000 | ||
).toFixed()}:R>`; | ||
const cTime = `<t:${( | ||
new Date(member.user.createdTimestamp) / 1000 | ||
).toFixed()}:R>`; | ||
const boostedOn = `<t:${( | ||
new Date(member.premiumSince) / 1000 | ||
).toFixed()}:R>`; | ||
const userInfoEmbed = new MessageEmbed() | ||
.setAuthor("User Information") | ||
.setTimestamp() | ||
.setColor(member.displayHexColor || 3092790) | ||
.setThumbnail( | ||
member.user.displayAvatarURL({ dynamic: true, size: 512 }) | ||
) | ||
.setDescription( | ||
`:white_small_square: **Tag :** ${ | ||
member.user.tag | ||
}\n :white_small_square: **Id :** ${ | ||
user.id | ||
} \n :white_small_square: **Nickname**: ${ | ||
member.nickname || "Not available" | ||
} \n :white_small_square: **Presence :** ${ | ||
member.presence?.status | ||
} \n :white_small_square: **Account created :** ${cTime} \n:white_small_square: **Joined server :** ${time} \n :white_small_square: **Highest role :** <@&${ | ||
member.roles.highest.id | ||
}>\n :white_small_square: **Roles count:** ${ | ||
member.roles.cache.size - 1 | ||
} \n:white_small_square: **Banner :** ${ | ||
data.banner ? "" : "No banner" | ||
}` | ||
); | ||
if (data.banner) { | ||
const extenstion = data.banner.startsWith("a_") ? ".gif" : ".png"; | ||
const url = `https://cdn.discordapp.com/banners/${user.id}/${data.banner}${extenstion}?size=512`; | ||
userInfoEmbed.setImage(url); | ||
} | ||
message.reply({ | ||
embeds: [userInfoEmbed], | ||
}); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
module.exports = { | ||
name: "invites", | ||
run: async (message, args) => { | ||
const { guild } = message; | ||
const user = | ||
message.mentions.users.first() || | ||
(args[0] && (await message.client.users.fetch(args[0]))) || | ||
message.author; | ||
const invites = await guild.invites.fetch(); | ||
let invsOfUser = 0; | ||
invites.forEach((inv) => { | ||
const { uses, inviter } = inv; | ||
if (inviter.tag === user.tag) { | ||
invsOfUser += uses; | ||
} | ||
// message.channel.send({ | ||
// content: `${inviter.tag} has ${uses} invites!`, | ||
// }); | ||
}); | ||
message.reply(`${user.tag} has ${invsOfUser} invites.`); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
const { MessageEmbed } = require("discord.js"); | ||
|
||
module.exports = { | ||
name: "membercount", | ||
aliases: ["mc", "stats"], | ||
cooldown: 3000, | ||
description: "give users ping", | ||
category: "misc", | ||
run: async (message) => { | ||
const memberCountEmbed = new MessageEmbed() | ||
.setDescription(`${message.guild.memberCount}`) | ||
.setColor(3092790) | ||
.setAuthor("Members") | ||
.setTimestamp(); | ||
message.channel.send({ embeds: [memberCountEmbed] }); | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
module.exports = { | ||
name: "ping", | ||
aliases: ["la"], | ||
cooldown: 3000, | ||
description: "give users ping", | ||
category: "misc", | ||
requiredPermission: "ADMINISTRATOR", | ||
run: async (message) => { | ||
message.reply("pong"); | ||
}, | ||
}; |
Oops, something went wrong.