DBL (Discord Bot Lists) extension library for discord-py-interactions
Project description
interactions-dbl
DBL (Discord Bot Lists) extension library for discord-py-interactions.
Find the supported bot listings here.
Features
- Update server count on most of the bot listings.
Installation
pip install interactions-dbl
Examples
Using bot.py
import interactions
from interactions.ext.dbl import DBLClient
from config import BOT_TOKEN, TOPGG_TOKEN, DBL_TOKEN
if __name__ == '__main__':
bot = interactions.Client(
token=BOT_TOKEN,
intents=interactions.Intents.DEFAULT
)
@bot.event
async def on_ready():
auth = {
"top.gg": TOPGG_TOKEN,
"discordbotlist.com": DBL_TOKEN
}
DBLClient(bot=bot, auth=auth)
bot.start()
Using cogs
import interactions
from interactions.ext.dbl import DBLClient
from config import TOPGG_TOKEN, DBL_TOKEN
class UpdateCount(interactions.Extension):
def __init__(self, bot):
self.bot: interactions.Extension = bot
auth = {
"top.gg": TOPGG_TOKEN,
"discordbotlist.com": DBL_TOKEN
}
DBLClient(bot=self.bot, auth=auth)
def setup(client):
UpdateCount(client)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
interactions-dbl-1.0b2.tar.gz
(5.2 kB
view hashes)
Built Distribution
Close
Hashes for interactions_dbl-1.0b2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 344ff8b048d0a10ae8641541677d258b3d0860dac9dce207a7372262872a7ae1 |
|
MD5 | 452698e599ba52ce097153361f2ee726 |
|
BLAKE2b-256 | b97a56d67a2199f919294d2fa65667700084f48d6c704d1fe3622e94a48596a8 |