index — Deutsche-Haus-Bot @ 97216eb443942ca3a720b3ebbfe5faab65613025

Discord bot to dynamically create voice chats for clubs that boosters can create

test code
crispy-caesus 114518720+crispy-caesus@users.noreply.github.com
Thu, 08 Aug 2024 22:18:24 +0200
commit

97216eb443942ca3a720b3ebbfe5faab65613025

2 files changed, 17 insertions(+), 0 deletions(-)

jump to
A .gitignore

@@ -0,0 +1,2 @@

+bot_token.py +__pycache__/*
A bot.py

@@ -0,0 +1,15 @@

+import discord +import bot_token + +bot = discord.Bot() + +@bot.slash_command() +async def hello(ctx, name: str = None): + name = name or ctx.author.name + await ctx.respond(f"Hello {name}!") + +@bot.user_command(name="Say Hello") +async def hi(ctx, user): + await ctx.respond(f"{ctx.author.mention} says hello to {user.name}!") + +bot.run(bot_token.token)