Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Properties

Properties

default

default: { checks: { isMemberAdmin: (interaction: BaseCommandInteraction<CacheType>) => boolean; memberHasRole: (int: BaseCommandInteraction<CacheType>, role: string, exactCase?: boolean) => Promise<boolean> }; embeds: { errorEmbed: (errorMessage: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed; simpleEmbed: (title: string, color?: ColorResolvable, options?: { description?: string; emoji?: EmojiResolvable }) => MessageEmbed; successEmbed: (message: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed }; errorEmbed: (errorMessage: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed; interceptors: { replyWithError: (interaction: BaseCommandInteraction<CacheType>, errorMessage: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void>; replyWithSuccess: (interaction: BaseCommandInteraction<CacheType>, message: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void> }; isMemberAdmin: (interaction: BaseCommandInteraction<CacheType>) => boolean; memberHasRole: (int: BaseCommandInteraction<CacheType>, role: string, exactCase?: boolean) => Promise<boolean>; replyWithError: (interaction: BaseCommandInteraction<CacheType>, errorMessage: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void>; replyWithSuccess: (interaction: BaseCommandInteraction<CacheType>, message: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void>; simpleEmbed: (title: string, color?: ColorResolvable, options?: { description?: string; emoji?: EmojiResolvable }) => MessageEmbed; successEmbed: (message: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed }

Type declaration

  • checks: { isMemberAdmin: (interaction: BaseCommandInteraction<CacheType>) => boolean; memberHasRole: (int: BaseCommandInteraction<CacheType>, role: string, exactCase?: boolean) => Promise<boolean> }
    • isMemberAdmin: (interaction: BaseCommandInteraction<CacheType>) => boolean
        • (interaction: BaseCommandInteraction<CacheType>): boolean
        • Checks if the member who triggered the interaction is an admin

          remark

          This checks if the member has the ADMINISTRATOR permission

          Parameters

          • interaction: BaseCommandInteraction<CacheType>

            The interaction to check

          Returns boolean

          Whether the member is an admin

    • memberHasRole: (int: BaseCommandInteraction<CacheType>, role: string, exactCase?: boolean) => Promise<boolean>
        • (int: BaseCommandInteraction<CacheType>, role: string, exactCase?: boolean): Promise<boolean>
        • Checks if a member of an interaction has a role, by id or name

          Parameters

          • int: BaseCommandInteraction<CacheType>

            The interaction to check

          • role: string

            The role name or id

          • exactCase: boolean = false

            Whether the role name should have the exact case/capitalization (default: false)

          Returns Promise<boolean>

          Whether the member has the role

  • embeds: { errorEmbed: (errorMessage: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed; simpleEmbed: (title: string, color?: ColorResolvable, options?: { description?: string; emoji?: EmojiResolvable }) => MessageEmbed; successEmbed: (message: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed }
    • errorEmbed: (errorMessage: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed
        • (errorMessage: string, details?: string, emoji?: EmojiResolvable): MessageEmbed
        • Makes an embed for reporting an error

          Parameters

          • errorMessage: string

            The error message to display

          • Optional details: string

            Optional details to include in the message

          • Optional emoji: EmojiResolvable

            Emoji to include in the title

          Returns MessageEmbed

          The created embed

    • simpleEmbed: (title: string, color?: ColorResolvable, options?: { description?: string; emoji?: EmojiResolvable }) => MessageEmbed
        • (title: string, color?: ColorResolvable, options?: { description?: string; emoji?: EmojiResolvable }): MessageEmbed
        • Makes a simple embed with a title and description

          Parameters

          • title: string

            The title of the embed

          • color: ColorResolvable = 'BLUE'

            The color of the embed (default: blue)

          • Optional options: { description?: string; emoji?: EmojiResolvable }

            Extra options like description and emoji

            • Optional description?: string
            • Optional emoji?: EmojiResolvable

          Returns MessageEmbed

          The created embed

    • successEmbed: (message: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed
        • (message: string, details?: string, emoji?: EmojiResolvable): MessageEmbed
        • Makes an embed for sending a success message

          Parameters

          • message: string

            The success message to display

          • Optional details: string

            Optional details to include in the message

          • Optional emoji: EmojiResolvable

            Emoji to include in the title

          Returns MessageEmbed

          The created embed

  • errorEmbed: (errorMessage: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed
      • (errorMessage: string, details?: string, emoji?: EmojiResolvable): MessageEmbed
      • Makes an embed for reporting an error

        Parameters

        • errorMessage: string

          The error message to display

        • Optional details: string

          Optional details to include in the message

        • Optional emoji: EmojiResolvable

          Emoji to include in the title

        Returns MessageEmbed

        The created embed

  • interceptors: { replyWithError: (interaction: BaseCommandInteraction<CacheType>, errorMessage: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void>; replyWithSuccess: (interaction: BaseCommandInteraction<CacheType>, message: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void> }
    • replyWithError: (interaction: BaseCommandInteraction<CacheType>, errorMessage: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void>
        • (interaction: BaseCommandInteraction<CacheType>, errorMessage: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable): Promise<void>
        • Replies to an interaction with an error embed

          Parameters

          • interaction: BaseCommandInteraction<CacheType>

            The interaction to reply to

          • errorMessage: string

            The error message to send

          • ephemeral: boolean = false

            Whether to make reply ephemeral (default: false)

          • Optional details: string

            Optional details to include in the message

          • Optional emoji: EmojiResolvable

            Emoji to include in the title

          Returns Promise<void>

    • replyWithSuccess: (interaction: BaseCommandInteraction<CacheType>, message: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void>
        • (interaction: BaseCommandInteraction<CacheType>, message: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable): Promise<void>
        • Replies to an interaction with a success embed

          Parameters

          • interaction: BaseCommandInteraction<CacheType>

            The interaction to reply to

          • message: string

            The success message to display

          • ephemeral: boolean = false

            Whether to make reply ephemeral (default: false)

          • Optional details: string

            Optional details to include in the message

          • Optional emoji: EmojiResolvable

            Emoji to include in the title

          Returns Promise<void>

  • isMemberAdmin: (interaction: BaseCommandInteraction<CacheType>) => boolean
      • (interaction: BaseCommandInteraction<CacheType>): boolean
      • Checks if the member who triggered the interaction is an admin

        remark

        This checks if the member has the ADMINISTRATOR permission

        Parameters

        • interaction: BaseCommandInteraction<CacheType>

          The interaction to check

        Returns boolean

        Whether the member is an admin

  • memberHasRole: (int: BaseCommandInteraction<CacheType>, role: string, exactCase?: boolean) => Promise<boolean>
      • (int: BaseCommandInteraction<CacheType>, role: string, exactCase?: boolean): Promise<boolean>
      • Checks if a member of an interaction has a role, by id or name

        Parameters

        • int: BaseCommandInteraction<CacheType>

          The interaction to check

        • role: string

          The role name or id

        • exactCase: boolean = false

          Whether the role name should have the exact case/capitalization (default: false)

        Returns Promise<boolean>

        Whether the member has the role

  • replyWithError: (interaction: BaseCommandInteraction<CacheType>, errorMessage: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void>
      • (interaction: BaseCommandInteraction<CacheType>, errorMessage: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable): Promise<void>
      • Replies to an interaction with an error embed

        Parameters

        • interaction: BaseCommandInteraction<CacheType>

          The interaction to reply to

        • errorMessage: string

          The error message to send

        • ephemeral: boolean = false

          Whether to make reply ephemeral (default: false)

        • Optional details: string

          Optional details to include in the message

        • Optional emoji: EmojiResolvable

          Emoji to include in the title

        Returns Promise<void>

  • replyWithSuccess: (interaction: BaseCommandInteraction<CacheType>, message: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable) => Promise<void>
      • (interaction: BaseCommandInteraction<CacheType>, message: string, ephemeral?: boolean, details?: string, emoji?: EmojiResolvable): Promise<void>
      • Replies to an interaction with a success embed

        Parameters

        • interaction: BaseCommandInteraction<CacheType>

          The interaction to reply to

        • message: string

          The success message to display

        • ephemeral: boolean = false

          Whether to make reply ephemeral (default: false)

        • Optional details: string

          Optional details to include in the message

        • Optional emoji: EmojiResolvable

          Emoji to include in the title

        Returns Promise<void>

  • simpleEmbed: (title: string, color?: ColorResolvable, options?: { description?: string; emoji?: EmojiResolvable }) => MessageEmbed
      • (title: string, color?: ColorResolvable, options?: { description?: string; emoji?: EmojiResolvable }): MessageEmbed
      • Makes a simple embed with a title and description

        Parameters

        • title: string

          The title of the embed

        • color: ColorResolvable = 'BLUE'

          The color of the embed (default: blue)

        • Optional options: { description?: string; emoji?: EmojiResolvable }

          Extra options like description and emoji

          • Optional description?: string
          • Optional emoji?: EmojiResolvable

        Returns MessageEmbed

        The created embed

  • successEmbed: (message: string, details?: string, emoji?: EmojiResolvable) => MessageEmbed
      • (message: string, details?: string, emoji?: EmojiResolvable): MessageEmbed
      • Makes an embed for sending a success message

        Parameters

        • message: string

          The success message to display

        • Optional details: string

          Optional details to include in the message

        • Optional emoji: EmojiResolvable

          Emoji to include in the title

        Returns MessageEmbed

        The created embed

Generated using TypeDoc