DiscordChannel class

Constructors

DiscordChannel({required DiscordSnowflake id, required int type, DiscordSnowflake? guildId, int? position, List<DiscordOverwrite>? permissionOverwrites, String? name, String? topic, bool? nsfw, DiscordSnowflake? lastMessageId, int? bitrate, int? userLimit, int? rateLimitPerUser, List<DiscordUser>? recipients, String? icon, DiscordSnowflake? ownerId, DiscordSnowflake? applicationId, DiscordSnowflake? parentId, String? lastPinTimestamp, String? rtcRegion, int? videoQualityMode, int? messageCount, int? memberCount, DiscordThreadMetadata? threadMetadata, DiscordThreadMember? member, int? defaultAutoArchiveDuration, String? permissions})
DiscordChannel.fromJson(Map<String, dynamic> json)
factory

Properties

applicationId DiscordSnowflake?
application id of the group DM creator if it is bot-created
final
bitrate int?
the bitrate (in bits) of the voice channel
final
defaultAutoArchiveDuration int?
default duration that the clients (not the API) will use for newly created threads, in minutes, to automatically archive the thread after recent activity, can be set to: 60, 1440, 4320, 10080
final
guildId DiscordSnowflake?
the id of the guild (may be missing for some channel objects received over gateway guild dispatches)
final
hashCode int
The hash code for this object.
no setterinherited
icon String?
icon hash of the group DM
final
id DiscordSnowflake
the id of this channel
final
lastMessageId DiscordSnowflake?
the id of the last message sent in this channel (may not point to an existing or valid message)
final
lastPinTimestamp String?
when the last pinned message was pinned. This may be null in events such as GUILD_CREATE when a message is not pinned.
final
lastPinTimestampAsDateTime DateTime?
no setter
member DiscordThreadMember?
thread member object for the current user, if they have joined the thread, only included on certain API endpoints
final
memberCount int?
an approximate count of users in a thread, stops counting at 50
final
messageCount int?
an approximate count of messages in a thread, stops counting at 50
final
name String?
the name of the channel (1-100 characters)
final
nsfw bool?
whether the channel is nsfw
final
ownerId DiscordSnowflake?
id of the creator of the group DM or thread
final
parentId DiscordSnowflake?
for guild channels: id of the parent category for a channel (each parent category can contain up to 50 channels), for threads: id of the text channel this thread was created
final
permissionOverwrites List<DiscordOverwrite>?
explicit permission overewrites for members and roles
final
permissions String?
computed permissions for the invoking user in the channel, including overwrites, only included when part of the resolved data received on a slash command interaction
final
position int?
sorting position of the channel
final
rateLimitPerUser int?
amount of seconds a user has to wait before sending another message (0-21600); bots, as well as users with the permission manage_messages or manage_channel, are unaffected
final
recipients List<DiscordUser>?
the recipients of the DM
final
rtcRegion String?
voice region id for the voice channel, automatic when set to null
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
threadMetadata DiscordThreadMetadata?
thread-specific fields not needed by other channels
final
topic String?
the channel topic (0-1024 characters)
final
type int
the type of channel
final
typeAsEnum DiscordChannelType
no setter
userLimit int?
the user limit of the voice channel
final
videoQualityMode int?
the camera video quality mode of the voice channel, 1 when not present
final
videoQualityModeAsEnum DiscordVideoQualityMode?
no setter

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited