Skip to main content
POST
/
partitions
/
{partitionKey}
/
v1
/
collections
/
{collectionKey}
/
query
Search resources of a specific collection in the data partition
curl --request POST \
  --url https://{workspaceId}.clinia.cloud/partitions/{partitionKey}/v1/collections/{collectionKey}/query \
  --header 'Content-Type: application/json' \
  --header 'X-Clinia-API-Key: <api-key>' \
  --data '{
  "semanticQuery": {
    "value": "<string>",
    "paths": {
      "include": [
        "<string>"
      ],
      "exclude": [
        "<string>"
      ]
    }
  },
  "query": {
    "id": "<string>",
    "and": [
      "<any>"
    ]
  },
  "filter": {
    "id": "<string>",
    "and": [
      "<any>"
    ]
  },
  "properties": {
    "include": [
      "<string>"
    ],
    "exclude": [
      "<string>"
    ]
  },
  "highlighting": [
    "<string>"
  ],
  "page": 123,
  "perPage": 20,
  "sort": {
    "direction": "DESC",
    "path": "<string>"
  },
  "ranking": {
    "type": "DEFAULT"
  },
  "aggregations": [
    {
      "type": "LEXICAL",
      "path": "<string>",
      "prefix": "<string>",
      "size": 20
    }
  ],
  "traversedProperties": [
    "<string>"
  ]
}'
{
  "semanticQueryInfo": {
    "reasoning": "<string>",
    "originalQuery": "<string>",
    "query": {
      "id": "<string>",
      "and": [
        "<any>"
      ]
    },
    "filter": {
      "id": "<string>",
      "and": [
        "<any>"
      ]
    }
  },
  "hits": [
    {
      "hitType": "RESOURCE",
      "score": 123,
      "resource": {},
      "traversedProperties": {},
      "highlighting": {}
    }
  ],
  "meta": {
    "numPages": 123,
    "page": 123,
    "perPage": 123,
    "total": 123,
    "filter": {
      "id": "<string>",
      "and": [
        "<any>"
      ]
    }
  },
  "aggregates": [
    {
      "type": "LEXICAL",
      "path": "<string>",
      "aggregate": [
        {
          "value": "<string>",
          "count": 123
        }
      ]
    }
  ]
}

Authorizations

X-Clinia-API-Key
string
header
required

Path Parameters

partitionKey
string
required
collectionKey
string
required

Body

application/json
semanticQuery
object
query
object
  • Option 1
  • Option 2
  • Option 3
  • Option 4
  • Option 5
  • Option 6
  • Option 7
  • Option 8
  • Option 9
  • Option 10
  • Option 11
  • Option 12
filter
object
  • Option 1
  • Option 2
  • Option 3
  • Option 4
  • Option 5
  • Option 6
  • Option 7
  • Option 8
  • Option 9
  • Option 10
  • Option 11
  • Option 12
properties
object
highlighting
string[]
page
integer
perPage
integer
default:20
sort
object
ranking
object
  • Option 1
  • Option 2
aggregations
object[]
traversedProperties
string[]

Response

hits
object[]
required
meta
object
required
aggregates
object[]
required
semanticQueryInfo
object