class TrustedSearch::V2::Location

Attributes

resource[RW]

Public Class Methods

new() click to toggle source
# File lib/trustedsearch/v2/locations.rb, line 6
def initialize
  @resource = 'locations'
end

Public Instance Methods

index() click to toggle source

Retrieve an array of all available hooks

# File lib/trustedsearch/v2/locations.rb, line 11
def index()
  method_url = @resource
  return self.get(method_url)
end
listings(location_id = nil) click to toggle source

Get the details of a single hook

# File lib/trustedsearch/v2/locations.rb, line 17
def listings(location_id = nil)
  method_url = @resource + "/" + location_id + "/listings"
  params = {}
  return self.get(method_url, params)
end