Struct twilight_http::request::channel::update_channel::UpdateChannel[][src]

pub struct UpdateChannel<'a> { /* fields omitted */ }
Expand description

Update a channel.

All fields are optional. The minimum length of the name is 1 UTF-16 character and the maximum is 100 UTF-16 characters.

Implementations

Set the bitrate of the channel. Applicable to voice channels only.

Set the name.

The minimum length is 1 UTF-16 character and the maximum is 100 UTF-16 characters.

Errors

Returns an UpdateChannelErrorType::NameInvalid error type if the name length is too short or too long.

Set whether the channel is marked as NSFW.

If this is specified, and the parent ID is a ChannelType::CategoryChannel, move this channel to a child of the category channel.

Set the permission overwrites of a channel. This will overwrite all permissions that the channel currently has, so use with caution!

Set the position of the channel.

Positions are numerical and zero-indexed. If you place a channel at position 2, channels 2-n will shift down one position and the initial channel will take its place.

Set the number of seconds that a user must wait before before they are able to send another message.

The minimum is 0 and the maximum is 21600. Refer to the discord docs for more details. This is also known as “Slow Mode”.

Errors

Returns an UpdateChannelErrorType::RateLimitPerUserInvalid error type if the amount is greater than 21600.

Set the topic.

The maximum length is 1024 UTF-16 characters. Refer to the discord docs for more details.

Errors

Returns an UpdateChannelErrorType::TopicInvalid error type if the topic length is too long.

For voice channels, set the user limit.

Set to 0 for no limit. Limit can otherwise be between 1 and 99 inclusive. Refer to the discord docs for more details.

Set the VideoQualityMode for the voice channel.

Set the kind of channel.

Only conversion between ChannelType::GuildText and ChannelType::GuildNews is possible, and only if the guild has the NEWS feature enabled. Refer to the discord docs for more details.

Execute the request, returning a future resolving to a Response.

Trait Implementations

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more