Skip to content

Commit f34fabc

Browse files
committed
update
1 parent bf1ce3b commit f34fabc

File tree

1 file changed

+4
-0
lines changed
  • stac_fastapi/core/stac_fastapi/core

1 file changed

+4
-0
lines changed

stac_fastapi/core/stac_fastapi/core/core.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,6 +227,7 @@ async def landing_page(self, **kwargs) -> stac_types.LandingPage:
227227
async def all_collections(
228228
self,
229229
datetime: Optional[str] = None,
230+
limit: Optional[int] = None,
230231
fields: Optional[List[str]] = None,
231232
sortby: Optional[str] = None,
232233
filter_expr: Optional[str] = None,
@@ -239,6 +240,7 @@ async def all_collections(
239240
240241
Args:
241242
datetime (Optional[str]): Filter collections by datetime range.
243+
limit (Optional[int]): Maximum number of collections to return.
242244
fields (Optional[List[str]]): Fields to include or exclude from the results.
243245
sortby (Optional[str]): Sorting options for the results.
244246
filter_expr (Optional[str]): Structured filter expression in CQL2 JSON or CQL2-text format.
@@ -252,7 +254,9 @@ async def all_collections(
252254
"""
253255
request = kwargs["request"]
254256
base_url = str(request.base_url)
257+
255258
limit = int(request.query_params.get("limit", os.getenv("STAC_ITEM_LIMIT", 10)))
259+
256260
token = request.query_params.get("token")
257261

258262
# Process fields parameter for filtering collection properties

0 commit comments

Comments
 (0)