Class: Harvest::RateLimitStatus
- Inherits:
-
Hashie::Mash
- Object
- Hashie::Mash
- Harvest::RateLimitStatus
- Includes:
- Model
- Defined in:
- lib/harvest/rate_limit_status.rb
Overview
The model that contains the information about the user's rate limit
Fields
- last_access_at
-
The last registered request
- count
-
The current number of requests registered
- timeframe_limit
-
The amount of seconds before a rate limit refresh occurs
- max_calls
-
The number of requests you can make within the timeframe_limit
- lockout_seconds
-
If you exceed the rate limit, how long you will be locked out from Harvest
Instance Method Summary (collapse)
-
- (Boolean) over_limit?
Returns true if the user is over their rate limit.
Methods included from Model
Instance Method Details
- (Boolean) over_limit?
Returns true if the user is over their rate limit
19 20 21 |
# File 'lib/harvest/rate_limit_status.rb', line 19 def over_limit? count > max_calls end |