Deleting ephemeral replies
Is there a way to delete/hide a previous ephemeral reply after user clicks the button? I know
await interaction.deleteReply();
will do it, but im not sure how to point it correctly here so its targeting the previous reply instead of the current one. My thinking is ill need to write a function to do so? fetch interaction.id -> forward it, then delete that id after the new reply is created
4 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!
- ✅
Marked as resolved by OP:method: ChatInputCommandInteraction#deleteReply()
Deletes a reply to this interaction.
:method: InteractionWebhook#deleteMessage()
Delete a message that was sent by this webhook.
Both can be passed a reference to the message to delete
ohhhhh perfect thank you guys so much