POST /api/sources/{source_id}/search
Run the real retrieval pipeline against one source and return the ranked chunks it produces, optionally under an ad-hoc retrieval config. Read-only: nothing is saved.
Personal access token scope: chat:run.
bearerAuthorizationBearer <token>A session token or a personal access token. Leave it empty when the instance runs without authentication (AUTH_TYPE unset).
source_id*stringapplication/json- body
compare?booleanAlso return candidates: every chunk the stages received, in retriever order, with its relevance and whether it was kept.
query*stringThe query to retrieve for
retrieval?Ad-hoc retrieval config to test with. Omit to use the source's saved config. Never persisted.
Success
curl -X POST 'http://localhost:7091/api/sources/string/search' \ -H 'Content-Type: application/json' \ -d '{ "query": "string"}'POST /api/sources/from_attachments POST
Creates a Knowledge source from chat attachments the caller already uploaded. The stored originals are copied into a new source and ingested like an upload (a zip contributes its files); the files together may not exceed the upload request limit (413). Returns the source id and the ingest task id; progress arrives as `source.ingest.*` events for that source id. Honors an optional `Idempotency-Key` header: a repeat request with the same key within 24h returns the first request's source and task ids without copying the files or queueing a second ingest. [Personal access token](/API/personal-access-tokens) scope: `sources:write`.
Trigger an immediate sync for a source POST
Trigger an immediate sync for a source. [Personal access token](/API/personal-access-tokens) scope: `sources:write`.