Skip to content

Commit 1c2d079

Browse files
authored
Merge pull request #883 from radiantearth/unique-ids
Unique ids
2 parents 70121de + 9fe980e commit 1c2d079

File tree

3 files changed

+20
-1
lines changed

3 files changed

+20
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
3030
- `proj:geometry` allows all GeoJSON geometries instead of just a polygon.
3131
- `label:description` and `processing:lineage` allow CommonMark for rich-text representation ([#950](https://github.com/radiantearth/stac-spec/issues/950))
3232
- Renamed "Scientific Extension" to "Scientific Citation Extension" ([#990](https://github.com/radiantearth/stac-spec/issues/990))
33+
- Enhanced the way the spec talks about ID's to encourage more global uniqueness.
3334

3435
### Removed
3536

collection-spec/collection-spec.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ STAC Collections are meant to be compatible with *OGC API - Features* Collection
3434

3535
### Additional Field Information
3636

37+
#### id
38+
39+
It is important that collection identifiers are unique across the provider. And providers should strive as much as possible to make
40+
their collection ids 'globally' unique, prefixing any common information with a unique string. This could be the provider's name if
41+
it is a fairly unique name, or their name combined with the domain they operate in.
42+
3743
#### stac_extensions
3844

3945
A list of extensions the Collection implements. This does NOT declare the extensions of child Catalogs or Items. The list contains URLs to the JSON Schema files it can be validated against. For official [extensions](../extensions/README.md#list-of-stac-extensions), a "shortcut" can be used. This means you can specify the folder name of the extension, for example `version` for the Versioning Indicators extension. If the versions of the extension and the collection diverge, you can specify the URL of the JSON schema file.

item-spec/item-spec.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ inherited from GeoJSON.
3131
| ---------- | -------------------------------------------------------------------------- | ----------- |
3232
| stac_version | string | **REQUIRED.** The STAC version the Item implements. |
3333
| stac_extensions | \[string] | A list of extensions the Item implements. |
34-
| id | string | **REQUIRED.** Provider identifier. As most geospatial assets are already defined by some identification scheme by the data provider it is recommended to simply use that ID. Data providers are advised to include sufficient information to make their IDs globally unique, including things like unique satellite IDs. |
34+
| id | string | **REQUIRED.** Provider identifier. The ID should be unique within the [Collection](../collection-spec/README.md) that contains the item. |
3535
| type | string | **REQUIRED.** Type of the GeoJSON Object. MUST be set to `Feature`. |
3636
| geometry | [GeoJSON Geometry Object](https://tools.ietf.org/html/rfc7946#section-3.1) \| [null](https://tools.ietf.org/html/rfc7946#section-3.2) | **REQUIRED.** Defines the full footprint of the asset represented by this item, formatted according to [RFC 7946, section 3.1](https://tools.ietf.org/html/rfc7946#section-3.1). The footprint should be the default GeoJSON geometry, though additional geometries can be included. Coordinates are specified in Longitude/Latitude or Longitude/Latitude/Elevation based on [WGS 84](http://www.opengis.net/def/crs/OGC/1.3/CRS84). |
3737
| bbox | \[number] | **REQUIRED if `geometry` is not `null`.** Bounding Box of the asset represented by this item, formatted according to [RFC 7946, section 5](https://tools.ietf.org/html/rfc7946#section-5). |
@@ -46,6 +46,18 @@ inherited from GeoJSON.
4646

4747
In general, STAC versions can be mixed, but please keep the [recommended best practices](../best-practices.md#mixing-stac-versions) in mind.
4848

49+
#### id
50+
51+
It is important that an Item identifier is unique within a collection, and that the
52+
[Collection identifier](../collection-spec/collection-spec.md#id) in turn is unique globally. Then the two can be combined to
53+
give a globally unique identifier. Items are *[strongly recommended](#collections)* to have collections, and not having one makes
54+
it more difficult to be used in the wider STAC ecosystem. If an Item does not have a Collection, then the Item identifier should be unique within its root Catalog.
55+
56+
As most geospatial assets are already uniquely defined by some
57+
identification scheme from the data provider it is recommended to simply use that ID. Data providers are advised to include sufficient information to make their
58+
IDs globally unique, including things like unique satellite IDs. See the [id section of best practices](../best-practices.md#field-and-id-formatting) for
59+
additional recommendations.
60+
4961
#### stac_extensions
5062

5163
A list of extensions the Item implements. The list contains URLs to the JSON Schema files it can be validated against. For official [extensions](../extensions/README.md#list-of-stac-extensions), a "shortcut" can be used. This means you can specify the folder name of the extension, for example `pointcloud` for the Point Cloud extension. This does *not* apply for API extensions. If the versions of the extension and the item diverge, you can specify the URL of the JSON schema file.

0 commit comments

Comments
 (0)