Search Results for

    Show / Hide Table of Contents

    Interface IVoiceChannel

    Represents a generic voice channel in a guild.

    Inherited Members
    IMessageChannel.SendMessageAsync(String, Boolean, Embed, RequestOptions, AllowedMentions, MessageReference, MessageComponent, ISticker[], Embed[], MessageFlags)
    IMessageChannel.SendFileAsync(String, String, Boolean, Embed, RequestOptions, Boolean, AllowedMentions, MessageReference, MessageComponent, ISticker[], Embed[], MessageFlags)
    IMessageChannel.SendFileAsync(Stream, String, String, Boolean, Embed, RequestOptions, Boolean, AllowedMentions, MessageReference, MessageComponent, ISticker[], Embed[], MessageFlags)
    IMessageChannel.SendFileAsync(FileAttachment, String, Boolean, Embed, RequestOptions, AllowedMentions, MessageReference, MessageComponent, ISticker[], Embed[], MessageFlags)
    IMessageChannel.SendFilesAsync(IEnumerable<FileAttachment>, String, Boolean, Embed, RequestOptions, AllowedMentions, MessageReference, MessageComponent, ISticker[], Embed[], MessageFlags)
    IMessageChannel.GetMessageAsync(UInt64, CacheMode, RequestOptions)
    IMessageChannel.GetMessagesAsync(Int32, CacheMode, RequestOptions)
    IMessageChannel.GetMessagesAsync(UInt64, Direction, Int32, CacheMode, RequestOptions)
    IMessageChannel.GetMessagesAsync(IMessage, Direction, Int32, CacheMode, RequestOptions)
    IMessageChannel.GetPinnedMessagesAsync(RequestOptions)
    IMessageChannel.DeleteMessageAsync(UInt64, RequestOptions)
    IMessageChannel.DeleteMessageAsync(IMessage, RequestOptions)
    IMessageChannel.ModifyMessageAsync(UInt64, Action<MessageProperties>, RequestOptions)
    IMessageChannel.TriggerTypingAsync(RequestOptions)
    IMessageChannel.EnterTypingState(RequestOptions)
    INestedChannel.CategoryId
    INestedChannel.GetCategoryAsync(CacheMode, RequestOptions)
    INestedChannel.SyncPermissionsAsync(RequestOptions)
    INestedChannel.CreateInviteAsync(Nullable<Int32>, Nullable<Int32>, Boolean, Boolean, RequestOptions)
    INestedChannel.CreateInviteToApplicationAsync(UInt64, Nullable<Int32>, Nullable<Int32>, Boolean, Boolean, RequestOptions)
    INestedChannel.CreateInviteToApplicationAsync(DefaultApplications, Nullable<Int32>, Nullable<Int32>, Boolean, Boolean, RequestOptions)
    INestedChannel.CreateInviteToStreamAsync(IUser, Nullable<Int32>, Nullable<Int32>, Boolean, Boolean, RequestOptions)
    INestedChannel.GetInvitesAsync(RequestOptions)
    IGuildChannel.Position
    IGuildChannel.Flags
    IGuildChannel.Guild
    IGuildChannel.GuildId
    IGuildChannel.PermissionOverwrites
    IGuildChannel.ModifyAsync(Action<GuildChannelProperties>, RequestOptions)
    IGuildChannel.GetPermissionOverwrite(IRole)
    IGuildChannel.GetPermissionOverwrite(IUser)
    IGuildChannel.RemovePermissionOverwriteAsync(IRole, RequestOptions)
    IGuildChannel.RemovePermissionOverwriteAsync(IUser, RequestOptions)
    IGuildChannel.AddPermissionOverwriteAsync(IRole, OverwritePermissions, RequestOptions)
    IGuildChannel.AddPermissionOverwriteAsync(IUser, OverwritePermissions, RequestOptions)
    IGuildChannel.GetUsersAsync(CacheMode, RequestOptions)
    IGuildChannel.GetUserAsync(UInt64, CacheMode, RequestOptions)
    IDeletable.DeleteAsync(RequestOptions)
    IAudioChannel.RTCRegion
    IAudioChannel.ConnectAsync(Boolean, Boolean, Boolean)
    IAudioChannel.DisconnectAsync()
    IAudioChannel.ModifyAsync(Action<AudioChannelProperties>, RequestOptions)
    IChannel.Name
    ISnowflakeEntity.CreatedAt
    IEntity<UInt64>.Id
    IMentionable.Mention
    Namespace: Discord
    Assembly: Discord.Net.Core.dll
    Syntax
    public interface IVoiceChannel : IMessageChannel, INestedChannel, IGuildChannel, IDeletable, IAudioChannel, IChannel, ISnowflakeEntity, IEntity<ulong>, IMentionable

    Properties

    | Improve this Doc View Source

    Bitrate

    Gets the bit-rate that the clients in this voice channel are requested to use.

    Declaration
    int Bitrate { get; }
    Property Value
    Type Description
    Int32

    An representing the bit-rate (bps) that this voice channel defines and requests the client(s) to use.

    | Improve this Doc View Source

    UserLimit

    Gets the max number of users allowed to be connected to this channel at once.

    Declaration
    int? UserLimit { get; }
    Property Value
    Type Description
    Nullable<Int32>

    An representing the maximum number of users that are allowed to be connected to this channel at once; null if a limit is not set.

    Methods

    | Improve this Doc View Source

    DeleteMessagesAsync(IEnumerable<IMessage>, RequestOptions)

    Bulk-deletes multiple messages.

    Declaration
    Task DeleteMessagesAsync(IEnumerable<IMessage> messages, RequestOptions options = null)
    Parameters
    Type Name Description
    IEnumerable<IMessage> messages

    The messages to be bulk-deleted.

    RequestOptions options

    The options to be used when sending the request.

    Returns
    Type Description
    Task

    A task that represents the asynchronous bulk-removal operation.

    Remarks

    This method attempts to remove the messages specified in bulk.

    important

    Due to the limitation set by Discord, this method can only remove messages that are posted within 14 days!

    Examples

    The following example gets 250 messages from the channel and deletes them.

    var messages = await voiceChannel.GetMessagesAsync(250).FlattenAsync();
    await voiceChannel.DeleteMessagesAsync(messages);
    | Improve this Doc View Source

    DeleteMessagesAsync(IEnumerable<UInt64>, RequestOptions)

    Bulk-deletes multiple messages.

    Declaration
    Task DeleteMessagesAsync(IEnumerable<ulong> messageIds, RequestOptions options = null)
    Parameters
    Type Name Description
    IEnumerable<UInt64> messageIds

    The snowflake identifier of the messages to be bulk-deleted.

    RequestOptions options

    The options to be used when sending the request.

    Returns
    Type Description
    Task

    A task that represents the asynchronous bulk-removal operation.

    Remarks

    This method attempts to remove the messages specified in bulk.

    important

    Due to the limitation set by Discord, this method can only remove messages that are posted within 14 days!

    | Improve this Doc View Source

    ModifyAsync(Action<VoiceChannelProperties>, RequestOptions)

    Modifies this voice channel.

    Declaration
    Task ModifyAsync(Action<VoiceChannelProperties> func, RequestOptions options = null)
    Parameters
    Type Name Description
    Action<VoiceChannelProperties> func

    The properties to modify the channel with.

    RequestOptions options

    The options to be used when sending the request.

    Returns
    Type Description
    Task

    A task that represents the asynchronous modification operation.

    See Also
    VoiceChannelProperties

    Extension Methods

    ChannelExtensions.GetChannelType(IChannel)

    Theme

    • Improve this Doc
    • View Source
    In This Article
    Back to top Discord.Net (c) 2015-2022 3.9.0