filter
is an Object containing filter parameters, for example { type: "apartment" }
will return just the accommodations that match that criteria.filter
is an Object containing filter parameters, for example { type: "apartment" }
will return just the accommodations that match that criteria.We offer a new way to transparently "Get accommodations" with or without availabilities with a generic response format. See getItems() below.
finish
a callback which is called when the Query is fully executedfinishProvider
a finish callback for every single booking providerfilter
a filter object, see belowtracktag
a short string used to distinguish different queries from another. Max length 30 characters, no whitespace. Tracktags beginning with underscore are reserved for internal use.cb
, the availabilities that you receive and the library stores it in a DataManager which are easily querable for you afterwards. Basicaly when a result comes you can add it to your page via jQuery or you can just load the data again from the DataManager included in the library, so you can filter and sort the data directly.filter
parameter with an object with the following fields:type
: can be a type or all
. Currently the following types are supported: hotel
, appartment
, offer
reference_id
: pass an accommodationId here to get results only for a single accommodationorigin
is the hash of the queryaccommodationId
is the accommodationId which you want to get the availabilities forcb
is the callback that returns the availabilities. Provide a Function with the following signature:getItems()
returns an instance of the Items
objects, which allows you to easily paginate and sort.parameters
can contain the following keys:options
can contain the follow keys:sortString
can be one of the following values.ascending
. For descending
sort order add prefix -
cb
or leave it undefined to get a promise
as return value. Returns a calendar with Arrival days, available days and minimum stays in this format:arrival
and free
are integers in the format yymmdd
arrival
there is a matching minstay
element, denoting the number of minimum stay days for a particular arrival day