Skip to content

Commit 151804a

Browse files
committed
Add section to readme
1 parent 8a35848 commit 151804a

File tree

2 files changed

+23
-3
lines changed

2 files changed

+23
-3
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
1111

1212
- Added `USE_DATETIME` environment variable to configure datetime search behavior in SFEOS. [#452](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/452)
1313
- GET `/collections` collection search sort extension ex. `/collections?sortby=+id`. [#456](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/456)
14-
- GET `/collections` collection search fields extension ex. `/collections?fields=id,title`. [#457](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/457)
14+
- GET `/collections` collection search fields extension ex. `/collections?fields=id,title`. [#465](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/465)
1515

1616
### Changed
1717

README.md

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,10 @@ SFEOS (stac-fastapi-elasticsearch-opensearch) is a high-performance, scalable AP
3636
- **Scale to millions of geospatial assets** with fast search performance through optimized spatial indexing and query capabilities
3737
- **Support OGC-compliant filtering** including spatial operations (intersects, contains, etc.) and temporal queries
3838
- **Perform geospatial aggregations** to analyze data distribution across space and time
39+
- **Enhanced collection search capabilities** with support for sorting and field selection
3940

4041
This implementation builds on the STAC-FastAPI framework, providing a production-ready solution specifically optimized for Elasticsearch and OpenSearch databases. It's ideal for organizations managing large geospatial data catalogs who need efficient discovery and access capabilities through standardized APIs.
4142

42-
43-
4443
## Common Deployment Patterns
4544

4645
stac-fastapi-elasticsearch-opensearch can be deployed in several ways depending on your needs:
@@ -72,6 +71,7 @@ This project is built on the following technologies: STAC, stac-fastapi, FastAPI
7271
- [Common Deployment Patterns](#common-deployment-patterns)
7372
- [Technologies](#technologies)
7473
- [Table of Contents](#table-of-contents)
74+
- [Collection Search Extensions](#collection-search-extensions)
7575
- [Documentation \& Resources](#documentation--resources)
7676
- [Package Structure](#package-structure)
7777
- [Examples](#examples)
@@ -113,6 +113,26 @@ This project is built on the following technologies: STAC, stac-fastapi, FastAPI
113113
- [Gitter Chat](https://app.gitter.im/#/room/#stac-fastapi-elasticsearch_community:gitter.im) - For real-time discussions
114114
- [GitHub Discussions](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/discussions) - For longer-form questions and answers
115115

116+
## Collection Search Extensions
117+
118+
SFEOS implements extended capabilities for the `/collections` endpoint, allowing for more powerful collection discovery:
119+
120+
- **Sorting**: Sort collections by sortable fields using the `sortby` parameter
121+
- Example: `/collections?sortby=+id` (ascending sort by ID)
122+
- Example: `/collections?sortby=-id` (descending sort by ID)
123+
124+
- **Field Selection**: Request only specific fields to be returned using the `fields` parameter
125+
- Example: `/collections?fields=id,title,description`
126+
- This helps reduce payload size when only certain fields are needed
127+
128+
These extensions make it easier to build user interfaces that display and navigate through collections efficiently.
129+
130+
> **Note**: Sorting is only available on fields that are indexed for sorting in Elasticsearch/OpenSearch. With the default mappings, you can sort on:
131+
> - `id` (keyword field)
132+
> - `extent.temporal.interval` (date field)
133+
>
134+
> Text fields like `title` and `description` are not sortable by default as they use text analysis for better search capabilities. Attempting to sort on these fields will result in a `BadRequestError` with a message about fielddata being disabled.
135+
116136
## Package Structure
117137

118138
This project is organized into several packages, each with a specific purpose:

0 commit comments

Comments
 (0)