From 904379f12f7652581df208031ae02679c491d572 Mon Sep 17 00:00:00 2001 From: Matthias Mohr Date: Tue, 30 Nov 2021 18:00:28 +0100 Subject: [PATCH 1/3] Explicitly specify metadata filters for collections #396 --- CHANGELOG.md | 1 + openapi.yaml | 13 +++++++++++++ 2 files changed, 14 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index c3c1aa51..983075bb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - `create-form` to link to the registration page - `recovery-form` to link to the credentials recovery page. - `GET /me`: New Relation types `alternate` and `related` for user-specific external pages. [#404](https://github.com/Open-EO/openeo-api/issues/404) +- `GET /collections` and `GET /collections/{collection_id}` (and implicitly `GET /jobs/{job_id}/results`): Added a field that can indicate which properties can be filtered on when loading data from a collection. [#396](https://github.com/Open-EO/openeo-api/issues/396) - `GET /credentials/oidc`: Allow `authorization_code` and `urn:ietf:params:oauth:grant-type:device_code` (both without PKCE) as grants for `default_clients`. [#410](https://github.com/Open-EO/openeo-api/issues/410) - Recommendation to add media types and titles to links for a better user experience. - Allow the relation type `canonical` to be used generally for (shared) resources (e.g. UDPs or batch jobs) without requiring Bearer authentication. [#405](https://github.com/Open-EO/openeo-api/issues/405) diff --git a/openapi.yaml b/openapi.yaml index daa33337..d84e716d 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -1445,6 +1445,10 @@ paths: - B10 - B11 - B12 + 'openeo:property_filters': + - platform + - eo:cloud_cover + - sat:orbit_state summaries: 'constellation': - Sentinel-2 @@ -4346,6 +4350,15 @@ components: x-additionalPropertiesName: Dimension Name allOf: - $ref: '#/components/schemas/dimension' + 'openeo:property_filters': + description: |- + Gives a list of properties you can filter on when loading data from the collection. + More metadata about the properties can be found in `summaries`. + + Returning an empty array means that no filters are available. + type: array + items: + type: string summaries: title: STAC Summaries (Collection Properties) description: |- From 62da90dccd16d9366da70c39674825793d68f443 Mon Sep 17 00:00:00 2001 From: Matthias Mohr Date: Wed, 1 Dec 2021 13:46:19 +0100 Subject: [PATCH 2/3] Clarify description --- openapi.yaml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/openapi.yaml b/openapi.yaml index d84e716d..66062b7b 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -4353,9 +4353,15 @@ components: 'openeo:property_filters': description: |- Gives a list of properties you can filter on when loading data from the collection. + Returning an empty array means that no filters are available. + + This is a guide for users to get an overview over available filters. More metadata about the properties can be found in `summaries`. - Returning an empty array means that no filters are available. + If this property is not present, it means that the collections does + not provide any collection-specific details about available filters. + It's then up to other means of documentation to inform the user, + e.g. there could be documentation about filters that work across collections. type: array items: type: string From 3a8f6c933feb598f4edfbbb0ad1673a5f35f741f Mon Sep 17 00:00:00 2001 From: Matthias Mohr Date: Wed, 8 Dec 2021 16:43:51 +0100 Subject: [PATCH 3/3] Apply suggestions from code review --- openapi.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/openapi.yaml b/openapi.yaml index 66062b7b..c783bf52 100644 --- a/openapi.yaml +++ b/openapi.yaml @@ -4353,15 +4353,15 @@ components: 'openeo:property_filters': description: |- Gives a list of properties you can filter on when loading data from the collection. - Returning an empty array means that no filters are available. + Returning an empty array means that no property-based filters are available. - This is a guide for users to get an overview over available filters. + This is a guide for users to get an overview of available properties to filter on. More metadata about the properties can be found in `summaries`. If this property is not present, it means that the collections does - not provide any collection-specific details about available filters. + not provide any collection-specific details about available property-based filters. It's then up to other means of documentation to inform the user, - e.g. there could be documentation about filters that work across collections. + e.g. there could be documentation about property filters that work across collections. type: array items: type: string