Skip to main content
POST
Query a Knowledge Base

Endpoint

Path Parameters

string
required
The unique identifier of the knowledge base to query.

Request Headers

string
required
Bearer token with your API key: Bearer YOUR_API_KEY
string
required
Must be application/json

Request Body

string
required
The question or search query to send to the knowledge base.

Example Request

Response

string
The generated answer to your query based on the knowledge base content.
array
List of source documents that support the answer.
integer
Number of tokens consumed by this query.

Example Response

Error Responses

Next Steps

Rate Limits

Understand usage caps

Error Handling

Handle errors gracefully