Skip to Content
Docs

Query a search profile

POST
/query

Authorization

jwt
headerAuthorizationBearer <JWT>

Request Body

application/json
  1. body
profileId*string
Match^[a-z0-9]+(?:-[a-z0-9]+)*$
Length3 <= length <= 64
indexId?string
Length1 <= length
query*string
Length1 <= length
topK?integer
Range1 <= value <= 100

Response Body

application/json
  1. response
profileId*string
Match^[a-z0-9]+(?:-[a-z0-9]+)*$
Length3 <= length <= 64
indexId?string
Length1 <= length
generationId*string
Match^[A-Za-z0-9_-]{1,64}$
items*array<>
Example Request
curl -X POST 'https://ai-search.your-tenant-id.my.contextual.io/api/v1/query' \  -H 'Content-Type: application/json' \  -d '{  "profileId": "string",  "query": "string"}'
Example Response
{  "profileId": "string",  "indexId": "string",  "generationId": "string",  "items": [    {      "recordUri": "string",      "sourceHash": "string",      "documentId": "string",      "chunkId": "string",      "score": 0,      "semanticRank": 1,      "keywordRank": 1,      "rerankScore": 0,      "content": "string",      "projections": {        "property1": "string",        "property2": "string"      }    }  ]}