Closed Cufee closed 2 years ago
That seems sound. Do you want to throw up a PR for this?
I got the type changed over, but I am still not able to add a file to an existing interaction message. I wonder if that's not something Discord API currently supports Found the issue, updated the PR.
Describe the bug Possibly incorrect type used in as message argument in
Session.EditInteractionResponse(ctx context.Context, interaction *InteractionCreate, message *Message) error
It looks like this type is missing some fields that are available when creating the interaction response. From some discussions on the Discord server, it looks like the right type there might beUpdateMessage
instead ofMessage
.Expected behavior
session.EditInteractionResponse(...)
should acceptUpdateMessage
as type for the message argument.Error messages N/A
Desktop (please complete the following information):
Additional context I am rewriting my bot using Disgord and am looking for a way to edit an interaction message after it has been sent due to a possibility that some commands may take more than 3 seconds to process. The solution I found is to reply to the user interaction instantly with a loading status and edit the message once the response is ready.
The issue I ran into is that I am not able to add new files to the interaction message after it has been sent. I noticed that a recent change was made to
session.SendInteractionResponse
in order to acceptData: CreateInteractionResponseData
, which allows me to add files asCreateMessageFile
, but I am not able to add/edit a file usingCreateMessageFile
throughEditInteractionResponse
.