VoiceChannel

VoiceChannel

new VoiceChannel()

Source:
Properties:
Name Type Attributes Description
bitrate Number <nullable>

The bitrate (in bits) of the voice channel

userLimit Number <nullable>

The amount of members allowed to join the voice channel

parentID Snowflake <nullable>

The id of the category the channel is in

parent Object <nullable>

The category the channel is in

Extends

Methods

changePermissions(userOrRole, optionsopt) → {Promise.<(Member|Role)>}

Source:
Inherited From:

Edits the channel permission for the user or role

Parameters:
Name Type Attributes Description
userOrRole Snowflake

The id of the user or role

options Object <optional>

Options for the permission change

Properties
Name Type Attributes Description
allow String <optional>

The name of the permission to allow for the role or user

deny String <optional>

The name of the permission to deny for the role or user

type String <optional>

"member" for a user or "role" for a role

Returns:
Type
Promise.<(Member|Role)>

close() → {Promise.<(TextChannel|VoiceChannel|CategoryChannell)>}

Source:
Inherited From:

Closes a channel

Returns:
Type
Promise.<(TextChannel|VoiceChannel|CategoryChannell)>

createInvite(optionsopt) → {Promise.<Invite>}

Source:
Inherited From:

Creates an invite for the guild channel

Parameters:
Name Type Attributes Description
options Object <optional>

Options for creating the invite

Properties
Name Type Attributes Default Description
maxAge Number <optional>
86400

Duration of invite in seconds, or 0 for never

maxUses Number <optional>
0

Maximum uses for the invite, or 0 for unlimited

temporary Boolean <optional>
false

Whether this invite should be temporary

unique= Boolean <optional>

If true, don't try to reuse a similar invite

Returns:
Type
Promise.<Invite>

delete() → {Promise.<(TextChannel|VoiceChannel|CategoryChannell)>}

Source:
Inherited From:

Similar to GuildChannel#delete. Closes a channel

Returns:
Type
Promise.<(TextChannel|VoiceChannel|CategoryChannell)>

edit(nameopt, positionopt) → {Promise.<(TextChannel|VoiceChannel|CategoryChannel)>}

Source:
Inherited From:

Edits the channel

Parameters:
Name Type Attributes Description
name String <optional>

The new name of the channel

position Number <optional>

The new position of the channel

Returns:
Type
Promise.<(TextChannel|VoiceChannel|CategoryChannel)>

getInvites() → {Promise.<Array.<Invite>>}

Source:
Inherited From:

Returns an array of Channel Invites

Returns:
Type
Promise.<Array.<Invite>>