This commit is contained in:
ITOH
2021-04-06 22:25:26 +02:00
parent 484e995140
commit 96d26605ca
20 changed files with 143 additions and 80 deletions
@@ -1,5 +1,6 @@
import { applicationId } from "../../bot.ts";
import { rest } from "../../rest/rest.ts";
import { EditGlobalApplicationCommand } from "../../types/interactions/edit_global_application_command.ts";
import { endpoints } from "../../util/constants.ts";
import { validateSlashCommands } from "../../util/utils.ts";
@@ -9,7 +10,7 @@ import { validateSlashCommands } from "../../util/utils.ts";
* **NOTE:** Any slash commands that are not specified in this function will be **deleted**. If you don't provide the commandId and rename your command, the command gets a new Id.
*/
export async function upsertSlashCommands(
options: UpsertSlashCommandsOptions[],
options: EditGlobalApplicationCommand[],
guildId?: string,
) {
validateSlashCommands(options);