moonapi.js

1.0.1 • Public • Published

moonapi.js

NPM Package

Join our discord
Support: https://moonbotlist.ga/dc

Installation

If you have trouble with the installation, please feel free to visit our discord address.

  • npm i moonapi.js

Define Module & Client

const Discord = require("discord.js");
const client = new Discord.Client();
const moonapi = require("moonapi.js");
const dbl = new moonapi("TOKEN-HERE", client);

client.login("BotToken");

Server Count & Shard Count Posting

client.on("ready", async () => {
  dbl.serverCount();
  /* 
  -> Server count posted. 
  or 
  -> Server count & shard count posted.
  */

});

Vote Checking

let hasVote = await dbl.hasVoted("962983504403112017"); // -> User ID
  if(hasVote === true) {
      console.log("Voted")
    } else {
      console.log("Vote please.")
  }
// -> Vote please.

Search on moonbotlist

let botFind = await dbl.search("962983504403112017");
console.log(botFind.username) // -> Allegro

Questions?

Come talk to us here:

Moonbotlist.ga

/moonapi.js/

    Package Sidebar

    Install

    npm i moonapi.js

    Weekly Downloads

    0

    Version

    1.0.1

    License

    MIT

    Unpacked Size

    10.6 kB

    Total Files

    4

    Last publish

    Collaborators

    • moonbotlist