Skip to content

List Knowledge Items

GET /knowledge-items

A flat collection filtered by kb_id, not /knowledge-bases/{id}/items.

Annex 05 §1.2 settles it in one line — “deeper nesting becomes a filtered collection instead: /knowledge-items?kb_id=…” — and the reason survives the appeal to authority: three of the four item placements (agent, subject, conversation) have no kb_id at all, so a nested route could not address them. A curator’s real question is “what is pending across everything I own”, which is one page here and a fan-out over every base under the nested form. The routes that are nested in this API — /agents/{id}/revisions, /runs/{id}/steps — are for children that cannot exist without the parent. An item can.

The three axes of annex 10 §1.1 are each filterable, on purpose: item_scope (who can see it), kind (how it is used) and curation_state (is it trusted). Two of three is the surface that reads complete and cannot answer “what did the agent write privately that is still pending”.

NameInTypeNotes
kb_idquerystring (uuid) | nulloptional—
item_scopequerykb | agent | subject | conversation | nulloptional—
kindqueryfact | rule | open_question | hub | nulloptional—
curation_statequerypending | reviewed | promoted | superseded | retired | nulloptional—
originqueryhuman | agent | import | derived | nulloptionalwho authored it
agent_idquerystring (uuid) | nulloptionalagent-placed items
persona_idquerystring (uuid) | nulloptionalitems written by this overlay
session_idquerystring (uuid) | nulloptionalconversation-placed items
subject_kindqueryuser | guest | nulloptional—
subject_idquerystring | nulloptional—
qquerystring | nulloptionalsubstring of content or title
include_structuralquerybooleanoptionalinclude hubs Default false.
created_afterquerystring (date-time) | nulloptional—
created_beforequerystring (date-time) | nulloptional—
viewer_agent_idquerystring (uuid) | nulloptionalread as this agent: unlocks its private bases
limitqueryintegeroptionalDefault 50. min 1 max 200
cursorquerystring | nulloptional—
offsetqueryinteger | nulloptionalmin 0
StatusDescriptionBody
200Successful ResponsePage_KnowledgeItemView_
422Validation ErrorHTTPValidationError
Terminal window
curl -X GET https://your-deployment.example.com/knowledge-items \
-H "Authorization: Bearer $COBRE_TOKEN"
FieldTypeNotes
itemsKnowledgeItemView[]required—
next_cursorstring | nulloptional—
totalinteger | nulloptional—