Skip to main content
Version: 1.16

Legacy search API

Introduction

This section describes how to search products from REGARDS meta catalog with specific lucene API.

REST API

How to

The Regards REST API concept describes how REST interfaces must be handled to submit requests.

Endpoints

descriptionurlverb
Search entities/api/v1/rs-catalog/engines/legacy/entities/searchGET
Get a single entity from its Unique Resource Name/api/v1/rs-catalog/engines/legacy/entities/{urn}GET
Search collections/api/v1/rs-catalog/engines/legacy/collections/searchGET
Get a single collection from its Unique Resource Name/api/v1/rs-catalog/engines/legacy/collections/{urn}GET
Search documents/api/v1/rs-catalog/engines/legacy/documents/searchGET
Get a single document from its Unique Resource Name/api/v1/rs-catalog/engines/legacy/documents/{urn}GET
Search datasets/api/v1/rs-catalog/engines/legacy/datasets/searchGET
Get a single dataset from its Unique Resource Name/api/v1/rs-catalog/engines/legacy/datasets/{urn}GET
Search data objects/api/v1/rs-catalog/engines/legacy/dataobjects/searchGET
Get a single data object from its Unique Resource Name/api/v1/rs-catalog/engines/legacy/dataobjects/{urn}GET
Search data objects returning datasets/api/v1/rs-catalog/engines/legacy/dataobjects/datasets/searchGET
Search data objects in the specified dataset/api/v1/rs-catalog/engines/legacy/datasets/{urn}/dataobjects/searchGET

Query parameters

valuedescription
qThe search query in lucene query format for example altitude:[1000 TO 2000] OR name:sensor-*
facetsThe array of attribute names
pagePage you want to retrieve, 0 indexed and default to 0
sizeSize of the page you want to retrieve, defaults to 20
sortProperties that should be sorted by in the format property,property(,ASC/DESC).
Default sort direction is ascending. Use multiple sort parameters if you want to switch directions, e.g. ?sort=firstname&sort=lastname,asc.

Using CURL to run search requests

To be able to run search request with cURL tool, you have to encode url parameters. To do so, you can use the here under cURL syntaxe to run GET request with encoded parameters :

curl -G 'http://<host>/api/v1//rs-catalog/engines/legacy/dataobjects/search' \
--data-urlencode "q=(param1:test OR param2:test)" \
-H 'Authorization: Bearer <token>' -H 'Accept: application/json'

Query parameter

The query parameter is a String containing search criteria on attributs models formated with lucene format. To know the list of queryable attributs refer to the associated Data Model in rs-dam microservice.