Clinia
RegistrySearch

Run multiple queries

POST
/sources/{sourceKey}/v1/queries

Execute several queries within a single request. It is possible to send multiple query items, where each of the item can be either a regular query or a federated query. To trigger a federated query, one must specify more then one collection key in the item.

headerX-Clinia-API-Key<token>
sourceKey*string

The source from which to execute the query.

application/json
  1. body

The list of queries to execute. It is possible to send multiple query items, where each of the item can be either a regular query or a federated query.

requests*array<>

The list of queries to execute.

Response Body

A successful response.

application/json
  1. response

The list of responses for the multi query. The responses are returned in the same order as the requests.

responses*array<>

The responses for each corresponding requests.

Example Request
curl -X POST 'https://api..clinia.cloud/sources/string/v1/queries' \  -H 'Content-Type: application/json' \  -d '{  "requests": [    {      "collectionKeys": [        "string"      ],      "params": {}    }  ]}'
Example Response
{  "responses": [    {      "collectionKeys": [        "string"      ],      "response": {        "semanticQueryInfo": {          "reasoning": "string",          "originalQuery": "string",          "query": {            "id": "string",            "and": [              null            ]          },          "filter": {            "id": "string",            "and": [              null            ]          }        },        "hits": [          {            "hitType": "RESOURCE",            "score": 0.1,            "resource": {},            "traversedProperties": {              "property1": [                {                  "type": "address",                  "value": {},                  "relationshipId": "string",                  "relationshipType": "string",                  "recordId": "string",                  "recordType": "string"                }              ],              "property2": [                {                  "type": "address",                  "value": {},                  "relationshipId": "string",                  "relationshipType": "string",                  "recordId": "string",                  "recordType": "string"                }              ]            },            "highlighting": {              "property1": [                {                  "type": "textual",                  "highlight": "string"                }              ],              "property2": [                {                  "type": "textual",                  "highlight": "string"                }              ]            }          }        ],        "meta": {          "numPages": 0,          "page": 0,          "perPage": 0,          "total": 0,          "filter": {            "id": "string",            "and": [              null            ]          }        },        "aggregates": [          {            "type": "LEXICAL",            "path": "string",            "aggregate": [              {                "value": "string",                "count": 0              }            ]          }        ]      }    }  ]}