List knowledge sources
List the knowledge-base sources currently attached to this agent. Returns each source's name, kind (text/url/upload/site), status (pending/extracting/embedding/ready/failed), chunk count, and what the ingest quality gate dropped on the latest read: `rejectedChunkCount` and `rejectedReasons` ([{reason, count, sections}]). A `ready` source can still have dropped chunks; a `live price list` reason means the agent cannot quote those prices from the KB and needs a price tool. Use before `add_text_kb_source` or `add_url_kb_source` to avoid duplicating coverage.
Authorization
bearerAuth A personal access token from Settings > API tokens.
In: header
Path Parameters
Workspace slug (GET /me lists yours).
Agent slug within the workspace.
Query Parameters
Items per page, 1 to 200. Default 50.
1 <= value <= 200The next_cursor of the previous page.
Response Body
application/json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
application/problem+json
curl -X GET "https://example.com/workspaces/string/agents/string/knowledge-base"{
"data": [
{
"id": "string",
"kind": "string",
"status": "string",
"property1": null,
"property2": null
}
],
"has_more": true,
"next_cursor": "string"
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}{
"type": "http://example.com",
"title": "string",
"status": 0,
"detail": "string",
"code": "string",
"errors": [
{
"path": "string",
"message": "string"
}
],
"estimate": {},
"retryAfterSeconds": 0
}Delete a knowledge source DELETE
Delete a knowledge-base source by id. Cascades to its chunks via the FK. Use when content is wrong or no longer wanted; for content that just needs re-reading, call `refresh_kb_source` instead, which keeps the source's id and sync schedule.
Fetch a source again POST
Re-read one knowledge-base source now, keeping its id and its sync schedule. Use after the page or site behind a URL source changed, or to retry a source that failed. The page is fetched fresh, never from a cache. Unchanged pages keep their passages; changed pages are re-embedded (a metered charge). A failed refresh keeps the previous passages and reports the error. Returns the source's status, chunk count and what the quality gate dropped (`rejectedChunkCount`, `rejectedReasons`). A workspace-shared source cannot be refreshed from an agent.