mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-02 08:50:07 +00:00
refactor(helpers): rename executeSlashCommand to sendInteractionResponse (#676)
This commit is contained in:
@@ -10,7 +10,7 @@ import { endpoints } from "../../util/constants.ts";
|
||||
*
|
||||
* NOTE: By default we will suppress mentions. To enable mentions, just pass any mentions object.
|
||||
*/
|
||||
export async function executeSlashCommand(
|
||||
export async function sendInteractionResponse(
|
||||
id: string,
|
||||
token: string,
|
||||
options: SlashCommandResponseOptions,
|
||||
@@ -17,9 +17,9 @@ import { createSlashCommand } from "./commands/create_slash_command.ts";
|
||||
import { deleteSlashCommand } from "./commands/delete_slash_command.ts";
|
||||
import { deleteSlashResponse } from "./commands/delete_slash_response.ts";
|
||||
import { editSlashResponse } from "./commands/edit_slash_response.ts";
|
||||
import { executeSlashCommand } from "./commands/execute_slash_command.ts";
|
||||
import { getSlashCommand } from "./commands/get_slash_command.ts";
|
||||
import { getSlashCommands } from "./commands/get_slash_commands.ts";
|
||||
import { sendInteractionResponse } from "./commands/send_interaction_response.ts";
|
||||
import { upsertSlashCommand } from "./commands/upsert_slash_command.ts";
|
||||
import { upsertSlashCommands } from "./commands/upsert_slash_commands.ts";
|
||||
import { createEmoji } from "./emojis/create_emoji.ts";
|
||||
@@ -168,7 +168,6 @@ export {
|
||||
editWebhookWithToken,
|
||||
editWidget,
|
||||
emojiURL,
|
||||
executeSlashCommand,
|
||||
executeWebhook,
|
||||
fetchMembers,
|
||||
followChannel,
|
||||
@@ -229,6 +228,7 @@ export {
|
||||
removeRole,
|
||||
removeUserReaction,
|
||||
sendDirectMessage,
|
||||
sendInteractionResponse,
|
||||
sendMessage,
|
||||
startTyping,
|
||||
swapChannels,
|
||||
@@ -264,7 +264,7 @@ export let helpers = {
|
||||
deleteSlashCommand,
|
||||
deleteSlashResponse,
|
||||
editSlashResponse,
|
||||
executeSlashCommand,
|
||||
sendInteractionResponse,
|
||||
getSlashCommand,
|
||||
getSlashCommands,
|
||||
upsertSlashCommand,
|
||||
|
||||
@@ -70,7 +70,7 @@ export interface EditSlashCommandOptions {
|
||||
guildID?: string;
|
||||
}
|
||||
|
||||
export interface ExecuteSlashCommandOptions {
|
||||
export interface SendInteractionResponseOptions {
|
||||
type: InteractionResponseType;
|
||||
data: SlashCommandCallbackData;
|
||||
}
|
||||
|
||||
@@ -215,13 +215,13 @@ export interface EditSlashCommandOptions {
|
||||
options?: SlashCommandOption[];
|
||||
}
|
||||
|
||||
export interface ExecuteSlashCommandOptions {
|
||||
export interface SendInteractionResponseOptions {
|
||||
type: InteractionResponseType;
|
||||
data: SlashCommandCallbackData;
|
||||
}
|
||||
|
||||
export interface SlashCommandResponseOptions
|
||||
extends ExecuteSlashCommandOptions {
|
||||
extends SendInteractionResponseOptions {
|
||||
/** Whether to make this response visible ONLY to the user who used this command. It will also be deleted after some time. */
|
||||
private?: boolean;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user