From 60174e78b8add88ca5204071734f07442f49448f Mon Sep 17 00:00:00 2001 From: "DavidCrompton1192@gmail.com" Date: Wed, 15 Mar 2023 23:45:03 -0400 Subject: [PATCH] Basic Interaction Test --- handyhelper/__init__.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/handyhelper/__init__.py b/handyhelper/__init__.py index 91a17bb..a638252 100644 --- a/handyhelper/__init__.py +++ b/handyhelper/__init__.py @@ -1,6 +1,7 @@ import nextcord as nc from nextcord.ext import commands from typing import Optional +import asyncio import os bot = commands.Bot() @@ -15,6 +16,11 @@ async def summarize( article: str, part: Optional[str] = nc.SlashOption(required=False) ): + await interaction.response.defer(False, True) + + await asyncio.sleep(5) + + await interaction.followup.send(f"I'll summarize {article} for you {interaction.user}") print("Will summarize article.") def main():