Manages API methods for objects and stores their cache.
Extends
ThreadManager<false>Name | Constraints | Optional | Default | Description |
---|---|---|---|---|
AllowedThreadType | No | None |
The cache of items for this manager.
Inherited from DataManagerThe channel this Manager belongs to
Inherited from ThreadManagerThe client that instantiated this Manager
Inherited from BaseManagerThe data structure belonging to this manager.
Inherited from DataManagercreate(options):Promise<AllowedThreadType extends ChannelType.PrivateThread ? PrivateThreadChannel : PublicThreadChannel<false>>
Creates a new thread in the channel.
Example
Example
Name | Type | Optional | Description |
---|---|---|---|
options | GuildTextThreadCreateOptions<AllowedThreadType> | No | Options to create a new thread |
Obtains a thread from Discord, or the channel cache if it's already available.
Returns
FetchedThreads if active & FetchedThreadsMore if archived.Example
Name | Type | Optional | Description |
---|---|---|---|
options | ThreadChannelResolvable | No | The options to fetch threads. If it is a ThreadChannelResolvable then the specified thread will be fetched. Fetches all active threads if undefined |
cacheOptions | BaseFetchOptions | Yes | Additional options for this fetch. The force field gets ignored if options is not a ThreadChannelResolvable |
Obtains all active threads in the channel.
Name | Type | Optional | Description |
---|---|---|---|
cache | boolean | Yes | Whether to cache the fetched data |
Obtains a set of archived threads from Discord. This method requires the PermissionFlagsBits.ReadMessageHistory permission in the parent channel.
Name | Type | Optional | Description |
---|---|---|---|
options | FetchArchivedThreadOptions | Yes | The options to fetch archived threads |
cache | boolean | Yes | Whether to cache the new thread objects if they aren't already |
Resolves a ThreadChannelResolvable to a object.
Name | Type | Optional | Description |
---|---|---|---|
thread | ThreadChannelResolvable | No | The ThreadChannel resolvable to resolve |
Resolves a ThreadChannelResolvable to a id.
Name | Type | Optional | Description |
---|---|---|---|
thread | ThreadChannelResolvable | No | The ThreadChannel resolvable to resolve |