From 762e7ba13d2369845841a8b42a9209aeb817994c Mon Sep 17 00:00:00 2001 From: Nathan Woodburn Date: Sat, 12 Aug 2023 15:38:32 +1000 Subject: [PATCH] bot: Added invite command --- bot.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/bot.py b/bot.py index 766b3ac..0c9b481 100644 --- a/bot.py +++ b/bot.py @@ -5,7 +5,6 @@ from discord import app_commands import requests import dns.resolver - load_dotenv() TOKEN = os.getenv('DISCORD_TOKEN') @@ -95,10 +94,9 @@ async def curl(ctx, url: str): except requests.exceptions.RequestException as e: await ctx.response.send_message(f"An error occurred: {e}") - - - - +@tree.command(name="invite", description="Invite me to your server") +async def invite(ctx): + await ctx.response.send_message("https://discord.com/api/oauth2/authorize?client_id=1006128164218621972&permissions=0&scope=bot",ephemeral=True) async def log(message):