Class: ReviewsCatcher::Account

Inherits:
BaseService show all
Defined in:
lib/reviews_catcher/account.rb

Instance Attribute Summary

Attributes inherited from BaseService

#client

Instance Method Summary collapse

Methods inherited from BaseService

#auth, #get, #get_api_rating, #get_api_reviews, #initialize, #url

Constructor Details

This class inherits a constructor from ReviewsCatcher::BaseService

Instance Method Details

#aggregate_ratingObject



10
11
12
13
14
# File 'lib/reviews_catcher/account.rb', line 10

def aggregate_rating
  response = JSON.parse(get_api_rating.body)

  response['aggregate_rating']
end

#nameObject



4
5
6
7
8
# File 'lib/reviews_catcher/account.rb', line 4

def name
  response = JSON.parse(get_api_rating.body)

  response['account_name']
end

#rating_countObject



16
17
18
19
20
# File 'lib/reviews_catcher/account.rb', line 16

def rating_count
  response = JSON.parse(get_api_rating.body)

  response['rating_count']
end