View source: R/query_and_sign.R
rsi_query_api | R Documentation |
This function is the default method used to retrieve lists of items to download for all the collections and endpoints supported by rsi. It will likely work for any other STAC APIs of interest.
rsi_query_api(bbox, stac_source, collection, start_date, end_date, limit, ...)
bbox |
A |
stac_source |
Character of length 1: the STAC URL to download imagery from. |
collection |
Character of length 1: the STAC collection to download images from. |
start_date , end_date |
Character strings of length 1 representing the
boundaries of your temporal range of interest, in RFC-3339 format. Set either
argument to |
limit |
an |
... |
Ignored by this function. Arguments passed to |
You can pass your own query functions to get_stac_data()
and its variants.
This is the best way to perform more complex queries, for instance if you
need to provide authentication to get the list of items (not just the assets)
available for your AOI, or to perform cloud filtering prior to downloading
assets.
A StacItemCollection object.
aoi <- sf::st_point(c(-74.912131, 44.080410))
aoi <- sf::st_set_crs(sf::st_sfc(aoi), 4326)
aoi <- sf::st_buffer(sf::st_transform(aoi, 5070), 100)
landsat_image <- get_landsat_imagery(
aoi,
start_date = "2022-06-01",
end_date = "2022-08-30",
query_function = rsi_query_api
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.