Class: Zester::Valuation
Instance Attribute Summary
Attributes inherited from Resource
#client
Instance Method Summary
collapse
Methods inherited from Resource
#get_results, #initialize
Instance Method Details
#chart(params = {}) ⇒ Object
18
19
20
21
22
23
24
|
# File 'lib/zester/valuation.rb', line 18
def chart(params = {})
if params['zpid'].nil?
raise ArgumentError, "zpid is required"
end
params['unit-type'] ||= 'dollar'
get_results('GetChart', :chart, params)
end
|
#comps(params = {}) ⇒ Object
26
27
28
29
30
31
32
|
# File 'lib/zester/valuation.rb', line 26
def comps(params = {})
if params['zpid'].nil?
raise ArgumentError, "zpid is required"
end
params['count'] ||= 10
get_results('GetComps', :comps, params)
end
|
#search_results(params = {}) ⇒ Object
11
12
13
14
15
16
|
# File 'lib/zester/valuation.rb', line 11
def search_results(params = {})
if params['address'].nil? || params['citystatezip'].nil?
raise ArgumentError, "address and citystatezip are required"
end
get_results('GetSearchResults', :searchresults, params)
end
|
#zestimate(params = {}) ⇒ Object
4
5
6
7
8
9
|
# File 'lib/zester/valuation.rb', line 4
def zestimate(params = {})
if params['zpid'].nil?
raise ArgumentError, "zpid is required"
end
get_results('GetZestimate', :zestimate, params)
end
|