Skip to main content

Search

To publish Earth Observations Applications in the GEO Knowledge Hub, Knowledge Providers use Knowledge Packages and Knowledge Resources. Each of these entities has specialized APIs. This prevents the realization of searches that have both entities in the results.

To solve this problem, the Search API is available in the GEO Knowledge Hub. Using this API, it is possible to query Packages and Resources simultaneously. This is useful for pages like the Search page and the Knowledge Provider dashboard.

This documentation page shows how Search API can be used.

Search Packages and resources

GET /api/search

Parameters

NameTypeLocationDescription
qstringquerySearch query used to filter results based on ElasticSearch's query string syntax.
bboxstringqueryBounding box search query (You need to define two points, Top Left and Bottom Right, with the format 'longitude,latitude,longitude,latitude').
sortstringquerySort search results.
sizeintegerquerySpecify number of items in the results page (default: 10).
pageintegerquerySpecify the page of results.
allversions  booleanquerySpecify if all versions should be included.
acceptstringheader- application/json (default)
- application/vnd.inveniordm.v1+json

Request

GET /api/search HTTP/1.1

Response

HTTP/1.1 200 OK
Content-Type: application/json

{
"aggregations": {...},
"hits": {...},
"links": {...},
"sortBy": ...,
}