Class RateLimitedException

java.lang.Object
java.lang.Throwable
java.lang.Exception
net.dv8tion.jda.api.exceptions.RateLimitedException
All Implemented Interfaces:
Serializable

public class RateLimitedException extends Exception
Indicates that we received a 429: Too Many Requests response
See Also:
  • Constructor Details

    • RateLimitedException

      public RateLimitedException(Route.CompiledRoute route, long retryAfter)
    • RateLimitedException

      public RateLimitedException(String route, long retryAfter)
  • Method Details

    • getRateLimitedRoute

      @Nonnull public String getRateLimitedRoute()
      The route responsible for the rate limit bucket that is used in the responsible RateLimiter
      Returns:
      The corresponding route
    • getRetryAfter

      public long getRetryAfter()
      The back-off delay in milliseconds that should be respected before trying to query the route again
      Returns:
      The back-off delay in milliseconds