Context Documents

Get the latest context document tree

Get the most recent context document tree for the authenticated app.

The sync daemon polls this endpoint to fetch updated files. Default behaviour: serve the latest "ready" tree, where "ready" depends on whether the app has require_review enabled:

  • require_review=False (default): latest COMPLETED ships immediately.
  • require_review=True: latest PUBLISHED only — apps that gate on a curator's approval before the daemon picks up the new tree.

?status=<value> filters to a specific status (case-insensitive). ?include_published=true returns the absolute latest tree (any status) so the dashboard can surface an in-flight PROCESSING generation when the user navigates away mid-gen and back. The daemon path (no include_published) keeps strict status filtering.

get/context-documents/tree/latest

Query parameters

statusstring nullable
include_publishedboolean

Response

Successful Response

tree_idstring required
statusstring required
versioninteger required
errorstring nullable required
created_atstring date-time required
completed_atstring date-time nullable required
metaobject required

Changes