List Content

Select a knowledge base

Register a Knowledge with contents_db on AgentOS, an Agent or a Team. Read the actual generated ID from GET /config under knowledge.knowledge_instances; use that knowledge_id in the request's selector. It is not an arbitrary Knowledge.id. A selector is required when multiple instances make the request ambiguous (400); no configured knowledge base returns 503. If both selectors are supplied, knowledge_id takes precedence over db_id.

Ingestion and search also require suitable readers, vector storage, an embedder where needed, and their dependencies and credentials. See Knowledge.

Content access

Scoped callers can read their own and shared content; other-owned records return 404. JWT user scoping requires user isolation, while non-admin service-account PAT users always self-scope. A scoped caller cannot modify, refresh or delete shared content (403). Authentication alone does not enable JWT user isolation.

Supported filtering

The current handler accepts selection, pagination, sorting and parent_id. It does not implement the status, content-type or arbitrary metadata filters mentioned in the generated description. Sending such query parameters does not apply those filters.

parent_id is an exact match against a site's stored parent ID and is applied alongside content access scoping. This filter requires local Knowledge; it returns 501 for RemoteKnowledge.

GET/knowledge/content

Retrieve paginated list of all content in the knowledge base with filtering and sorting options. Filter by status, content type, or metadata properties.

Authorization

HTTPBearer
AuthorizationBearer <token>

In: header

Query Parameters

limit?|

Number of content entries to return

Default20
page?|

Page number

Default1
sort_by?|

Field to sort by

Default"created_at"
sort_order?|

Sort order (asc or desc)

Default"desc"
db_id?|

Database ID to use

knowledge_id?|

Knowledge base ID to use

parent_id?|

Only page rows of this site row (exact id match)

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

curl --request GET 'https://example.com/knowledge/content'
{  "data": [    {      "id": "3c2fc685-d451-4d47-b0c0-b9a544c672b7",      "name": "example.pdf",      "description": "",      "type": "application/pdf",      "size": "251261",      "metadata": {},      "access_count": 1,      "status": "completed",      "status_message": "",      "created_at": "2025-09-08T15:22:53Z",      "updated_at": "2025-09-08T15:22:54Z"    }  ],  "meta": {    "page": 1,    "limit": 20,    "total_pages": 1,    "total_count": 2  }}