Skip to main content

Interface IThreadChannel

Represents a thread channel inside of a guild.

Assembly: Discord.Net.Core.dll​
View Source​
Declaration
public interface IThreadChannel : ITextChannel, IMessageChannel, IMentionable, INestedChannel, IGuildChannel, IChannel, ISnowflakeEntity, IEntity<ulong>, IDeletable

Properties​

Type​

Gets the type of the current thread channel.

View Source​
Declaration
ThreadType Type { get; }

HasJoined​

Gets whether or not the current user has joined this thread.

View Source​
Declaration
bool HasJoined { get; }

IsArchived​

Gets whether or not the current thread is archived.

View Source​
Declaration
bool IsArchived { get; }

AutoArchiveDuration​

Gets the duration of time before the thread is automatically archived after no activity.

View Source​
Declaration
ThreadArchiveDuration AutoArchiveDuration { get; }

ArchiveTimestamp​

Gets the timestamp when the thread's archive status was last changed, used for calculating recent activity.

View Source​
Declaration
DateTimeOffset ArchiveTimestamp { get; }

IsLocked​

Gets whether or not the current thread is locked.

View Source​
Declaration
bool IsLocked { get; }

MemberCount​

Gets an approximate count of users in a thread, stops counting after 50.

View Source​
Declaration
int MemberCount { get; }

MessageCount​

Gets an approximate count of messages in a thread, stops counting after 50.

View Source​
Declaration
int MessageCount { get; }

Methods​

JoinAsync(RequestOptions)​

Joins the current thread.

View Source​
Declaration
Task JoinAsync(RequestOptions options = null)
Returns​

System.Threading.Tasks.Task: A task that represents the asynchronous join operation.

Parameters​
TypeNameDescription
Discord.RequestOptionsoptionsThe options to be used when sending the request.

LeaveAsync(RequestOptions)​

Leaves the current thread.

View Source​
Declaration
Task LeaveAsync(RequestOptions options = null)
Returns​

System.Threading.Tasks.Task: A task that represents the asynchronous leave operation.

Parameters​
TypeNameDescription
Discord.RequestOptionsoptionsThe options to be used when sending the request.

AddUserAsync(IGuildUser, RequestOptions)​

Adds a user to this thread.

View Source​
Declaration
Task AddUserAsync(IGuildUser user, RequestOptions options = null)
Returns​

System.Threading.Tasks.Task: A task that represents the asynchronous operation of adding a member to a thread.

Parameters​
TypeNameDescription
Discord.IGuildUseruserThe Discord.IGuildUser to add.
Discord.RequestOptionsoptionsThe options to be used when sending the request.

RemoveUserAsync(IGuildUser, RequestOptions)​

Removes a user from this thread.

View Source​
Declaration
Task RemoveUserAsync(IGuildUser user, RequestOptions options = null)
Returns​

System.Threading.Tasks.Task: A task that represents the asynchronous operation of removing a user from this thread.

Parameters​
TypeNameDescription
Discord.IGuildUseruserThe Discord.IGuildUser to remove from this thread.
Discord.RequestOptionsoptionsThe options to be used when sending the request.