Stac Search
POST
/services/stac/search
const url = 'https://example.com/api/services/stac/search';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"url":"example","collections":["example"],"bbox":[1],"datetime_range":"example","limit":20}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/services/stac/search \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "url": "example", "collections": [ "example" ], "bbox": [ 1 ], "datetime_range": "example", "limit": 20 }'Search items in a STAC API with spatial/temporal filters.
Authorizations
Section titled “Authorizations ”Request Body required
Section titled “Request Body required ” Media type application/json
StacSearchRequest
object
url
required
Url
STAC API root URL.
string
collections
Any of:
Array<string>
null
bbox
Any of:
Array<number>
null
limit
Limit
Maximum items to return.
integer
Responses
Section titled “ Responses ”Successful Response
Media type application/json
StacSearchResponse
object
items
required
Items
Matching items.
Array<object>
StacItemSummaryobject
id
required
Id
Item identifier.
string
title
required
Title
Item title (falls back to ID).
string
bbox
Any of:
Array<number>
null
asset_count
required
Asset Count
Number of assets on this item.
integer
returned
required
Returned
Number of items in this response.
integer
Example generated
{ "items": [ { "id": "example", "collection": "example", "title": "example", "bbox": [ 1 ], "datetime": "example", "datetime_start": "example", "datetime_end": "example", "epsg": 1, "gsd": 1, "cloud_cover": 1, "data_asset_href": "example", "data_asset_type": "example", "thumbnail_href": "example", "asset_count": 1 } ], "matched": 1, "returned": 1}Validation Error
Media type application/json
HTTPValidationError
object
detail
Detail
Array<object>
ValidationErrorobject
loc
required
Location
Array
msg
required
Message
string
type
required
Error Type
string
input
Input
ctx
Context
object
Example generated
{ "detail": [ { "loc": [ "example" ], "msg": "example", "type": "example", "input": "example", "ctx": {} } ]}