class Harvest::API::Account
API
Methods to contain all account actions
Public Instance Methods
rate_limit_status()
click to toggle source
Returns the current rate limit information @return [Harvest::RateLimitStatus]
# File lib/harvest/api/account.rb, line 9 def rate_limit_status response = request(:get, credentials, '/account/rate_limit_status') Harvest::RateLimitStatus.parse(response.body).first end
who_am_i()
click to toggle source
Returns the current logged in user @return [Harvest::User]
# File lib/harvest/api/account.rb, line 16 def who_am_i response = request(:get, credentials, '/account/who_am_i') parsed = JSON.parse(response.body) Harvest::User.parse(parsed).first.tap do |user| user.company = parsed["company"] end end