Uplife api give best discord bot hosting script
/* make sure loginMe use then setTimeout so work else not work*/
const UP = require("uplife-api");
UP.start(
"[your Bot TOKEN]",
"[your prefix]",
"[your user id]",
{
ping: "true",
ping color: "#0099ff",
util: "true",
mod: "true",
giveaway: "true",
reaction: "🎉",
giveawaystorage: __dirname+"/giveaways.json",
giveawayembed: "🎉🎉START GIVEAWAY🎉🎉",
giveawaymessage: "🎉🎉start giveaway🎉🎉",
participate: "click to 🎉 participate",
music: "true",
youtubekey: "[your youtube api key]",
economy: "true",
help: "true"
});
const UP = require("uplife-api");
UP.commandHeader({
name: __dirname+"/commands",
})
const UP = require("uplife-api");
exports.run = async (option) => {
option.channel.send(option.ping+"ws");
}
exports.command = {
name:"ping",
aliases: [""]
}
option.bot - get discord.js client option.guilds - get gMessage guild info option.message - get command then message content show option.guilds - get bot all guild list option.author - get info from author option.emojis - get guilds emoji list option.discord - require discord.js package option.mentionUser - message content Frist mention user info show option.mentionChannel - message content Frist mention channel info show option.mentionRole - Frist mention role info show
/* Start react role function */
const UP = require("uplife-api");
UP.reactRoleSetup(__dirname+"/reactionRole.json");
/* Create reaction role by message Id*/
UP.reactionRoleCreate({
messageId: "403303020202", /* replace your message id */
msg: option.msg, /* or message */
react: "💪", /* react */
roleName: "power" /* role name */
});
/* Create reaction role by cmd */
option.channel.send({ embed: {title: "click 💪 to get power role", color: "0099ff" }}).then(msg => {
UP.reactionRoleCreate({
messageId: msg.id,
msg: option.msg, /* or message */
react: "💪", /* react */
roleName: "power" /* role name */
})
});
/* Delete reaction role */
UP.reactionRoleDelete({
react: "💪",
messageId: "403303020202"
});