This package makes it easy for you to use the discord.bots.gg API
- Download Node.js
- Write in CMD / Terminal:
npm i discordbotsgg.apiconst dbAPI = require('discordbotsgg.api');
const { Client, Intents, } = require('discord.js');
const client = new Client({
intents: [Intents.FLAGS.GUILDS,]
});
client.on('ready', async () => {
console.log(`Logged in as ${client.user.tag}!`);
//PostStats;
await dbAPI.postStats(client, "API_TOKEN", "BOT_ID", false);
});
client.login("TOKEN");| Name | Params | Type | Function | Returns |
|---|---|---|---|---|
| await postStats() | client,api_token,botID,refresh |
Object (Discord.Client),String,String,Boolean |
Posts your Bot Stats automatically, if refresh is true it will update your bot stats every 30 mins |
/ |
| await getBot() | botID,sanitized |
String,Boolean |
Get a bot using ID |
Object ({ Bot }) |
| await getBots() | Query Params | Query Params Types | Search for bots using Query Parameters |
Object |
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.