Exception: Hanko::RateLimitError
- Defined in:
- lib/hanko/errors.rb
Overview
Raised when the API returns HTTP 429 Too Many Requests.
Instance Attribute Summary collapse
-
#retry_after ⇒ Integer?
readonly
Seconds to wait before retrying.
Attributes inherited from ApiError
Instance Method Summary collapse
-
#initialize(message = nil, status: nil, body: nil, retry_after: nil) ⇒ RateLimitError
constructor
A new instance of RateLimitError.
Constructor Details
#initialize(message = nil, status: nil, body: nil, retry_after: nil) ⇒ RateLimitError
Returns a new instance of RateLimitError.
55 56 57 58 |
# File 'lib/hanko/errors.rb', line 55 def initialize( = nil, status: nil, body: nil, retry_after: nil) @retry_after = retry_after super(, status: status, body: body) end |
Instance Attribute Details
#retry_after ⇒ Integer? (readonly)
Returns seconds to wait before retrying.
49 50 51 |
# File 'lib/hanko/errors.rb', line 49 def retry_after @retry_after end |