Exception: Slk::RateLimitError

Inherits:
ApiError show all
Defined in:
lib/slk.rb

Overview

Slack rate-limit error. Carries Retry-After in seconds when present.

Instance Attribute Summary collapse

Attributes inherited from ApiError

#code

Instance Method Summary collapse

Constructor Details

#initialize(message, retry_after: nil) ⇒ RateLimitError

Returns a new instance of RateLimitError.



48
49
50
51
# File 'lib/slk.rb', line 48

def initialize(message, retry_after: nil)
  super(message, code: :ratelimited)
  @retry_after = retry_after
end

Instance Attribute Details

#retry_afterObject (readonly)

Returns the value of attribute retry_after.



46
47
48
# File 'lib/slk.rb', line 46

def retry_after
  @retry_after
end