mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-16 11:28:15 +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 { getPruneCount } from "./guilds/get_prune_count.ts";
|
||||||
import { getVanityURL } from "./guilds/get_vainty_url.ts";
|
import { getVanityURL } from "./guilds/get_vainty_url.ts";
|
||||||
import { getVoiceRegions } from "./guilds/get_voice_regions.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 { getWidget } from "./guilds/get_widget.ts";
|
||||||
import { getWidgetImageURL } from "./guilds/get_widget_image_url.ts";
|
import { getWidgetImageURL } from "./guilds/get_widget_image_url.ts";
|
||||||
import { getWidgetSettings } from "./guilds/get_widget_settings.ts";
|
import { getWidgetSettings } from "./guilds/get_widget_settings.ts";
|
||||||
@@ -203,6 +204,7 @@ export {
|
|||||||
getWebhook,
|
getWebhook,
|
||||||
getWebhooks,
|
getWebhooks,
|
||||||
getWebhookWithToken,
|
getWebhookWithToken,
|
||||||
|
getWelcomeScreen,
|
||||||
getWidget,
|
getWidget,
|
||||||
getWidgetImageURL,
|
getWidgetImageURL,
|
||||||
getWidgetSettings,
|
getWidgetSettings,
|
||||||
@@ -282,6 +284,7 @@ export let helpers = {
|
|||||||
getBans,
|
getBans,
|
||||||
getGuildPreview,
|
getGuildPreview,
|
||||||
getGuild,
|
getGuild,
|
||||||
|
getWelcomeScreen,
|
||||||
getPruneCount,
|
getPruneCount,
|
||||||
getVanityURL,
|
getVanityURL,
|
||||||
getVoiceRegions,
|
getVoiceRegions,
|
||||||
|
|||||||
Reference in New Issue
Block a user