Delete a knowledge source
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.
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
Must be true to perform this action. It deletes something, publishes, or changes what live callers get straight away, so confirm with the user first.
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 DELETE "https://example.com/workspaces/string/agents/string/knowledge-base/string"{
"property1": null,
"property2": null
}{
"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
}Add a web page or site POST
Add a URL knowledge-base source. The page is read, cleaned to its main text, chunked, and embedded, the same shape as `add_text_kb_source` but the content is pulled at ingest time. Pass `wholeSite: true` to read up to 100 pages of the same site as one source instead. Re-fetch is manual unless a schedule is set with `edit_kb_source_schedule`. Paywalled pages, or a site with no readable pages, fail with an error the operator can act on. Use for public content the operator wants to keep current (pricing page, FAQ page, policy page, or a whole small-business site).
List knowledge sources GET
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.