Struct stac_api::Root

source ·
pub struct Root {
    pub catalog: Catalog,
    pub conforms_to: Vec<String>,
}
Expand description

The root landing page of a STAC API.

In a STAC API, the root endpoint (Landing Page) has the following characteristics:

  • The returned JSON is a STAC Catalog, and provides any number of ‘child’ links to navigate to additional Catalog, Collection, and Item objects.
  • The links attribute is part of a STAC Catalog, and provides a list of relations to API endpoints. Some of these endpoints can exist on any path (e.g., sub-catalogs) and some have a specified path (e.g., /search), so the client must inspect the rel (relationship) to understand what capabilities are offered at each location.
  • The conformsTo section provides the capabilities of this service. This is the field that indicates to clients that this is a STAC API and how to access conformance classes, including this one. The relevant conformance URIs are listed in each part of the API specification. If a conformance URI is listed then the service must implement all of the required capabilities.

Fields§

§catalog: Catalog§conforms_to: Vec<String>

Provides the capabilities of this service.

This is the field that indicates to clients that this is a STAC API and how to access conformance classes, including this one. The relevant conformance URIs are listed in each part of the API specification. If a conformance URI is listed then the service must implement all of the required capabilities.

Note the conformsTo array follows the same structure of the OGC API - Features declaration of conformance classes, except it is part of the landing page instead of in the JSON response from the /conformance endpoint. This is different from how the OGC API advertises conformance, as STAC feels it is important for clients to understand conformance from a single request to the landing page. Implementers who implement the OGC API - Features and/or STAC API - Features conformance classes must also implement the /conformance endpoint.

The scope of the conformance classes declared in the conformsTo field and the /conformance endpoint are limited to the STAC API Catalog that declares them. A STAC API Catalog may link to sub-catalogs within it via child links that declare different conformance classes. This is useful when an entire catalog cannot be searched against to support the STAC API - Item Search conformance class, perhaps because it uses multiple databases to store items, but sub-catalogs whose items are all in one database can support search. #[serde(rename = “conformsTo”)]

Trait Implementations§

Formats the value using the given formatter. Read more
Deserialize this value from the given Serde deserializer. Read more
Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.