CategoryChannel

CategoryChannel

Represents a guild category channel. See GuildChannel for more properties and methods

Constructor

new CategoryChannel()

Properties:
Name Type Description
channels Collection.<GuildChannel>

A collection of guild channels that are part of this category

permissionOverwrites Collection.<PermissionOverwrite>

Collection of permission overwrites in the channel

position Number

The position of the channel

Source:

Extends

Methods

delete(reasonopt) → {Promise.<(CategoryChannel|ForumChannel|NewsChannel|NewsThreadChannel|PrivateThreadChannel|PublicThreadChannel|TextChannel|VoiceChannel)>}

Delete the channel

Overrides:
Source:
Parameters:
Name Type Attributes Description
reason String <optional>

The reason to be displayed in audit logs

deletePermission(overwriteID, reasonopt) → {Promise}

Delete a channel permission overwrite

Source:
Parameters:
Name Type Attributes Description
overwriteID String

The ID of the overwritten user or role

reason String <optional>

The reason to be displayed in audit logs

Returns:
Type:
Promise

edit(options, reasonopt) → {Promise.<(CategoryChannel|ForumChannel|NewsChannel|NewsThreadChannel|PrivateThreadChannel|PublicThreadChannel|TextChannel|VoiceChannel)>}

Edit the channel's properties

Overrides:
Source:
Parameters:
Name Type Attributes Description
options Object

The properties to edit

Name Type Attributes Description
appliedTags Array.<String> <optional>

[Th] The tags applied to a forum/media thread

archived Boolean <optional>

[Th] The archive status of the channel

autoArchiveDuration Number <optional>

[Th] The duration in minutes to automatically archive the thread after recent activity, either 60, 1440, 4320 or 10080

availableTags Array.<Object> <optional>

[FM] An array of tags that can be applied. This will overwrite all existing tags unless edited by specifying the tag ID

bitrate Number <optional>
<nullable>

[VS] The bitrate of the channel

defaultAutoArchiveDuration Number <optional>
<nullable>

[TAFM] The default duration of newly created threads in minutes to automatically archive the thread after inactivity (60, 1440, 4320, 10080)

defaultForumLayout Number <optional>

[F] The default post layout type

defaultReactionEmoji Object <optional>
<nullable>

[FM] The emoji to show in the Add Reaction Button

defaultSortOrder Number <optional>
<nullable>

[FM] The default post sort type (0 for latest activity, 1 for creation date)

defaultThreadRateLimitPerUser Number <optional>

[TFM] The default rate limit duration for newly created threads

flags Number <optional>

[FM/Th] The channel's flag bit set

invitable Boolean <optional>

[Th] Whether non-moderators can add other non-moderators to the channel

locked Boolean <optional>

[Th] The lock status of the channel

name String <optional>

[All/Th] The name of the channel

nsfw Boolean <optional>
<nullable>

[TVASFM] The NSFW status of the channel

parentID String <optional>
<nullable>

[TVASFM] The ID of the parent channel category for this channel

permissionOverwrites Array.<Object> <optional>
<nullable>

[All] An object containing permission overwrite objects

position Number <optional>
<nullable>

[All] The sorting position of the channel

rateLimitPerUser Number <optional>
<nullable>

[TVSFM/Th] The time in seconds a user has to wait before sending another message (does not affect bots or users with manageMessages/manageChannel permissions)

rtcRegion String <optional>
<nullable>

[VS] The RTC region ID of the channel (automatic if null)

topic String <optional>
<nullable>

[TAFM] The topic of the channel

type Boolean <optional>

[TA] The type of channel (only between types 0 and 5)

userLimit Number <optional>
<nullable>

[VS] The channel user limit

videoQualityMode Number <optional>
<nullable>

[VS] The camera video quality mode of the channel. 1 is auto, 2 is 720p

reason String <optional>

The reason to be displayed in audit logs

editPermission(overwriteID, allow, deny, type, reasonopt) → {Promise.<PermissionOverwrite>}

Edit a channel permission overwrite

Source:
Parameters:
Name Type Attributes Description
overwriteID String

The ID of the overwritten user or role

allow BigInt | Number | String

The permissions number for allowed permissions

deny BigInt | Number | String

The permissions number for denied permissions

type Number

The object type of the overwrite, either 1 for "member" or 0 for "role"

reason String <optional>

The reason to be displayed in audit logs

Returns:
Type:
Promise.<PermissionOverwrite>

permissionsOf(memberID) → {Permission}

Get the channel-specific permissions of a member

Overrides:
Source:
Parameters:
Name Type Description
memberID String | Member | Object

The ID of the member or a Member object

Returns:
Type:
Permission