mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-16 19:28:17 +00:00
add: getWelcomeScreen
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
import { rest } from "../../rest/rest.ts";
|
||||
import { WelcomeScreen } from "../../types/mod.ts";
|
||||
import { endpoints } from "../../util/constants.ts";
|
||||
import { snakeKeysToCamelCase } from "../../util/utils.ts";
|
||||
|
||||
export async function getWelcomeScreen(guildId: string) {
|
||||
const result = await rest.runMethod(
|
||||
"get",
|
||||
endpoints.GUILD_WELCOME_SCREEN(guildId),
|
||||
);
|
||||
|
||||
return snakeKeysToCamelCase<WelcomeScreen>(result);
|
||||
}
|
||||
@@ -41,6 +41,7 @@ import { getGuildPreview } from "./guilds/get_guild_preview.ts";
|
||||
import { getPruneCount } from "./guilds/get_prune_count.ts";
|
||||
import { getVanityURL } from "./guilds/get_vainty_url.ts";
|
||||
import { getVoiceRegions } from "./guilds/get_voice_regions.ts";
|
||||
import { getWelcomeScreen } from "./guilds/get_welcome_screen.ts";
|
||||
import { getWidget } from "./guilds/get_widget.ts";
|
||||
import { getWidgetImageURL } from "./guilds/get_widget_image_url.ts";
|
||||
import { getWidgetSettings } from "./guilds/get_widget_settings.ts";
|
||||
@@ -203,6 +204,7 @@ export {
|
||||
getWebhook,
|
||||
getWebhooks,
|
||||
getWebhookWithToken,
|
||||
getWelcomeScreen,
|
||||
getWidget,
|
||||
getWidgetImageURL,
|
||||
getWidgetSettings,
|
||||
@@ -282,6 +284,7 @@ export let helpers = {
|
||||
getBans,
|
||||
getGuildPreview,
|
||||
getGuild,
|
||||
getWelcomeScreen,
|
||||
getPruneCount,
|
||||
getVanityURL,
|
||||
getVoiceRegions,
|
||||
|
||||
Reference in New Issue
Block a user