Security News
cURL Project and Go Security Teams Reject CVSS as Broken
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
discord-msg
Advanced tools
Hi 👋 Discord-Measage Discord-Message - A lightweight and easy to use, framework for discord bots, uses MongoDB.
npm i discord-msg
First things first, we include the module into the project.
const Message = require("discord-msg");
Message.Setup(client, 'DataBase Url')
onMessage({
message,
guildID: GuildID,
userID: UserID
})
AddMessage({
guildID: GuildID,
userID: UserID,
Value: Num
})
SubtractMessage({
guildID: GuildID,
userID: UserID,
Value: Num
})
Fetch({
guildID: GuildID,
userID: UserID,
}).then(count => <Measage>.channel.send(count))
Leaderboard({
guildID: GuildID,
UsersFetch,
}).then(Leader => <Measage>.channel.send(Leader))
const Discord = require('discord.js')
const client = new Discord.Client()
const Message = require('discord-msg')
const prefix = "+"
Setup(client, 'MongoDB DataBase Url')
client.on('message', async message => {
if(message.content.startsWith(prefix + "top")){
if(message.author.bot || !message.guild) return
await Message.Leaderboard({
guildID: message.guild.id,
UsersFetch: 2
}).then(Leader => {
message.channel.send(new Discord.MessageEmbed().setAuthor(message.author.tag, message.author.avatarURL({dynamic: true})).setDescription(Leader).setTimestamp().setFooter(`Leaderboard For: ${message.guild.name}`).setColor('RANDOM'))
})
}
})
client.on('message', async message => {
if(message.author.bot || !message.guild) return
await Message.onMessage({
message,
userID: message.author.id,
guildID: message.guild.id,
})
})
client.on('message', async message => {
if(message.content.startsWith(prefix + "fetch")){
if(message.author.bot || !message.guild) return
let u = message.mentions.users.first()
if(!u) return
await Message.Fetch({
userID: u.id,
guildID: message.guild.id
}).then(count => {
message.channel.send(count)
}).catch(err => console.log(err))
}
})
client.on('message', async message => {
if(message.content.startsWith(prefix + "add")){
if(message.author.bot || !message.guild) return
if(message.author.id == 'Your ID'){
let u = message.mentions.users.first()
if(!u) return
let args = message.content.split(' ').slice(2).join(' ')
if(!args) return
if(args.includes('-')) return message.channel.send('Nice Try Bro')
await Message.AddMessage({
userID: u.id,
guildID: message.guild.id,
value: parseInt(args)
})
message.channel.send('done')
}
}
})
client.on('message', async message => {
if(message.content.startsWith(prefix + "subtract")){
if(message.author.bot || !message.guild) return
if(message.author.id == 'Your ID'){
let u = message.mentions.users.first()
let args = message.content.split(' ').slice(2).join(' ')
if(!args) return
await Message.SubtractMessage({
userID: u.id,
guildID: message.guild.id,
count: args
})
message.channel.send('done')
}
}
})
FAQs
Hi 👋 Discord-Measage Discord-Message - A lightweight and easy to use, framework for discord bots, uses MongoDB.
The npm package discord-msg receives a total of 12 weekly downloads. As such, discord-msg popularity was classified as not popular.
We found that discord-msg demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
cURL and Go security teams are publicly rejecting CVSS as flawed for assessing vulnerabilities and are calling for more accurate, context-aware approaches.
Security News
Bun 1.2 enhances its JavaScript runtime with 90% Node.js compatibility, built-in S3 and Postgres support, HTML Imports, and faster, cloud-first performance.
Security News
Biden's executive order pushes for AI-driven cybersecurity, software supply chain transparency, and stronger protections for federal and open source systems.