Discord.bots.gg API Client for Posting stats or Fetching data
const dbots = require(`@beatx/dbots-sdk`) const api = new dbots.Api('Your discord.bots.gg token')
Library docs
API Reference
Create Discord.bots.gg API instance
Token or options
API Options
Get bot info
await api.getBot('461521980492087297') // returns bot info
Bot ID
Info for bot
Get a list of bots
// Finding by properties await api.getBots({ search: { username: 'shiro', certifiedBot: true ...any other bot object properties } }) // => { results: [ { id: '461521980492087297', username: 'Shiro', discriminator: '8764', lib: 'discord.js', ...rest of bot object } ...other shiro knockoffs B) ], limit: 10, offset: 0, count: 1, total: 1 } // Restricting fields await api.getBots({ fields: ['id', 'username'] }) // => { results: [ { id: '461521980492087297', username: 'Shiro' }, { id: '493716749342998541', username: 'Mimu' }, ... ], ... }
Bot Query
Return response
Get a bots stats
await api.getStats('461521980492087297') // => { serverCount: 28199, shardCount 1, shards: [] }
Stats of bot requested
Post bot stats to Discord.bots.gg
await api.postStats({ serverCount: 28199, shardCount: 1, shardId: 0, })
Stats object
Passed object
Generated using TypeDoc
Discord.bots.gg API Client for Posting stats or Fetching data
Library docs
API Reference