Module: TrestleData::API::ReversePhone
- Includes:
- Util
- Included in:
- Client
- Defined in:
- lib/trestle-data/api/reverse_phone.rb
Constant Summary
collapse
- API_VERSION =
'3.0'
Constants included
from Util
Util::ROOT_URL
Instance Attribute Summary
Attributes included from Configurable
#api_key
Instance Method Summary
collapse
Methods included from Util
#build_url, #call, #phone_number_valid?
#configure, keys
Instance Method Details
#api_key_valid? ⇒ Boolean
14
15
16
17
|
# File 'lib/trestle-data/api/reverse_phone.rb', line 14
def api_key_valid?
true unless api_key.blank?
false
end
|
#reverse_lookup(phone_number, options = {}) ⇒ Object
10
11
12
|
# File 'lib/trestle-data/api/reverse_phone.rb', line 10
def reverse_lookup(phone_number, options = {})
call('phone', API_VERSION, :get, {phone: phone_number, api_key: api_key}.merge(options))
end
|