Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Guild

Hierarchy

Index

Constructors

constructor

Properties

Optional afkChannelID

afkChannelID: undefined | string

afkTimeout

afkTimeout: number

Optional approximateMemberCount

approximateMemberCount: undefined | number

Optional approximatePresenceCount

approximatePresenceCount: undefined | number

Optional banner

banner: undefined | string

bannerURL

bannerURL: null | string

channels

createdAt

createdAt: number

defaultNotifications

defaultNotifications: number

Optional description

description: undefined | string

emojis

emojis: Emoji[]

explicitContentFilter

explicitContentFilter: number

features

features: string[]

Optional icon

icon: undefined | string

Optional iconURL

iconURL: undefined | string

id

id: string

joinedAt

joinedAt: number

large

large: boolean

maxMembers

maxMembers: number

maxPresences

maxPresences: number

Optional maxVideoChannelUsers

maxVideoChannelUsers: undefined | number

memberCount

memberCount: number

members

members: Collection<Member>

mfaLevel

mfaLevel: number

name

name: string

ownerID

ownerID: string

preferredLocale

preferredLocale: string

Optional premiumSubscriptionCount

premiumSubscriptionCount: undefined | number

premiumTier

premiumTier: number

publicUpdatesChannelID

publicUpdatesChannelID: string

region

region: string

roles

rulesChannelID

rulesChannelID: string

shard

shard: Shard

Optional splash

splash: undefined | string

splashURL

splashURL: null | string

Optional systemChannelID

systemChannelID: undefined | string

unavailable

unavailable: boolean

Optional vanityURL

vanityURL: undefined | string

verificationLevel

verificationLevel: number

Optional widgetChannelID

widgetChannelID: undefined | null | string

Optional widgetEnabled

widgetEnabled: undefined | null | boolean

Methods

addMemberRole

  • addMemberRole(memberID: string, roleID: string, reason?: string): Promise<void>
  • Parameters

    • memberID: string
    • roleID: string
    • Optional reason: string

    Returns Promise<void>

banMember

  • banMember(userID: string, deleteMessageDays?: number, reason?: string): Promise<void>
  • Parameters

    • userID: string
    • Optional deleteMessageDays: number
    • Optional reason: string

    Returns Promise<void>

createChannel

  • Parameters

    • name: string

    Returns Promise<TextChannel>

  • Parameters

    Returns Promise<TextChannel>

  • Parameters

    Returns Promise<VoiceChannel>

  • Parameters

    Returns Promise<CategoryChannel>

  • Parameters

    • name: string
    • Optional type: number
    • Optional reason: string
    • Optional options: string | CreateChannelOptions

    Returns Promise<unknown>

  • Parameters

    Returns Promise<TextChannel>

  • Parameters

    Returns Promise<VoiceChannel>

  • Parameters

    Returns Promise<CategoryChannel>

  • Parameters

    Returns Promise<unknown>

createEmoji

  • createEmoji(options: { image: string; name: string; roles?: undefined | string[] }, reason?: string): Promise<Emoji>
  • Parameters

    • options: { image: string; name: string; roles?: undefined | string[] }
      • image: string
      • name: string
      • Optional roles?: undefined | string[]
    • Optional reason: string

    Returns Promise<Emoji>

createRole

  • Parameters

    Returns Promise<Role>

delete

  • delete(): Promise<void>
  • Returns Promise<void>

deleteEmoji

  • deleteEmoji(emojiID: string, reason?: string): Promise<void>
  • Parameters

    • emojiID: string
    • Optional reason: string

    Returns Promise<void>

deleteIntegration

  • deleteIntegration(integrationID: string): Promise<void>
  • Parameters

    • integrationID: string

    Returns Promise<void>

deleteRole

  • deleteRole(roleID: string): Promise<void>
  • Parameters

    • roleID: string

    Returns Promise<void>

dynamicBannerURL

  • dynamicBannerURL(format?: string, size?: number): string
  • Parameters

    • Optional format: string
    • Optional size: number

    Returns string

dynamicIconURL

  • dynamicIconURL(format?: string, size?: number): string
  • Parameters

    • Optional format: string
    • Optional size: number

    Returns string

dynamicSplashURL

  • dynamicSplashURL(format?: string, size?: number): string
  • Parameters

    • Optional format: string
    • Optional size: number

    Returns string

edit

  • Parameters

    Returns Promise<Guild>

editEmoji

  • editEmoji(emojiID: string, options: { name: string; roles?: undefined | string[] }, reason?: string): Promise<Emoji>
  • Parameters

    • emojiID: string
    • options: { name: string; roles?: undefined | string[] }
      • name: string
      • Optional roles?: undefined | string[]
    • Optional reason: string

    Returns Promise<Emoji>

editIntegration

  • Parameters

    Returns Promise<void>

editMember

  • editMember(memberID: string, options: MemberOptions, reason?: string): Promise<void>
  • Parameters

    • memberID: string
    • options: MemberOptions
    • Optional reason: string

    Returns Promise<void>

editNickname

  • editNickname(nick: string): Promise<void>
  • Parameters

    • nick: string

    Returns Promise<void>

editRole

  • Parameters

    Returns Promise<Role>

fetchAllMembers

  • fetchAllMembers(timeout?: number): Promise<number>
  • Parameters

    • Optional timeout: number

    Returns Promise<number>

fetchMembers

getAuditLogs

  • getAuditLogs(limit?: number, before?: string, actionType?: number): Promise<GuildAuditLog>
  • Parameters

    • Optional limit: number
    • Optional before: string
    • Optional actionType: number

    Returns Promise<GuildAuditLog>

getBan

  • getBan(userID: string): Promise<{ reason?: undefined | string; user: User }>
  • Parameters

    • userID: string

    Returns Promise<{ reason?: undefined | string; user: User }>

getBans

  • getBans(): Promise<{ reason?: undefined | string; user: User }[]>
  • Returns Promise<{ reason?: undefined | string; user: User }[]>

getEmbed

  • Returns Promise<GuildEmbed>

getIntegrations

  • Returns Promise<GuildIntegration>

getInvites

  • Returns Promise<ChannelInvite[]>

getPruneCount

  • Parameters

    Returns Promise<number>

getRESTChannels

  • Returns Promise<AnyGuildChannel[]>

getRESTEmoji

  • getRESTEmoji(emojiID: string): Promise<Emoji>
  • Parameters

    • emojiID: string

    Returns Promise<Emoji>

getRESTEmojis

  • getRESTEmojis(): Promise<Emoji[]>
  • Returns Promise<Emoji[]>

getRESTMember

  • getRESTMember(memberID: string): Promise<Member>
  • Parameters

    • memberID: string

    Returns Promise<Member>

getRESTMembers

  • getRESTMembers(limit?: number, after?: string): Promise<Member[]>
  • Parameters

    • Optional limit: number
    • Optional after: string

    Returns Promise<Member[]>

getRESTRoles

  • getRESTRoles(): Promise<Role[]>
  • Returns Promise<Role[]>

getVanity

  • getVanity(): Promise<{ code?: undefined | string; uses?: undefined | number }>
  • Returns Promise<{ code?: undefined | string; uses?: undefined | number }>

getVoiceRegions

  • Returns Promise<VoiceRegion[]>

getWebhooks

  • getWebhooks(): Promise<Webhook[]>
  • Returns Promise<Webhook[]>

inspect

  • Returns Guild

kickMember

  • kickMember(userID: string, reason?: string): Promise<void>
  • Parameters

    • userID: string
    • Optional reason: string

    Returns Promise<void>

leave

  • leave(): Promise<void>
  • Returns Promise<void>

leaveVoiceChannel

  • leaveVoiceChannel(): void
  • Returns void

pruneMembers

  • Parameters

    Returns Promise<number>

removeMemberRole

  • removeMemberRole(memberID: string, roleID: string, reason?: string): Promise<void>
  • Parameters

    • memberID: string
    • roleID: string
    • Optional reason: string

    Returns Promise<void>

searchMembers

  • searchMembers(query: string, limit?: number): Promise<Member[]>
  • Parameters

    • query: string
    • Optional limit: number

    Returns Promise<Member[]>

syncIntegration

  • syncIntegration(integrationID: string): Promise<void>
  • Parameters

    • integrationID: string

    Returns Promise<void>

toJSON

  • Parameters

    • Optional props: string[]

    Returns JSONCache

unbanMember

  • unbanMember(userID: string, reason?: string): Promise<void>
  • Parameters

    • userID: string
    • Optional reason: string

    Returns Promise<void>

Generated using TypeDoc