Skip to main content
POST
Test a knowledge-base document query

Authorizations

Authorization
string
header
required

Dashboard JWT token from Clerk

Path Parameters

agentId
string
required
docId
string
required

Body

application/json
query
string
required

The natural-language query to run against the document.

Required string length: 1 - 2000
limit
integer
default:5

Top-K chunks to return.

Required range: 1 <= x <= 20
threshold
number
default:0

Minimum similarity score for a chunk to be included.

Required range: 0 <= x <= 1
synthesize
boolean
default:true

Whether to also synthesize an answer from the retrieved chunks.

Response

200 - application/json

The top matching chunks and the synthesized answer.

data
object
meta
object