mirror of
https://github.com/swc-project/swc.git
synced 2024-12-21 04:32:01 +03:00
32 lines
1.4 KiB
TypeScript
32 lines
1.4 KiB
TypeScript
|
// Loaded from https://deno.land/x/discordeno@11.0.0-rc.2/src/types/webhooks/execute_webhook.ts
|
||
|
|
||
|
|
||
|
import { Embed } from "../embeds/embed.ts";
|
||
|
import { AllowedMentions } from "../messages/allowed_mentions.ts";
|
||
|
import { FileContent } from "../discordeno/file_content.ts";
|
||
|
import { SnakeCasedPropertiesDeep } from "../util.ts";
|
||
|
|
||
|
/** https://discord.com/developers/docs/resources/webhook#execute-webhook */
|
||
|
export interface ExecuteWebhook {
|
||
|
/** Waits for server confirmation of message send before response, and returns the created message body (defaults to `false`; when `false` a message that is not saved does not return an error) */
|
||
|
wait?: boolean;
|
||
|
/** Send a message to the specified thread within a webhook's channel. The thread will automatically be unarchived. */
|
||
|
threadId?: bigint;
|
||
|
/** The message contents (up to 2000 characters) */
|
||
|
content?: string;
|
||
|
/** Override the default username of the webhook */
|
||
|
username?: string;
|
||
|
/** Override the default avatar of the webhook */
|
||
|
avatarUrl?: string;
|
||
|
/** True if this is a TTS message */
|
||
|
tts?: boolean;
|
||
|
/** The contents of the file being sent */
|
||
|
file?: FileContent | FileContent[];
|
||
|
/** Embedded `rich` content */
|
||
|
embeds?: Embed[];
|
||
|
/** Allowed mentions for the message */
|
||
|
allowedMentions?: AllowedMentions;
|
||
|
}
|
||
|
|
||
|
export type DiscordExecuteWebhook = SnakeCasedPropertiesDeep<Omit<ExecuteWebhook, "wait">>;
|