diff --git a/src/handlers/guild.ts b/src/handlers/guild.ts index 385b2c017..a0865d759 100644 --- a/src/handlers/guild.ts +++ b/src/handlers/guild.ts @@ -24,6 +24,7 @@ import { PositionSwap, PruneOptions, PrunePayload, + UpdateGuildPayload, UserPayload, } from "../types/guild.ts"; import { MemberCreatePayload } from "../types/member.ts"; @@ -607,3 +608,14 @@ export function getWebhooks(guildID: string) { export function getUser(userID: string) { return RequestManager.get(endpoints.USER(userID)) as Promise; } + +/** + * ⚠️ **If you need this, you are probably doing something wrong. Always use cache.guilds.get() + * + * Advanced Devs: + * This function fetches a guild's data. This is not the same data as a GUILD_CREATE. + * So it does not cache the guild, you must do it manually. + * */ +export function getGuild(guildID: string, counts = true) { + return RequestManager.get(endpoints.GUILD(guildID), { with_counts: counts }) as Promise +}