Exception: Schwab::RateLimitError

Inherits:
ApiError show all
Defined in:
lib/schwab/error.rb

Overview

Raised when API returns 429 Too Many Requests

Instance Attribute Summary collapse

Attributes inherited from ApiError

#response_body, #response_headers, #status

Instance Method Summary collapse

Constructor Details

#initialize(message = nil, retry_after: nil, **options) ⇒ RateLimitError

Returns a new instance of RateLimitError.



35
36
37
38
# File 'lib/schwab/error.rb', line 35

def initialize(message = nil, retry_after: nil, **options)
  super(message, **options)
  @retry_after = retry_after
end

Instance Attribute Details

#retry_afterObject (readonly)

Returns the value of attribute retry_after.



33
34
35
# File 'lib/schwab/error.rb', line 33

def retry_after
  @retry_after
end