diff --git a/src/helpers/commands/get_original_interaction_response.ts b/src/helpers/commands/get_original_interaction_response.ts new file mode 100644 index 000000000..b6009c94f --- /dev/null +++ b/src/helpers/commands/get_original_interaction_response.ts @@ -0,0 +1,15 @@ +import { applicationId } from "../../bot.ts"; +import { rest } from "../../rest/rest.ts"; +import { structures } from "../../structures/mod.ts"; +import type { Message } from "../../types/messages/message.ts"; +import { endpoints } from "../../util/constants.ts"; + +/** Returns the initial Interactio response. Functions the same as Get Webhook Message */ +export async function getOriginalInteractionResponse(token: string) { + const result = await rest.runMethod( + "get", + endpoints.INTERACTION_ORIGINAL_ID_TOKEN(applicationId, token), + ); + + return await structures.createDiscordenoMessage(result); +}