13.2.5 • Published 3 years ago

discord-v13-giveaways v13.2.5

Weekly downloads
-
License
ISC
Repository
-
Last release
3 years ago

Discord v13 Giveaways - Made by Brunoo#2021

Discord-v13-giveaways is a modified version of discord-giveaways, made for discord.js v13. Together with mongoDB!


Table of contents


Installation

First install Node.js. Then:

$ npm install discord-v13-giveaways

Importing

// Using Node.js `require()`

const { giveawayClient } = require('discord-v13-giveaways')

Support

If you need any help feel free to ask here!

GiveawayClient

Initialising the client

const discord = require('discord.js')

const client = new Discord.Client()

const { giveawayClient } = require('discord-v13-giveaways')

  

/**

* @name GiveawayClient

* @kind constructor

* @param {Client} client

* @param {Object} options Options

* @param {String} [options.mongoURI] mongodb connection string

* @param {String} [options.emoji] emoji for reaction (must be a unicode)

* @param {String} [options.defaultColor] default colors for giveaway embeds

* @description Initiating the giveaway client

*/

  

const giveaway = new giveawayClient(client, {
mongoURI?

emoji?

defaultColor?
})

module.exports = giveaway;

Methods

start

/**

* @method

* @param {Object} options options

* @param {TextChannel} [options.channel] Channel for the giveaway to be in

* @param {Number} [options.time] Duration of this giveaway

* @param {User} [options.hostedBy] Person that hosted the giveaway

* @param {String} [options.description] Description of the giveaway

* @param {Number} [options.winners] Amount of winners for the giveaway

* @param {String} [options.prize] Prize for the giveaway

*/

end

/**

* @method

* @param {String} MessageID Message ID for the giveaway

* @param {Boolean} getWinner Choose a winner?

* @description End a giveaway, choose a winner (optional)

*/

reroll

/**

* @method

* @param {String} channel channel of the giveaway

* @param {String} id message id

* @param {Number} winners amount of winners

* @description Change the winners for a giveaway!

*/

getCurrentGiveaways

/**

* @method

* @param {Boolean} activatedOnly display activated giveaways only?

* @param {Boolean} all display giveaways of all guilds?

* @param {Message} message message if (all = false)

* @description Get data on current giveaways hosted by the bot

*/

removeCachedGiveaways

/**

* @method

* @param {Boolean} all Get data from all guilds?

* @param {String} guildID guild id if all=false

* @description Removes (activated = false) giveaways

*/
13.2.5

3 years ago

13.2.4

3 years ago

13.2.3

3 years ago

13.1.9

3 years ago

13.2.2

3 years ago

13.2.0

3 years ago

13.2.1

3 years ago

13.1.7

3 years ago

13.0.8

3 years ago

13.1.8

3 years ago

13.0.9

3 years ago

13.1.5

3 years ago

13.1.6

3 years ago

13.1.3

3 years ago

13.1.4

3 years ago

13.1.1

3 years ago

13.1.2

3 years ago

13.1.0

3 years ago

13.0.7

3 years ago

13.0.6

3 years ago

13.0.21

3 years ago

13.0.2

3 years ago

13.0.1

3 years ago

13.0.0-0.1

3 years ago

13.0.0

3 years ago