mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-04 01:40:08 +00:00
* feat: base plugin lib idea * fix: stuff * fmt * fix: imports and exports * fix: errors & tests * fix: remove logs
10 lines
404 B
TypeScript
10 lines
404 B
TypeScript
import { Bot } from "../../bot.ts";
|
|
import { DiscordGetGatewayBot } from "../../deps.ts";
|
|
|
|
/** Get the bots Gateway metadata that can help during the operation of large or sharded bots. */
|
|
export async function getGatewayBot(bot: Bot) {
|
|
const result = await bot.rest.runMethod<DiscordGetGatewayBot>(bot.rest, "GET", bot.constants.routes.GATEWAY_BOT());
|
|
|
|
return bot.transformers.gatewayBot(result);
|
|
}
|