Skip to content

Commit

Permalink
Merge pull request #1092 from radiantearth/preview-rel-type
Browse files Browse the repository at this point in the history
Add preview relation type #1090
  • Loading branch information
cholmes authored Apr 23, 2021
2 parents b8d8b5e + 59ad837 commit d42e3c1
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.

## [Unreleased]

### Added

- Added `preview` relation type for interoperable thumbnails to best practices. ([#1090](https://github.com/radiantearth/stac-spec/issues/1090))

### Changed

- The first extent in a Collection is always the overall extent, followed by more specific extents. ([#1064](https://github.com/radiantearth/stac-spec/issues/1064), [opengeospatial/ogcapi-features#520](https://github.com/opengeospatial/ogcapi-features/pull/520))
Expand Down
8 changes: 5 additions & 3 deletions best-practices.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
- [Keep catalogs in sync with cloud notification and queue services](#keep-catalogs-in-sync-with-cloud-notification-and-queue-services)
- [How to Differentiate STAC Files](#how-to-differentiate-stac-files)


This document makes a number of recommendations for creating real world SpatioTemporal Asset Catalogs. None of them
are required to meet the core specification, but following these practices will make life easier for client tooling
and for users. They come about from practical experience of implementors and introduce a bit more 'constraint' for
Expand Down Expand Up @@ -293,7 +294,7 @@ following table lists some of the most common ones you may encounter or use.
| `image/png` | Visual PNGs (e.g. thumbnails) |
| `image/jpeg` | Visual JPEGs (e.g. thumbnails, oblique) |
| `text/xml` or `application/xml` | XML metadata [RFC 7303](https://www.ietf.org/rfc/rfc7303.txt) |
| `application/json` | A JSON file (often metadata, or [labels](https://github.com/radiantearth/stac-spec/tree/master/extensions/label#labels-required)) |
| `application/json` | A JSON file (often metadata, or [labels](https://github.com/radiantearth/stac-spec/tree/master/extensions/label#labels-required)) |
| `text/plain` | Plain text (often metadata) |
| `application/geo+json` | [GeoJSON](https://geojson.org/) |
| `application/geopackage+sqlite3` | [GeoPackage](https://www.geopackage.org/) |
Expand Down Expand Up @@ -631,13 +632,14 @@ with the `type` field) to communicate the structure and content of related entit
Types](https://www.iana.org/assignments/link-relations/link-relations.xhtml) as much as possible. The following table describes
a number of the common official relations that are used in production STAC implementations.

| Type | Description |
| ------------ | ------------------------------------------------------------ |
| Type | Description |
| --------- | ------------------------------------------------------------ |
| alternate | It is recommended that STAC Items are also available as HTML, and should use this rel with `"type" : "text/html"` to tell clients where they can get a version of the Item or Collection to view in a browser. See [STAC on the Web in Best Practices](#stac-on-the-web) for more information. |
| canonical | The URL of the [canonical](https://en.wikipedia.org/wiki/Canonical_link_element) version of the Item or Collection. API responses and copies of catalogs should use this to inform users that they are direct copy of another STAC Item, using the canonical rel to refer back to the primary location. |
| via | The URL of the source metadata that this STAC Item or Collection is created from. Used similarly to canonical, but refers back to a non-STAC record (Landsat MTL, Sentinel tileInfo.json, etc) |
| prev | Indicates that the link's context is a part of a series, and that the previous in the series is the link target. Typically used in STAC by API's, to return smaller groups of Items or Catalogs/Collections. |
| next | Indicates that the link's context is a part of a series, and that the next in the series is the link target. Typically used in STAC by API's, to return smaller groups of Items or Catalogs/Collections. |
| preview | Refers to a resource that serves as a preview (see [RFC 6903, sec. 3](https://tools.ietf.org/html/rfc6903#section-3)), usually a lower resolution thumbnail. In STAC this would usually be the same URL as the [thumbnail](#thumbnail) asset, but adding it as a link in addition enables OGC API clients that can't read assets to make use of it. It also adds support for thumbnails to STAC Catalogs as they can't list assets. |

### Versioning for Catalogs

Expand Down

0 comments on commit d42e3c1

Please sign in to comment.