Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/harmony/src/managers/guilds.ts>GuildManager

An easy to use Discord API Library for Deno.
Latest
class GuildManager
import { GuildManager } from "https://deno.land/x/harmony@v2.9.1/src/managers/guilds.ts";

Constructors

new
GuildManager(client: Client)

Methods

create(options: GuildCreateOptions): Promise<Guild>

Creates a guild. Returns Guild. Fires guildCreate event.

createFromTemplate(
template: Template | string,
name: string,
icon?: string,
): Promise<Guild>

Create a new guild based on a template.

delete(guild: Guild | string): Promise<Guild | undefined>

Deletes a guild. Returns deleted guild.

edit(
guild: Guild | string,
asRaw: false,
): Promise<Guild>

Edits a guild. Returns edited guild.

edit(
guild: Guild | string,
asRaw: true,
): Promise<GuildPayload>
fetch(id: string): Promise<Guild>
memberCacheSize(guild?: string | Guild): Promise<number>

Returns number of entries in Members Cache. Returns total of all guilds if guild param is not given

preview(guildID: string): Promise<GuildPreview>

Gets a preview of a guild. Returns GuildPreview.

set(key: string, value: GuildPayload): Promise<void>

Sets a value to Cache