Document ID (cdo_...) whose content to retrieve.
Optionalparams: { limit?: number; offset?: number; unit?: string }Query parameters.
Optionallimit?: numberMaximum number of units to return when slicing. Defaults to 200 when unit is "lines" and 8192 when unit is "bytes".
Optionaloffset?: numberStarting position for a content slice. When unit is "lines", this is a 1-indexed line number. When unit is "bytes", this is a 0-indexed byte offset. Omit to return the full document.
Optionalunit?: stringUnit to use for offset and limit. One of "lines" (default) or "bytes".
The document's content, optionally sliced by offset and limit.
Delete a context document Permanently deletes a context document and all of its associated chunk items. This action is irreversible. The backing storage file, if any, is not deleted — storage files can be shared across multiple documents and are cleaned up separately by the platform's storage garbage collector. The caller must be authenticated and the request must be scoped to the app that owns the document.
Document ID (cdo_...) to delete.
Empty body. Returns HTTP 204 on success.
Retrieve a context document Returns a single context document identified by its ID. The response includes document metadata such as title, size, and ownership fields, but not the document's text content. To read the full or partial content, use the content endpoint. The caller must be authenticated and the request must be scoped to the app that owns the document.
Document ID (cdo_...) to retrieve.
The requested context document's metadata.
List context documents
Returns a paginated list of context documents visible to the authenticated
caller within the scoped app. Results are ordered by creation time
descending.
Use q for a case-insensitive title prefix search. Use source,
installation, or agent to narrow results to documents belonging to
specific sources, installations, or agents. Multiple values within each
filter are treated as OR conditions. Filters may be combined.
The response includes page-level metadata so you can navigate through
large result sets without cursor tokens.
Optionalparams: {Query parameters.
Optionalagent?: string[]Return only documents owned by these agent IDs. Multiple values are OR'd.
Optionalinstallation?: string[]Return only documents belonging to these installation IDs. Multiple values are OR'd.
Optionalpage?: numberPage number to return. Defaults to 1.
OptionalpageSize?: numberNumber of documents per page. Defaults to 25.
Optionalq?: stringCase-insensitive prefix filter applied to the document title.
Optionalsource?: string[]Return only documents belonging to these source IDs (cso_...). Multiple values are OR'd.
Successful response
Retrieve a context document's content Returns the full text of a context document, or a slice of it when
offset,limit, andunitare supplied. Both file-backed and inline documents are supported; the response shape is the same in either case. When slicing, setunitto"lines"(default) or"bytes". A line-based slice uses a 1-indexedoffset; a byte-based slice uses a 0-indexedoffset. If you omitoffset, the full document text is returned and the slice-specific response fields (unit,offset,limit,start_line,end_line,start_byte,end_byte) are absent. The caller must be authenticated and the request must be scoped to an app that owns the document.