Skip to content
This repository was archived by the owner on Jan 28, 2019. It is now read-only.

Getting Bot Stats

iDerp edited this page Mar 27, 2018 · 2 revisions

How to get bot stats of a specific bot:

First, start by firing off the getBotStats event and supplying an ID.

let botStats = await dbw.getBotStats(BotID)

The function must be awaited or you can use a promise

dbw.getBotStats(BotID).then(botStats => {})

This will return likes, guilds, and shards. To get the information, just grab it from the function like so:

botStats.likes; // Returns the likes of the specified bot.
botStats.guilds; // Returns the guilds of the specified bot.
botStats.shards; // Returns the shards of the specified bot.

Lets say the bot doesn't have any server info posted to DBW, botStats.guilds would instead simply return a null.

Clone this wiki locally