Interface ServerTextChannel
-
- All Superinterfaces:
Categorizable,Channel,ChannelAttachableListenerManager,ChannelSpecialization,java.lang.Comparable<RegularServerChannel>,DiscordEntity,java.util.Formattable,Mentionable,Messageable,Nameable,RegularServerChannel,ServerChannel,ServerChannelAttachableListenerManager,ServerTextChannelAttachableListenerManager,ServerThreadChannelAttachableListenerManager,Specializable<ChannelSpecialization>,TextChannel,TextChannelAttachableListenerManager,Updatable,UpdatableFromCache
public interface ServerTextChannel extends RegularServerChannel, TextChannel, Mentionable, Categorizable, ServerTextChannelAttachableListenerManager
This class represents a server text channel.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default java.util.concurrent.CompletableFuture<ServerThreadChannel>createThread(ChannelType channelType, java.lang.String name, java.lang.Integer autoArchiveDuration)Creates a thread which is not related to a message.default java.util.concurrent.CompletableFuture<ServerThreadChannel>createThread(ChannelType channelType, java.lang.String name, java.lang.Integer autoArchiveDuration, java.lang.Boolean inviteable)Creates a thread which is not related to a message.default java.util.concurrent.CompletableFuture<ServerThreadChannel>createThread(ChannelType channelType, java.lang.String name, AutoArchiveDuration autoArchiveDuration)Creates a thread which is not related to a message.default java.util.concurrent.CompletableFuture<ServerThreadChannel>createThread(ChannelType channelType, java.lang.String name, AutoArchiveDuration autoArchiveDuration, java.lang.Boolean inviteable)Creates a thread which is not related to a message.default java.util.concurrent.CompletableFuture<ServerThreadChannel>createThreadForMessage(Message message, java.lang.String name, java.lang.Integer autoArchiveDuration)Creates a thread for a message in this ServerTextChannel.default java.util.concurrent.CompletableFuture<ServerThreadChannel>createThreadForMessage(Message message, java.lang.String name, AutoArchiveDuration autoArchiveDuration)Creates a thread for a message in this ServerTextChannel.default ServerTextChannelUpdatercreateUpdater()Creates an updater for this channel.default WebhookBuildercreateWebhookBuilder()Creates a webhook builder for this channel.default java.util.Optional<ServerTextChannel>getCurrentCachedInstance()Gets an updated instance of this entity from the cache.intgetDefaultAutoArchiveDuration()Gets the default auto archive duration for threads that will be created in this channel.default java.util.concurrent.CompletableFuture<ArchivedThreads>getJoinedPrivateArchivedThreads()Gets the joined private archived threads.default java.util.concurrent.CompletableFuture<ArchivedThreads>getJoinedPrivateArchivedThreads(int limit)Gets the joined private archived threads.default java.util.concurrent.CompletableFuture<ArchivedThreads>getJoinedPrivateArchivedThreads(long before)Gets the joined private archived threads.java.util.concurrent.CompletableFuture<ArchivedThreads>getJoinedPrivateArchivedThreads(java.lang.Long before, java.lang.Integer limit)Gets the joined private archived threads.default java.util.concurrent.CompletableFuture<ServerTextChannel>getLatestInstance()Gets an updated instance of this entity from the cache or from Discord directly.default java.util.concurrent.CompletableFuture<ArchivedThreads>getPrivateArchivedThreads()Gets the private archived threads.default java.util.concurrent.CompletableFuture<ArchivedThreads>getPrivateArchivedThreads(int limit)Gets the private archived threads.default java.util.concurrent.CompletableFuture<ArchivedThreads>getPrivateArchivedThreads(long before)Gets the private archived threads.java.util.concurrent.CompletableFuture<ArchivedThreads>getPrivateArchivedThreads(java.lang.Long before, java.lang.Integer limit)Gets the private archived threads.default java.util.concurrent.CompletableFuture<ArchivedThreads>getPublicArchivedThreads()Gets the public archived threads.default java.util.concurrent.CompletableFuture<ArchivedThreads>getPublicArchivedThreads(int limit)Gets the public archived threads.default java.util.concurrent.CompletableFuture<ArchivedThreads>getPublicArchivedThreads(long before)Gets the public archived threads.java.util.concurrent.CompletableFuture<ArchivedThreads>getPublicArchivedThreads(java.lang.Long before, java.lang.Integer limit)Gets the public archived threads.intgetSlowmodeDelayInSeconds()Gets the delay for slowmode.java.lang.StringgetTopic()Gets the topic of the channel.default booleanhasSlowmode()Check whether slowmode is activated for this channel.booleanisNsfw()Checks is the channel is "not safe for work".default java.util.concurrent.CompletableFuture<java.lang.Void>removeCategory()Removes the category of the channel.default java.util.concurrent.CompletableFuture<java.lang.Void>unsetSlowmode()Deactivate slowmode for this channel.default java.util.concurrent.CompletableFuture<java.lang.Void>updateCategory(ChannelCategory category)Updates the category of the channel.default java.util.concurrent.CompletableFuture<java.lang.Void>updateNsfwFlag(boolean nsfw)Updates the nsfw flag of the channel.default java.util.concurrent.CompletableFuture<java.lang.Void>updateSlowmodeDelayInSeconds(int delay)Set a slowmode for this channel.default java.util.concurrent.CompletableFuture<java.lang.Void>updateTopic(java.lang.String topic)Updates the topic of the channel.-
Methods inherited from interface org.javacord.api.entity.channel.Categorizable
getCategory
-
Methods inherited from interface org.javacord.api.entity.channel.Channel
asCategorizable, asChannelCategory, asPrivateChannel, asRegularServerChannel, asServerChannel, asServerForumChannel, asServerStageVoiceChannel, asServerTextChannel, asServerThreadChannel, asServerVoiceChannel, asTextChannel, asVoiceChannel, canSee, canYouSee, getType
-
Methods inherited from interface org.javacord.api.listener.channel.ChannelAttachableListenerManager
addChannelAttachableListener, getChannelAttachableListeners, removeChannelAttachableListener, removeListener
-
Methods inherited from interface org.javacord.api.entity.DiscordEntity
getApi, getCreationTimestamp, getId, getIdAsString
-
Methods inherited from interface org.javacord.api.entity.Mentionable
getMentionTag
-
Methods inherited from interface org.javacord.api.entity.message.Messageable
sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage
-
Methods inherited from interface org.javacord.api.entity.channel.RegularServerChannel
canCreateInstantInvite, canYouCreateInstantInvite, compareTo, getEffectiveAllowedPermissions, getEffectiveDeniedPermissions, getEffectiveOverwrittenPermissions, getEffectivePermissions, getOverwrittenPermissions, getOverwrittenPermissions, getOverwrittenRolePermissions, getOverwrittenUserPermissions, getPosition, getRawPosition, hasAnyPermission, hasPermission, hasPermissions, updateRawPosition
-
Methods inherited from interface org.javacord.api.entity.channel.ServerChannel
createInviteBuilder, delete, delete, getInvites, getServer, updateName
-
Methods inherited from interface org.javacord.api.listener.channel.server.ServerChannelAttachableListenerManager
addServerChannelAttachableListener, addServerChannelChangeNameListener, addServerChannelChangeOverwrittenPermissionsListener, addServerChannelChangePositionListener, addServerChannelDeleteListener, addVoiceStateUpdateListener, getServerChannelAttachableListeners, getServerChannelChangeNameListeners, getServerChannelChangeOverwrittenPermissionsListeners, getServerChannelChangePositionListeners, getServerChannelDeleteListeners, getVoiceStateUpdateListeners, removeListener, removeServerChannelAttachableListener
-
Methods inherited from interface org.javacord.api.listener.channel.server.text.ServerTextChannelAttachableListenerManager
addServerChannelChangeNsfwFlagListener, addServerTextChannelAttachableListener, addServerTextChannelChangeDefaultAutoArchiveDurationListener, addServerTextChannelChangeSlowmodeListener, addServerTextChannelChangeTopicListener, addWebhooksUpdateListener, getServerChannelChangeNsfwFlagListeners, getServerTextChannelAttachableListeners, getServerTextChannelChangeDefaultAutoArchiveDurationListeners, getServerTextChannelChangeSlowmodeListeners, getServerTextChannelChangeTopicListeners, getWebhooksUpdateListeners, removeListener, removeServerTextChannelAttachableListener
-
Methods inherited from interface org.javacord.api.listener.channel.ServerThreadChannelAttachableListenerManager
addServerThreadChannelAttachableListener, addServerThreadChannelCreateListener, addServerThreadChannelDeleteListener, addServerThreadChannelMembersUpdateListener, addServerThreadChannelUpdateListener, getServerThreadChannelAttachableListeners, getServerThreadChannelCreateListeners, getServerThreadChannelDeleteListeners, getServerThreadChannelMembersUpdateListeners, getServerThreadChannelUpdateListeners, removeListener, removeServerThreadChannelAttachableListener
-
Methods inherited from interface org.javacord.api.util.Specializable
as
-
Methods inherited from interface org.javacord.api.entity.channel.TextChannel
bulkDelete, bulkDelete, bulkDelete, bulkDelete, canAddNewReactions, canAttachFiles, canEmbedLinks, canManageMessages, canMentionEveryone, canReadMessageHistory, canRemoveReactionsOfOthers, canUseExternalEmojis, canUseTts, canWrite, canYouAddNewReactions, canYouAttachFiles, canYouEmbedLinks, canYouManageMessages, canYouMentionEveryone, canYouReadMessageHistory, canYouRemoveReactionsOfOthers, canYouUseExternalEmojis, canYouUseTts, canYouWrite, deleteMessages, deleteMessages, deleteMessages, deleteMessages, getAllIncomingWebhooks, getIncomingWebhooks, getMessageById, getMessageById, getMessageCache, getMessages, getMessagesAfter, getMessagesAfter, getMessagesAfterAsStream, getMessagesAfterAsStream, getMessagesAfterUntil, getMessagesAfterUntil, getMessagesAfterWhile, getMessagesAfterWhile, getMessagesAround, getMessagesAround, getMessagesAroundAsStream, getMessagesAroundAsStream, getMessagesAroundUntil, getMessagesAroundUntil, getMessagesAroundWhile, getMessagesAroundWhile, getMessagesAsStream, getMessagesBefore, getMessagesBefore, getMessagesBeforeAsStream, getMessagesBeforeAsStream, getMessagesBeforeUntil, getMessagesBeforeUntil, getMessagesBeforeWhile, getMessagesBeforeWhile, getMessagesBetween, getMessagesBetween, getMessagesBetweenAsStream, getMessagesBetweenAsStream, getMessagesBetweenUntil, getMessagesBetweenUntil, getMessagesBetweenWhile, getMessagesBetweenWhile, getMessagesUntil, getMessagesWhile, getPins, getWebhooks, type, typeContinuously, typeContinuously, typeContinuouslyAfter, typeContinuouslyAfter
-
Methods inherited from interface org.javacord.api.listener.channel.TextChannelAttachableListenerManager
addAutocompleteCreateListener, addButtonClickListener, addCachedMessagePinListener, addCachedMessageUnpinListener, addChannelPinsUpdateListener, addInteractionCreateListener, addMessageComponentCreateListener, addMessageContextMenuCommandListener, addMessageCreateListener, addMessageDeleteListener, addMessageEditListener, addModalSubmitListener, addReactionAddListener, addReactionRemoveAllListener, addReactionRemoveListener, addSelectMenuChooseListener, addSlashCommandCreateListener, addTextChannelAttachableListener, addUserContextMenuCommandListener, addUserStartTypingListener, getAutocompleteCreateListeners, getButtonClickListeners, getCachedMessagePinListeners, getCachedMessageUnpinListeners, getChannelPinsUpdateListeners, getInteractionCreateListeners, getMessageComponentCreateListeners, getMessageContextMenuCommandListeners, getMessageCreateListeners, getMessageDeleteListeners, getMessageEditListeners, getModalSubmitListeners, getReactionAddListeners, getReactionRemoveAllListeners, getReactionRemoveListeners, getSelectMenuChooseListeners, getSlashCommandCreateListeners, getTextChannelAttachableListeners, getUserContextMenuCommandListeners, getUserStartTypingListeners, removeListener, removeTextChannelAttachableListener
-
-
-
-
Method Detail
-
getDefaultAutoArchiveDuration
int getDefaultAutoArchiveDuration()
Gets the default auto archive duration for threads that will be created in this channel.- Returns:
- The default auto archive duration for this channel.
-
isNsfw
boolean isNsfw()
Checks is the channel is "not safe for work".- Returns:
- Whether the channel is "not safe for work" or not.
-
getTopic
java.lang.String getTopic()
Gets the topic of the channel.- Returns:
- The topic of the channel.
-
createWebhookBuilder
default WebhookBuilder createWebhookBuilder()
Creates a webhook builder for this channel.- Returns:
- A webhook builder.
-
createUpdater
default ServerTextChannelUpdater createUpdater()
Creates an updater for this channel.- Specified by:
createUpdaterin interfaceRegularServerChannel- Specified by:
createUpdaterin interfaceServerChannel- Returns:
- An updater for this channel.
-
updateTopic
default java.util.concurrent.CompletableFuture<java.lang.Void> updateTopic(java.lang.String topic)
Updates the topic of the channel.If you want to update several settings at once, it's recommended to use the
ServerTextChannelUpdaterfromcreateUpdater()which provides a better performance!- Parameters:
topic- The new topic of the channel.- Returns:
- A future to check if the update was successful.
-
updateNsfwFlag
default java.util.concurrent.CompletableFuture<java.lang.Void> updateNsfwFlag(boolean nsfw)
Updates the nsfw flag of the channel.If you want to update several settings at once, it's recommended to use the
ServerTextChannelUpdaterfromcreateUpdater()which provides a better performance!- Parameters:
nsfw- The new nsfw flag of the channel.- Returns:
- A future to check if the update was successful.
-
updateCategory
default java.util.concurrent.CompletableFuture<java.lang.Void> updateCategory(ChannelCategory category)
Updates the category of the channel.If you want to update several settings at once, it's recommended to use the
ServerTextChannelUpdaterfromcreateUpdater()which provides a better performance!- Specified by:
updateCategoryin interfaceCategorizable- Parameters:
category- The new category of the channel.- Returns:
- A future to check if the update was successful.
-
removeCategory
default java.util.concurrent.CompletableFuture<java.lang.Void> removeCategory()
Removes the category of the channel.If you want to update several settings at once, it's recommended to use the
ServerTextChannelUpdaterfromcreateUpdater()which provides a better performance!- Specified by:
removeCategoryin interfaceCategorizable- Returns:
- A future to check if the update was successful.
-
getSlowmodeDelayInSeconds
int getSlowmodeDelayInSeconds()
Gets the delay for slowmode.- Returns:
- The delay in seconds.
-
hasSlowmode
default boolean hasSlowmode()
Check whether slowmode is activated for this channel.- Returns:
- Whether this channel enforces a slowmode.
-
updateSlowmodeDelayInSeconds
default java.util.concurrent.CompletableFuture<java.lang.Void> updateSlowmodeDelayInSeconds(int delay)
Set a slowmode for this channel.If you want to update several settings at once, it's recommended to use the
ServerTextChannelUpdaterfromcreateUpdater()which provides a better performance!- Parameters:
delay- The slowmode delay in seconds.- Returns:
- A future to check if the update was successful.
-
unsetSlowmode
default java.util.concurrent.CompletableFuture<java.lang.Void> unsetSlowmode()
Deactivate slowmode for this channel.If you want to update several settings at once, it's recommended to use the
ServerTextChannelUpdaterfromcreateUpdater()which provides a better performance!- Returns:
- A future to check if the update was successful.
-
getCurrentCachedInstance
default java.util.Optional<ServerTextChannel> getCurrentCachedInstance()
Description copied from interface:UpdatableFromCacheGets an updated instance of this entity from the cache. This is for example necessary if an instance got invalid by a reconnect to Discord which invalidates all existing instances which means they do not get any further updates from Discord applied. Due to that, references to instances should usually not be held for an extended period of time. If they are, this method can be used to retrieve the current instance from the cache, that gets updates from Discord, in case this one was invalidated.This method returns the currently cached entity, or an empty
Optionalif the entity is not cached any longer, for example because it was deleted or the message was thrown out of the cache.- Specified by:
getCurrentCachedInstancein interfaceChannel- Specified by:
getCurrentCachedInstancein interfaceRegularServerChannel- Specified by:
getCurrentCachedInstancein interfaceServerChannel- Specified by:
getCurrentCachedInstancein interfaceTextChannel- Specified by:
getCurrentCachedInstancein interfaceUpdatableFromCache- Returns:
- The current cached instance.
-
getLatestInstance
default java.util.concurrent.CompletableFuture<ServerTextChannel> getLatestInstance()
Description copied from interface:UpdatableGets an updated instance of this entity from the cache or from Discord directly. This is for example necessary if an instance got invalid by a reconnect to Discord which invalidates all existing instances which means they do not get any further updates from Discord applied. Due to that, references to instances should usually not be held for an extended period of time. If they are, this method can be used to retrieve the current instance from the cache if present or from Discord directly.This method returns the currently cached entity if present, or request the entity from Discord if it is not cached or not permanently cached. If the entity is a fully cached entity and is not in the cache any longer, for example because it was deleted or the message was thrown out of the cache, the
CompletableFuturecompletes exceptionally with aNoSuchElementException. If a request to Discord is made, the according remote call exception will be used to complete theCompletableFutureexceptionally.- Specified by:
getLatestInstancein interfaceChannel- Specified by:
getLatestInstancein interfaceRegularServerChannel- Specified by:
getLatestInstancein interfaceServerChannel- Specified by:
getLatestInstancein interfaceTextChannel- Specified by:
getLatestInstancein interfaceUpdatable- Specified by:
getLatestInstancein interfaceUpdatableFromCache- Returns:
- The current cached instance.
-
createThreadForMessage
default java.util.concurrent.CompletableFuture<ServerThreadChannel> createThreadForMessage(Message message, java.lang.String name, AutoArchiveDuration autoArchiveDuration)
Creates a thread for a message in this ServerTextChannel.- Parameters:
message- The message to create the thread for.name- The Thread name.autoArchiveDuration- Duration in minutes to automatically archive the thread after recent activity.- Returns:
- The created ServerThreadChannel.
-
createThreadForMessage
default java.util.concurrent.CompletableFuture<ServerThreadChannel> createThreadForMessage(Message message, java.lang.String name, java.lang.Integer autoArchiveDuration)
Creates a thread for a message in this ServerTextChannel.- Parameters:
message- The message to create the thread for.name- The Thread name.autoArchiveDuration- Duration in minutes to automatically archive the thread after recent activity.- Returns:
- The created ServerThreadChannel.
-
createThread
default java.util.concurrent.CompletableFuture<ServerThreadChannel> createThread(ChannelType channelType, java.lang.String name, java.lang.Integer autoArchiveDuration)
Creates a thread which is not related to a message.Creating a private thread requires the server to be boosted. The 3 day and 7 day archive durations require the server to be boosted. The server features will indicate if that is possible for the server.
- Parameters:
channelType- A ChannelType for a thread.name- The thread name.autoArchiveDuration- Duration in minutes to automatically archive the thread after recent activity.- Returns:
- The created ServerThreadChannel.
-
createThread
default java.util.concurrent.CompletableFuture<ServerThreadChannel> createThread(ChannelType channelType, java.lang.String name, AutoArchiveDuration autoArchiveDuration)
Creates a thread which is not related to a message.Creating a private thread requires the server to be boosted. The 3 day and 7 day archive durations require the server to be boosted. The server features will indicate if that is possible for the server.
- Parameters:
channelType- A ChannelType for a thread.name- The thread name.autoArchiveDuration- Duration in minutes to automatically archive the thread after recent activity.- Returns:
- The created ServerThreadChannel.
-
createThread
default java.util.concurrent.CompletableFuture<ServerThreadChannel> createThread(ChannelType channelType, java.lang.String name, java.lang.Integer autoArchiveDuration, java.lang.Boolean inviteable)
Creates a thread which is not related to a message.Creating a private thread requires the server to be boosted. The 3 day and 7 day archive durations require the server to be boosted. The server features will indicate if that is possible for the server.
- Parameters:
channelType- A ChannelType for a thread.name- The thread name.autoArchiveDuration- Duration in minutes to automatically archive the thread after recent activity.inviteable- Whether non-moderators can add other non-moderators to a thread; only available when creating a private thread.- Returns:
- The created ServerThreadChannel.
-
createThread
default java.util.concurrent.CompletableFuture<ServerThreadChannel> createThread(ChannelType channelType, java.lang.String name, AutoArchiveDuration autoArchiveDuration, java.lang.Boolean inviteable)
Creates a thread which is not related to a message.Creating a private thread requires the server to be boosted. The 3 day and 7 day archive durations require the server to be boosted. The server features will indicate if that is possible for the server.
- Parameters:
channelType- A ChannelType for a thread.name- The thread name.autoArchiveDuration- Duration in minutes to automatically archive the thread after recent activity.inviteable- Whether non-moderators can add other non-moderators to a thread; only available when creating a private thread.- Returns:
- The created ServerThreadChannel.
-
getPublicArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getPublicArchivedThreads()
Gets the public archived threads.Returns archived threads in the channel that are public. When called on a SERVER_TEXT_CHANNEL, returns threads of type SERVER_PUBLIC_THREAD. When called on a SERVER_NEWS_CHANNEL returns threads of type SERVER_NEWS_THREAD. Threads are ordered by archive_timestamp, in descending order. Requires the READ_MESSAGE_HISTORY permission.
- Returns:
- The ArchivedThreads.
-
getPublicArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getPublicArchivedThreads(long before)
Gets the public archived threads.Returns archived threads in the channel that are public. When called on a SERVER_TEXT_CHANNEL, returns threads of type SERVER_PUBLIC_THREAD. When called on a SERVER_NEWS_CHANNEL returns threads of type SERVER_NEWS_THREAD. Threads are ordered by archive_timestamp, in descending order. Requires the READ_MESSAGE_HISTORY permission.
- Parameters:
before- Get public archived threads before the thread with this id.- Returns:
- The ArchivedThreads.
-
getPublicArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getPublicArchivedThreads(int limit)
Gets the public archived threads.Returns archived threads in the channel that are public. When called on a SERVER_TEXT_CHANNEL, returns threads of type SERVER_PUBLIC_THREAD. When called on a SERVER_NEWS_CHANNEL returns threads of type SERVER_NEWS_THREAD. Threads are ordered by archive_timestamp, in descending order. Requires the READ_MESSAGE_HISTORY permission.
- Parameters:
limit- The maximum amount of public archived threads.- Returns:
- The ArchivedThreads.
-
getPublicArchivedThreads
java.util.concurrent.CompletableFuture<ArchivedThreads> getPublicArchivedThreads(java.lang.Long before, java.lang.Integer limit)
Gets the public archived threads.Returns archived threads in the channel that are public. When called on a SERVER_TEXT_CHANNEL, returns threads of type SERVER_PUBLIC_THREAD. When called on a SERVER_NEWS_CHANNEL returns threads of type SERVER_NEWS_THREAD. Threads are ordered by archive_timestamp, in descending order. Requires the READ_MESSAGE_HISTORY permission.
- Parameters:
before- Get public archived threads before the thread with this id.limit- The maximum amount of public archived threads.- Returns:
- The ArchivedThreads.
-
getPrivateArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getPrivateArchivedThreads()
Gets the private archived threads.Returns archived threads in the channel that are of type SERVER_PRIVATE_THREAD. Threads are ordered by archive_timestamp, in descending order. Requires both the READ_MESSAGE_HISTORY and MANAGE_THREADS permissions.
- Returns:
- The ArchivedThreads.
-
getPrivateArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getPrivateArchivedThreads(long before)
Gets the private archived threads.Returns archived threads in the channel that are of type SERVER_PRIVATE_THREAD. Threads are ordered by archive_timestamp, in descending order. Requires both the READ_MESSAGE_HISTORY and MANAGE_THREADS permissions.
- Parameters:
before- Get private archived threads before the thread with this id.- Returns:
- The ArchivedThreads.
-
getPrivateArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getPrivateArchivedThreads(int limit)
Gets the private archived threads.Returns archived threads in the channel that are of type SERVER_PRIVATE_THREAD. Threads are ordered by archive_timestamp, in descending order. Requires both the READ_MESSAGE_HISTORY and MANAGE_THREADS permissions.
- Parameters:
limit- The maximum amount of private archived threads.- Returns:
- The ArchivedThreads.
-
getPrivateArchivedThreads
java.util.concurrent.CompletableFuture<ArchivedThreads> getPrivateArchivedThreads(java.lang.Long before, java.lang.Integer limit)
Gets the private archived threads.Returns archived threads in the channel that are of type SERVER_PRIVATE_THREAD. Threads are ordered by archive_timestamp, in descending order. Requires both the READ_MESSAGE_HISTORY and MANAGE_THREADS permissions.
- Parameters:
before- Get private archived threads before the thread with this id.limit- The maximum amount of private archived threads.- Returns:
- The ArchivedThreads.
-
getJoinedPrivateArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getJoinedPrivateArchivedThreads()
Gets the joined private archived threads.Returns archived threads in the channel that are of type SERVER_PRIVATE_THREAD, and the user has joined.
- Returns:
- The ArchivedThreads.
-
getJoinedPrivateArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getJoinedPrivateArchivedThreads(long before)
Gets the joined private archived threads.Returns archived threads in the channel that are of type SERVER_PRIVATE_THREAD, and the user has joined.
- Parameters:
before- Get the joined private archived threads before the thread with this id.- Returns:
- The ArchivedThreads.
-
getJoinedPrivateArchivedThreads
default java.util.concurrent.CompletableFuture<ArchivedThreads> getJoinedPrivateArchivedThreads(int limit)
Gets the joined private archived threads.Returns archived threads in the channel that are of type SERVER_PRIVATE_THREAD, and the user has joined.
- Parameters:
limit- The maximum amount of private archived threads.- Returns:
- The ArchivedThreads.
-
getJoinedPrivateArchivedThreads
java.util.concurrent.CompletableFuture<ArchivedThreads> getJoinedPrivateArchivedThreads(java.lang.Long before, java.lang.Integer limit)
Gets the joined private archived threads.Returns archived threads in the channel that are of type SERVER_PRIVATE_THREAD, and the user has joined.
- Parameters:
before- Get the joined private archived threads before the thread with this id.limit- The maximum amount of private archived threads.- Returns:
- The ArchivedThreads.
-
-