Module: HomeAway::API::Domain::Listing
- Included in:
- Client
- Defined in:
- lib/homeaway/api/domain/listing.rb
Instance Method Summary collapse
-
#listing(id, q = nil, l = nil) ⇒ HomeAway::API::Response
Given a listing id, return details about the listing.
Instance Method Details
#listing(id, q = nil, l = nil) ⇒ HomeAway::API::Response
Given a listing id, return details about the listing.
analogous to calling a GET on API url /public/listing
Headers:
-
X-HomeAway-DisplayLocale: If a locale is not specified in a query param, it will be searched for in the X-HomeAway-DisplayLocale Header. If it is not supplied in either area the default locale of the user will be selected if it exists. Otherwise the Accept-Language Header will be used.
32 33 34 35 36 37 |
# File 'lib/homeaway/api/domain/listing.rb', line 32 def listing(id, q=nil, l=nil) params = {'id' => id.to_s} params['locale'] = l unless l == nil params['q'] = HomeAway::API::Util::Validators.array(q) unless q == nil get '/public/listing', HomeAway::API::Util::Validators.query_keys(params) end |