@@ -71,22 +71,29 @@ name, e.g., `properties.datetime` or `datetime`.
71
71
72
72
## Include/Exclude Semantics
73
73
74
- 1 . If ` fields ` attribute is specified with an empty object, or with both ` include ` and ` exclude ` set to null or an
75
- empty array, the recommended behavior is as if ` include ` was set to
76
- ` ["id", "type", "geometry", "bbox", "links", "assets", "properties.datetime"] ` . This default is so that the entity
77
- returned is a valid STAC Item. Implementations may choose to add other properties, e.g., ` created ` , but the number
74
+ 1 . If ` fields ` attribute is specified as an empty object, or with both ` include ` and ` exclude ` set to null or an
75
+ empty array, then the recommended behavior is to ` include ` the following keys:
76
+ ` ["id", "type", "geometry", "bbox", "links", "assets", "properties.datetime", "stac_version"] ` .
77
+ This default is so that the entity returned is a valid STAC Item.
78
+ Implementations may choose to add other properties, e.g., ` created ` , but the number
78
79
of default properties attributes should be kept to a minimum.
79
- 2 . If only ` include ` is specified, these attributes are added to the default set of attributes (set union operation).
80
- 3 . If only ` exclude ` is specified, these attributes are subtracted from the union of the default set of attributes and
81
- the ` include ` attributes (set difference operation). This will result in an entity that is not a valid Item if any
82
- of the excluded attributes are in the default set of attributes.
83
- 4 . If both ` include ` and ` exclude ` attributes are specified, semantics are that a field must be included and ** not**
84
- excluded. E.g., if ` properties ` is included and ` properties.datetime ` is excluded, then ` datetime ` must not appear
85
- in the attributes of ` properties ` .
80
+ 2 . If only ` include ` is specified, these attributes should be the only attributes included.
81
+ 3 . If only ` exclude ` is specified, these attributes are subtracted from the full item.
82
+ This may result in an entity that is not a valid STAC Item.
83
+ 4 . If ` exclude ` is specified and ` include ` is null or an empty
84
+ array, then the ` exclude ` attributes are subtracted from the default set.
85
+ This may result in an entity that is not a valid STAC Item.
86
+ 5 . If a key is in ` exclude ` , and a sub-key is in ` include ` , the sub-key should be included, but no other fields
87
+ in the key should be included. E.g., if ` properties ` is excluded and ` properties.datetime ` is included, then ` datetime `
88
+ should be the only attribute in ` properties ` .
89
+ 6 . If a key is in ` include ` , and a sub-key is in ` exclude ` , the key should be included, and the sub-key should be excluded.
90
+ E.g., if ` properties ` is included and ` properties.datetime ` is excluded, then ` datetime `
91
+ should not be in ` properties ` .
92
+ 7 . If the same attribute is present in both ` include ` and ` exclude ` , it should be included.
86
93
87
94
## Examples
88
95
89
- Return baseline fields. This ** must ** return valid STAC Item entities.
96
+ Return the default fields. This should return valid STAC Item entities.
90
97
91
98
Query Parameters
92
99
``` http
@@ -101,11 +108,11 @@ JSON
101
108
}
102
109
```
103
110
104
- This has a similar effect as an empty object for ` fields ` , but it is up to the discretion of the implementation
111
+ This has a similar effect as an empty object for ` fields ` , but it is up to the discretion of the implementation.
105
112
106
113
Query Parameters
107
114
``` http
108
- ?fields=id,type,geometry,bbox,properties,links,assets
115
+ ?fields=id,type,geometry,bbox,properties.datetime ,links,assets,stac_version
109
116
```
110
117
111
118
JSON
@@ -117,15 +124,16 @@ JSON
117
124
" type" ,
118
125
" geometry" ,
119
126
" bbox" ,
120
- " properties" ,
127
+ " properties.datetime " ,
121
128
" links" ,
122
- " assets"
129
+ " assets" ,
130
+ " stac_version" ,
123
131
]
124
132
}
125
133
}
126
134
```
127
135
128
- Exclude ` geometry ` from the baseline fields . This ** must** return an entity that is not a valid GeoJSON Feature or a valid STAC Item.
136
+ Exclude ` geometry ` from the full item . This ** must** return an entity that is not a valid GeoJSON Feature or a valid STAC Item.
129
137
130
138
Query Parameters
131
139
``` http
@@ -143,10 +151,8 @@ JSON
143
151
}
144
152
```
145
153
146
- To return the ` id ` , ` type ` , ` geometry ` , and the Properties attribute ` eo:cloud_cover ` .
147
- This ** must** return a valid STAC Item, as the includes are added to the default includes.
148
- Explicitly specifying ` id ` , ` type ` , and ` geometry ` has not effect as these are default fields,
149
- but ` properties.eo:cloud_cover ` is not a default field and thereby should be in the response.
154
+ Return the ` id ` , ` type ` , ` geometry ` , and the Properties attribute ` eo:cloud_cover ` .
155
+ This might not return a valid STAC Item, since not all required Item attributes are included.
150
156
151
157
Query Parameters
152
158
``` http
0 commit comments