Skip to contents

Many EDR servers expose an OGC API Features /items endpoint alongside the EDR queries. Behaviour varies: some deployments implement items as a full Features endpoint, others as a thin stub used only to register the collection as both EDR and Features. In the stub case, non-trivial data is usually obtained via the EDR queries (edr_locations(), edr_area(), edr_cube(), etc.).

Usage

edr_items(
  client,
  collection_id,
  bbox = NULL,
  datetime = NULL,
  limit = NULL,
  format = c("geojson", "json"),
  ...,
  instance_id = NULL,
  paginate = FALSE,
  max_pages = 100L,
  max_features = 100000L,
  f = NULL
)

edr_item(
  client,
  collection_id,
  item_id,
  format = c("geojson", "json"),
  ...,
  instance_id = NULL,
  f = NULL
)

Arguments

client

An edr_client.

collection_id

Collection identifier.

bbox

Numeric vector of length 4 or 6 (c(minx, miny, maxx, maxy) or with z).

datetime

ISO-8601 instant or interval, e.g. "2024-01-01/2024-12-31" or "2024-01-01/..".

limit

Requested server page size. Servers may enforce their own maximum or ignore this value; with paginate = TRUE, use max_features as the client-side total feature cap.

format

"geojson" (default) or "json".

...

Additional query parameters passed through verbatim.

instance_id

Optional instance identifier. When supplied, the request is sent beneath /collections/{collection_id}/instances/{instance_id}. This keyword-only argument leaves existing positional calls unchanged.

paginate

If TRUE, follow same-origin rel = "next" links and combine bounded GeoJSON FeatureCollection pages. Defaults to FALSE.

max_pages

Maximum number of pages to fetch when paginate = TRUE. Must be a finite positive integer; defaults to 100.

max_features

Maximum combined feature count when paginate = TRUE. Must be a finite positive integer; defaults to 100,000.

f

Optional server-advertised output-format token sent as the EDR f query parameter. This is separate from format, which selects the client-side parser. For example, a strict coverage endpoint can use edr_position(..., format = "covjson", f = "CoverageJSON").

item_id

Identifier of a single feature.

Value

An sf object when sf is installed and the server returns GeoJSON; otherwise an edr_response wrapping the GeoJSON document.