Skip to content
This repository was archived by the owner on Feb 18, 2023. It is now read-only.

Commit 5b70705

Browse files
committed
updated README with 3sec rule
1 parent 3822ebe commit 5b70705

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,9 @@ $client->registerCommand('hello', function (Interaction $interaction, Choices $c
130130
$client->run();
131131
```
132132

133+
Please note that you must always acknowledge the interaction within 3 seconds, otherwise Discord will cancel the interaction.
134+
If you are going to do something that takes time, call the `acknowledge()` function and then add a follow up message using `sendFollowUpMessage()` when ready.
135+
133136
This library only handles slash commands, and there is no support for any other interactions with Discord such as creating channels, sending other messages etc. You can easily combine the DiscordPHP library with this library to have a much larger collection of tools. All you must do is ensure both clients share the same ReactPHP event loop. Here is an example:
134137

135138
```php

0 commit comments

Comments
 (0)