Class ReactiveEventAdapter

java.lang.Object
discord4j.core.event.ReactiveEventAdapter

public abstract class ReactiveEventAdapter extends Object
An adapter class to attach reactive listeners to each event type. Create a new instance to subclass it and override one or more event methods. See Event class for more details.
  • Constructor Details

    • ReactiveEventAdapter

      public ReactiveEventAdapter()
  • Method Details

    • onReady

      public Publisher<?> onReady(ReadyEvent event)
      Invoked as Discord has established a fresh Gateway session. This event can be used to track the bot connection details and contains the initial state required to operate with the real-time Gateway. See ReadyEvent and Discord documentation for more details about this event.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onResume

      public Publisher<?> onResume(ResumeEvent event)
      Invoked when the gateway connection is successfully resumed.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMessageCreate

      public Publisher<?> onMessageCreate(MessageCreateEvent event)
      Invoked when a message is sent in a message channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMessageDelete

      public Publisher<?> onMessageDelete(MessageDeleteEvent event)
      Invoked when a message is deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMessageUpdate

      public Publisher<?> onMessageUpdate(MessageUpdateEvent event)
      Invoked when a message is updated. This event includes both normal message editing as well as the following behavior regarding embeds: When a message with a link is sent, it does not initially contain its embed. When Discord creates the embed, this event is fired with it added to the embeds list.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMessageBulkDelete

      public Publisher<?> onMessageBulkDelete(MessageBulkDeleteEvent event)
      Invoked when multiple messages are deleted at once.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onReactionAdd

      public Publisher<?> onReactionAdd(ReactionAddEvent event)
      Invoked when a reaction is added to a message. Guild ID might be missing if this event fires for a DM channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onReactionRemove

      public Publisher<?> onReactionRemove(ReactionRemoveEvent event)
      Invoked when a reaction is removed from a message. Guild ID might be missing if this event fires for a DM channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onReactionRemoveEmoji

      public Publisher<?> onReactionRemoveEmoji(ReactionRemoveEmojiEvent event)
      Invoked when the reactions for one emoji are removed from a message. Guild ID might be missing if this event fires for a DM channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onReactionRemoveAll

      public Publisher<?> onReactionRemoveAll(ReactionRemoveAllEvent event)
      Invoked when all of the reactions on a message are removed. Guild ID might be missing if this event fires for a DM channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onApplicationCommandCreate

      public Publisher<?> onApplicationCommandCreate(ApplicationCommandCreateEvent event)
      Invoked when an application command relevant to the current user is created. Guild ID might be missing if this event fires for a DM channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onApplicationCommandUpdate

      public Publisher<?> onApplicationCommandUpdate(ApplicationCommandUpdateEvent event)
      Invoked when an application command relevant to the current user is updated. Guild ID might be missing if this event fires for a DM channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onApplicationCommandDelete

      public Publisher<?> onApplicationCommandDelete(ApplicationCommandDeleteEvent event)
      Invoked when an application command relevant to the current user is deleted. Guild ID might be missing if this event fires for a DM channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onGuildCreate

      public Publisher<?> onGuildCreate(GuildCreateEvent event)
      Invoked when the bot receives initial information on startup, after it joins a guild, or after an outage is resolved.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onGuildDelete

      public Publisher<?> onGuildDelete(GuildDeleteEvent event)
      Invoked when the bot leaves or is kicked from a guild, or if a guild has become unavailable due to an outage.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onGuildUpdate

      public Publisher<?> onGuildUpdate(GuildUpdateEvent event)
      Invoked when a guild is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMemberJoin

      public Publisher<?> onMemberJoin(MemberJoinEvent event)
      Invoked when a user joins a guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMemberLeave

      public Publisher<?> onMemberLeave(MemberLeaveEvent event)
      Invoked when a user leaves a guild, or is kicked from it.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMemberUpdate

      public Publisher<?> onMemberUpdate(MemberUpdateEvent event)
      Invoked when a user's nickname or roles change in a guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMemberChunk

      public Publisher<?> onMemberChunk(MemberChunkEvent event)
      Invoked when members are streamed to the client from Discord.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onEmojisUpdate

      public Publisher<?> onEmojisUpdate(EmojisUpdateEvent event)
      Invoked when an emoji is added, deleted or edited in a guild. The emojis set includes ALL emojis of the guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onStickersUpdate

      public Publisher<?> onStickersUpdate(StickersUpdateEvent event)
      Invoked when a sticker is added, deleted or edited in a guild. The emojis set includes ALL stickers of the guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onAuditLogEntryCreate

      public Publisher<?> onAuditLogEntryCreate(AuditLogEntryCreateEvent event)
      Invoked when a new entry in Audit Log is created in a guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onBan

      public Publisher<?> onBan(BanEvent event)
      Invoked when a user is banned from a guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onUnban

      public Publisher<?> onUnban(UnbanEvent event)
      Invoked when a user is unbanned from a guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onIntegrationsUpdate

      public Publisher<?> onIntegrationsUpdate(IntegrationsUpdateEvent event)
      Invoked when guild integrations are updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onWebhooksUpdate

      public Publisher<?> onWebhooksUpdate(WebhooksUpdateEvent event)
      Invoked when a webhook is updated in a guild. Discord does not send any information about what was actually updated. This is simply a notification of some update.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onTextChannelCreate

      public Publisher<?> onTextChannelCreate(TextChannelCreateEvent event)
      Invoked when a guild text channel is created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onTextChannelDelete

      public Publisher<?> onTextChannelDelete(TextChannelDeleteEvent event)
      Invoked when a guild text channel is deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onTextChannelUpdate

      public Publisher<?> onTextChannelUpdate(TextChannelUpdateEvent event)
      Invoked when a guild text channel is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onVoiceChannelCreate

      public Publisher<?> onVoiceChannelCreate(VoiceChannelCreateEvent event)
      Invoked when a guild voice channel is created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onVoiceChannelDelete

      public Publisher<?> onVoiceChannelDelete(VoiceChannelDeleteEvent event)
      Invoked when a guild voice channel is deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onVoiceChannelUpdate

      public Publisher<?> onVoiceChannelUpdate(VoiceChannelUpdateEvent event)
      Invoked when a guild voice channel is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onCategoryCreate

      public Publisher<?> onCategoryCreate(CategoryCreateEvent event)
      Invoked when a guild channel category is created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onCategoryDelete

      public Publisher<?> onCategoryDelete(CategoryDeleteEvent event)
      Invoked when a guild channel category is deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onCategoryUpdate

      public Publisher<?> onCategoryUpdate(CategoryUpdateEvent event)
      Invoked when a guild channel category is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onNewsChannelCreate

      public Publisher<?> onNewsChannelCreate(NewsChannelCreateEvent event)
      Invoked when a guild news channel is created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onNewsChannelDelete

      public Publisher<?> onNewsChannelDelete(NewsChannelDeleteEvent event)
      Invoked when a guild news channel is deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onNewsChannelUpdate

      public Publisher<?> onNewsChannelUpdate(NewsChannelUpdateEvent event)
      Invoked when a guild news channel is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onStoreChannelCreate

      public Publisher<?> onStoreChannelCreate(StoreChannelCreateEvent event)
      Invoked when a guild store channel is created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onStoreChannelDelete

      public Publisher<?> onStoreChannelDelete(StoreChannelDeleteEvent event)
      Invoked when a guild store channel is deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onStoreChannelUpdate

      public Publisher<?> onStoreChannelUpdate(StoreChannelUpdateEvent event)
      Invoked when a guild store channel is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onThreadChannelCreateEvent

      public Publisher<?> onThreadChannelCreateEvent(ThreadChannelCreateEvent event)
      Invoked when a thread is created, relevant to the current user, or when the current user is added to a thread.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onThreadChannelDeleteEvent

      public Publisher<?> onThreadChannelDeleteEvent(ThreadChannelDeleteEvent event)
      Invoked when a thread relevant to the current user is deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onThreadChannelUpdateEvent

      public Publisher<?> onThreadChannelUpdateEvent(ThreadChannelUpdateEvent event)
      Invoked when a thread relevant to the current user is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onThreadListSyncEvent

      public Publisher<?> onThreadListSyncEvent(ThreadListSyncEvent event)
      Invoked when the current user gains access to a thread channel.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onThreadMembersUpdateEvent

      public Publisher<?> onThreadMembersUpdateEvent(ThreadMembersUpdateEvent event)
      Invoked when anyone is added to or removed from a thread. If the current user does not have the Intent.GUILD_MEMBERS Gateway Intent, then this event will only be sent if the current user was added to or removed from the thread.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onThreadMemberUpdateEvent

      public Publisher<?> onThreadMemberUpdateEvent(ThreadMemberUpdateEvent event)
      Invoked when the thread member object for the current user is updated. This event is documented for completeness, but unlikely to be used by most bots. For bots, this event largely is just a signal that you are a member of the thread.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onUnknownChannelCreate

      public Publisher<?> onUnknownChannelCreate(UnknownChannelCreateEvent event)
      Invoked when a guild channel is created, but its type is not supported or implemented.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onUnknownChannelDelete

      public Publisher<?> onUnknownChannelDelete(UnknownChannelDeleteEvent event)
      Invoked when a guild channel is deleted, but its type is not supported or implemented.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onUnknownChannelUpdate

      public Publisher<?> onUnknownChannelUpdate(UnknownChannelUpdateEvent event)
      Invoked when a guild channel is updated, but its type is not supported or implemented.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onTypingStart

      public Publisher<?> onTypingStart(TypingStartEvent event)
      Invoked when a user has started typing a message.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onPinsUpdate

      public Publisher<?> onPinsUpdate(PinsUpdateEvent event)
      Invoked when a channel's pinned messages are updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onRoleCreate

      public Publisher<?> onRoleCreate(RoleCreateEvent event)
      Invoked when a role is created in a guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onRoleDelete

      public Publisher<?> onRoleDelete(RoleDeleteEvent event)
      Invoked when a role is deleted from a guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onRoleUpdate

      public Publisher<?> onRoleUpdate(RoleUpdateEvent event)
      Invoked when one or more role's properties are updated in a guild.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onInviteCreate

      public Publisher<?> onInviteCreate(InviteCreateEvent event)
      Invoked when an invite to a channel is created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onInviteDelete

      public Publisher<?> onInviteDelete(InviteDeleteEvent event)
      Invoked when an invite to a channel has expired.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onUserUpdate

      public Publisher<?> onUserUpdate(UserUpdateEvent event)
      Invoked when one or more user's properties were updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onPresenceUpdate

      public Publisher<?> onPresenceUpdate(PresenceUpdateEvent event)
      Invoked when a user's presence or status has changed.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onVoiceStateUpdate

      public Publisher<?> onVoiceStateUpdate(VoiceStateUpdateEvent event)
      Invoked when a user's connected voice channel and status, was requested or has updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onVoiceServerUpdate

      public Publisher<?> onVoiceServerUpdate(VoiceServerUpdateEvent event)
      Invoked when a guild's voice server is requested or is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onConnect

      public Publisher<?> onConnect(ConnectEvent event)
      Invoked when connecting to the Gateway for the first time only.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onReconnect

      public Publisher<?> onReconnect(ReconnectEvent event)
      Invoked when subsequent reconnections to the Gateway, either through resumption or full retry.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onDisconnect

      public Publisher<?> onDisconnect(DisconnectEvent event)
      Invoked when the bot has disconnected from the Gateway.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onReconnectStart

      public Publisher<?> onReconnectStart(ReconnectStartEvent event)
      Invoked when a resumption or reconnection attempt has begun.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onReconnectFail

      public Publisher<?> onReconnectFail(ReconnectFailEvent event)
      Invoked when a resumption or reconnection attempt has failed but can be retried.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onSessionInvalidated

      public Publisher<?> onSessionInvalidated(SessionInvalidatedEvent event)
      Invoked when a gateway session has been invalidated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onInteractionCreate

      public Publisher<?> onInteractionCreate(InteractionCreateEvent event)
      Invoked when a user starts an interaction.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onDeferrableInteraction

      public Publisher<?> onDeferrableInteraction(DeferrableInteractionEvent event)
      Invoked when a user starts a deferrable interaction.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onApplicationCommandInteraction

      public Publisher<?> onApplicationCommandInteraction(ApplicationCommandInteractionEvent event)
      Invoked when a user starts an application command interaction.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onChatInputInteraction

      public Publisher<?> onChatInputInteraction(ChatInputInteractionEvent event)
      Invoked when a user issues a chat input command (formerly "slash command").
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onMessageInteraction

      public Publisher<?> onMessageInteraction(MessageInteractionEvent event)
      Invoked when a user issues a message command (context menu action on a message).
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onUserInteraction

      public Publisher<?> onUserInteraction(UserInteractionEvent event)
      Invoked when a user issues a user command (context menu action on a user).
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onComponentInteraction

      public Publisher<?> onComponentInteraction(ComponentInteractionEvent event)
      Invoked when a user interacts with a component.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onButtonInteraction

      public Publisher<?> onButtonInteraction(ButtonInteractionEvent event)
      Invoked when a user interacts with a button component.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onSelectMenuInteraction

      public Publisher<?> onSelectMenuInteraction(SelectMenuInteractionEvent event)
      Invoked when a user interacts with a select menu.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onAutoCompleteInteraction

      public Publisher<?> onAutoCompleteInteraction(AutoCompleteInteractionEvent event)
      Invoked when a user starts an auto-complete interaction.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onChatInputAutoCompleteInteraction

      public Publisher<?> onChatInputAutoCompleteInteraction(ChatInputAutoCompleteEvent event)
      Invoked when a user is typing a chat input command option that has auto-complete enabled.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onModalSubmitInteraction

      public Publisher<?> onModalSubmitInteraction(ModalSubmitInteractionEvent event)
      Invoked when a user starts a modal supported interaction.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onIntegrationCreate

      public Publisher<?> onIntegrationCreate(IntegrationCreateEvent event)
      Invoked when an integration has been created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onIntegrationUpdate

      public Publisher<?> onIntegrationUpdate(IntegrationUpdateEvent event)
      Invoked when an integration has been updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onIntegrationDelete

      public Publisher<?> onIntegrationDelete(IntegrationDeleteEvent event)
      Invoked when an integration has been deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onAutoModRuleCreate

      public Publisher<?> onAutoModRuleCreate(AutoModRuleCreateEvent event)
      Invoked when an automod rule has been created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onAutoModRuleUpdate

      public Publisher<?> onAutoModRuleUpdate(AutoModRuleUpdateEvent event)
      Invoked when an automod rule has been updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onAutoModRuleDelete

      public Publisher<?> onAutoModRuleDelete(AutoModRuleDeleteEvent event)
      Invoked when an automod rule has been deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onAutoModActionExecution

      public Publisher<?> onAutoModActionExecution(AutoModActionExecutedEvent event)
      Invoked when an automod rule action has been executed.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onScheduledEventCreate

      public Publisher<?> onScheduledEventCreate(ScheduledEventCreateEvent event)
      Invoked when a scheduled event is created.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onScheduledEventUpdate

      public Publisher<?> onScheduledEventUpdate(ScheduledEventUpdateEvent event)
      Invoked when a scheduled event is updated.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onScheduledEventDelete

      public Publisher<?> onScheduledEventDelete(ScheduledEventDeleteEvent event)
      Invoked when a scheduled event is deleted.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onScheduledEventUserAdd

      public Publisher<?> onScheduledEventUserAdd(ScheduledEventUserAddEvent event)
      Invoked when a user subscribes to a scheduled event.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • onScheduledEventUserRemove

      public Publisher<?> onScheduledEventUserRemove(ScheduledEventUserRemoveEvent event)
      Invoked when a user unsubscribes from a scheduled event.
      Parameters:
      event - the event instance
      Returns:
      a Publisher that completes when this listener has done processing the event, for example, returning any Mono, Flux or synchronous code using Mono.fromRunnable(Runnable).
    • from

      public static ReactiveEventAdapter from(ReactiveEventAdapter... adapters)
      Create a composite ReactiveEventAdapter from multiple adapters.
      Parameters:
      adapters - an array of adapters to combine
      Returns:
      a composite adapter
    • hookOnEvent

      public Publisher<?> hookOnEvent(Event event)