Basic Interaction Test
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
import nextcord as nc
|
import nextcord as nc
|
||||||
from nextcord.ext import commands
|
from nextcord.ext import commands
|
||||||
from typing import Optional
|
from typing import Optional
|
||||||
|
import asyncio
|
||||||
import os
|
import os
|
||||||
|
|
||||||
bot = commands.Bot()
|
bot = commands.Bot()
|
||||||
@@ -15,6 +16,11 @@ async def summarize(
|
|||||||
article: str,
|
article: str,
|
||||||
part: Optional[str] = nc.SlashOption(required=False)
|
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.")
|
print("Will summarize article.")
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|||||||
Reference in New Issue
Block a user