Description Usage Arguments Examples
Pull detailed listing data.
After using the searchLocation
, you can add greater detail on each listing
(such as amenities offered) using addDetails
. It takes as an input the dataset of
listings outputted from searchLocation
and merges in details based on the listing
ID. Note that this process is very time consuming, and so it may be unwise to pass too
large of a listing dataset.
listingDetails
is a function that will take in a character vector of
listing IDs and return a dataset. This function does not necessarily need to be used
with searchLocation
.
1 2 3 | addDetails(searchData)
listingDetails(listingIDs, client.id = "d306zoyjsyarp7ifhu67rjxn52tv0t20")
|
searchData |
a dataset of listings outputted from |
listingIDs |
a character vector of listing IDs. These can be found on the URLs
of Airbnb listings or on the output of |
client.id |
best left alone. This is a key that authorizes requests to the Airbnb API. |
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
listingData <- searchLocation("10019")$results$data
addDetails(listingData[1:5,])
## End(Not run)
## Not run:
listingData <- searchLocation("10019")$results$data
listing.details <- listingDetails(listingData$id[1:5])
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.