mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-16 19:28:17 +00:00
docs(handlers): add jsdoc comment block (#313)
* docs(handlers): add jsdoc comment block * style: format files
This commit is contained in:
@@ -356,6 +356,7 @@ function processEditChannelQueue() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Update a channel's settings. Requires the `MANAGE_CHANNELS` permission for the guild. */
|
||||||
export async function editChannel(
|
export async function editChannel(
|
||||||
channelID: string,
|
channelID: string,
|
||||||
options: ChannelEditOptions,
|
options: ChannelEditOptions,
|
||||||
|
|||||||
@@ -88,6 +88,7 @@ export function guildSplashURL(
|
|||||||
)
|
)
|
||||||
: undefined;
|
: undefined;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** The full URL of the banner from Discords CDN. Undefined if no banner is set. */
|
/** The full URL of the banner from Discords CDN. Undefined if no banner is set. */
|
||||||
export function guildBannerURL(
|
export function guildBannerURL(
|
||||||
guild: Guild,
|
guild: Guild,
|
||||||
|
|||||||
@@ -277,6 +277,7 @@ export async function editMessage(
|
|||||||
return structures.createMessage(result as MessageCreateOptions);
|
return structures.createMessage(result as MessageCreateOptions);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Crosspost a message in a News Channel to following channels. */
|
||||||
export async function publishMessage(channelID: string, messageID: string) {
|
export async function publishMessage(channelID: string, messageID: string) {
|
||||||
const data = await RequestManager.post(
|
const data = await RequestManager.post(
|
||||||
endpoints.CHANNEL_MESSAGE_CROSSPOST(channelID, messageID),
|
endpoints.CHANNEL_MESSAGE_CROSSPOST(channelID, messageID),
|
||||||
|
|||||||
@@ -55,6 +55,7 @@ export async function createWebhook(
|
|||||||
) as Promise<WebhookPayload>;
|
) as Promise<WebhookPayload>;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Execute a webhook with webhook ID and webhook token */
|
||||||
export async function executeWebhook(
|
export async function executeWebhook(
|
||||||
webhookID: string,
|
webhookID: string,
|
||||||
webhookToken: string,
|
webhookToken: string,
|
||||||
@@ -113,6 +114,7 @@ export async function executeWebhook(
|
|||||||
return structures.createMessage(result as MessageCreateOptions);
|
return structures.createMessage(result as MessageCreateOptions);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Returns the new webhook object for the given id. */
|
||||||
export function getWebhook(webhookID: string) {
|
export function getWebhook(webhookID: string) {
|
||||||
return RequestManager.get(endpoints.WEBHOOK_ID(webhookID));
|
return RequestManager.get(endpoints.WEBHOOK_ID(webhookID));
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user