1.0.2 • Published 5 years ago
easy-giveaway-discord v1.0.2
easy-giveaway-discord
Usage
const Discord = require("discord.js")
const client = new Discord.Client()
const Giveaway = require("easy-giveaway-discord")
const giveaway = Giveaway(client, {})
//Giveaway has 2 variables: client and options
client.login(token)Giveaway's options object
| name | optional | description | default value | type |
|---|---|---|---|---|
| prefix | yes | This is the prefix your bot will react to. | "?" | string |
| startCmd | yes | This command starts a giveaway. | "giveaway" | string |
| embedColor | yes | Color of the giveaway's embed. | "#7aefe0" | string |
| reactEmote | yes | The emote that you have to react with. | "🎉" | string |
Example:
const Discord = require("discord.js")
const client = new Discord.Client()
const Giveaway = require("easy-giveaway-discord")
const giveaway = Giveaway(client, {'prefix': '?', 'startCmd': 'gstart', 'embedColor': 'RED', 'reactEmote': 'emojihere'})
//you can change value inside {} bracket.
client.login(token)How To Start Giveaway?
You need to have MANAGE_SERVER permission. Then type [prefix]+[startcmd]+[time]+[title]. Example: ?giveaway 10m Test.