Class GuildTimeoutEvent

java.lang.Object
net.dv8tion.jda.api.events.Event
net.dv8tion.jda.api.events.guild.GuildTimeoutEvent
All Implemented Interfaces:
GenericEvent

public class GuildTimeoutEvent extends Event
Indicates that a guild failed to ready up and timed out.
Usually this event will be fired right before a ReadyEvent.

This will mark the guild as unavailable and it will not be usable when JDA becomes ready. You can check all unavailable guilds with ReadyEvent.getGuildUnavailableCount() and JDA.getUnavailableGuilds().

Developer Note

Discord may also explicitly mark guilds as unavailable during the setup, in which case this event will not fire. It is recommended to check for unavailable guilds in the ready event explicitly to avoid any ambiguity.

  • Constructor Details

    • GuildTimeoutEvent

      public GuildTimeoutEvent(@Nonnull JDA api, long guildId)
  • Method Details

    • getGuildIdLong

      public long getGuildIdLong()
      The guild id for the timed out guild
      Returns:
      The guild id
    • getGuildId

      @Nonnull public String getGuildId()
      The guild id for the timed out guild
      Returns:
      The guild id