Skip to content
Get started

Documents

Add document
POST/v3/documents
List documents
POST/v3/documents/list
Update document
PATCH/v3/documents/{id}
Get document
GET/v3/documents/{id}
Delete document by ID or customId
DELETE/v3/documents/{id}
Bulk delete documents
DELETE/v3/documents/bulk
Upload a file
POST/v3/documents/file
Batch add documents
POST/v3/documents/batch
Get processing documents
GET/v3/documents/processing
ModelsExpand Collapse
DocumentAddResponse object { id, status }
id: string

Unique identifier of the document

status: string

Status of the document

DocumentListResponse object { memories, pagination }

List of documents

memories: array of object { id, connectionId, createdAt, 11 more }
id: string

Unique identifier of the document.

minLength22
maxLength22
connectionId: string

Optional ID of connection the document was created from. This is useful for identifying the source of the document.

minLength22
maxLength22
createdAt: string

Creation timestamp

formatdatetime
customId: string

Optional custom ID of the document. This could be an ID from your database that will uniquely identify this document.

maxLength255
filepath: string
metadata: string or number or boolean or 2 more

Optional metadata for the document. This is used to store additional information about the document. You can use this to store any additional information you need about the document. Metadata can be filtered through. Keys must be strings and are case sensitive. Values can be strings, numbers, or booleans. You cannot nest objects.

One of the following:
string
number
boolean
map[unknown]
array of unknown
status: "unknown" or "queued" or "extracting" or 5 more

Status of the document

One of the following:
"unknown"
"queued"
"extracting"
"chunking"
"embedding"
"indexing"
"done"
"failed"
summary: string

Summary of the document content

title: string

Title of the document

type: "text" or "pdf" or "tweet" or 10 more

Type of the document

One of the following:
"text"
"pdf"
"tweet"
"google_doc"
"google_slide"
"google_sheet"
"image"
"video"
"audio"
"notion_doc"
"webpage"
"onedrive"
"github_markdown"
updatedAt: string

Last update timestamp

formatdatetime
DeprecatedcontainerTags: optional array of string

Optional tags this document should be containerized by. This can be an ID for your user, a project ID, or any other identifier you wish to use to group documents.

content: optional string

Content of the document (only included when includeContent=true)

url: optional string

URL of the document

DocumentUpdateResponse object { id, status }
id: string

Unique identifier of the document

status: string

Status of the document

DocumentGetResponse object { id, connectionId, content, 16 more }

Document object

id: string

Unique identifier of the document.

minLength22
maxLength22
connectionId: string

Optional ID of connection the document was created from. This is useful for identifying the source of the document.

minLength22
maxLength22
content: string

The content to extract and process into a document. This can be a URL to a website, a PDF, an image, or a video.

Plaintext: Any plaintext format

URL: A URL to a website, PDF, image, or video

We automatically detect the content type from the url’s response format.

createdAt: string

Creation timestamp

formatdatetime
customId: string

Optional custom ID of the document. This could be an ID from your database that will uniquely identify this document.

maxLength255
dreamingStatus: "dreaming" or "done"
One of the following:
"dreaming"
"done"
filepath: string
metadata: string or number or boolean or 2 more

Optional metadata for the document. This is used to store additional information about the document. You can use this to store any additional information you need about the document. Metadata can be filtered through. Keys must be strings and are case sensitive. Values can be strings, numbers, or booleans. You cannot nest objects.

One of the following:
string
number
boolean
map[unknown]
array of unknown
ogImage: string
raw: unknown

Raw content of the document

source: string

Source of the document

maxLength255
status: "unknown" or "queued" or "extracting" or 5 more

Status of the document

One of the following:
"unknown"
"queued"
"extracting"
"chunking"
"embedding"
"indexing"
"done"
"failed"
summary: string

Summary of the document content

taskType: "memory" or "superrag"

Task type: “memory” (default) for full context layer with SuperRAG built in, “superrag” for managed RAG as a service.

One of the following:
"memory"
"superrag"
title: string

Title of the document

type: "text" or "pdf" or "tweet" or 10 more

Type of the document

One of the following:
"text"
"pdf"
"tweet"
"google_doc"
"google_slide"
"google_sheet"
"image"
"video"
"audio"
"notion_doc"
"webpage"
"onedrive"
"github_markdown"
updatedAt: string

Last update timestamp

formatdatetime
DeprecatedcontainerTags: optional array of string

Optional tags this document should be containerized by. This can be an ID for your user, a project ID, or any other identifier you wish to use to group documents.

url: optional string

URL of the document

DocumentDeleteBulkResponse object { deletedCount, success, containerTags, errors }

Response for bulk document deletion

deletedCount: number

Number of documents successfully deleted

success: boolean

Whether the bulk deletion was successful

DeprecatedcontainerTags: optional array of string

Container tags that were processed (only applicable when deleting by container tags)

errors: optional array of object { id, error }

Array of errors for documents that couldn’t be deleted (only applicable when deleting by IDs)

id: string
error: string
DocumentUploadFileResponse object { id, status }
id: string

Unique identifier of the document

status: string

Status of the document

DocumentBatchAddResponse object { failed, results, success }
failed: number

Count of documents that failed to add

results: array of object { id, status, details, error }

Array of results for each document in the batch

id: string

Unique identifier of the document (empty string for failed items)

status: string

Status of the document (e.g. ‘done’, ‘queued’, ‘error’)

details: optional string

Additional error details when status is ‘error’

error: optional string

Error message when status is ‘error’

success: number

Count of documents successfully added

DocumentListProcessingResponse object { documents, totalCount }

List of documents currently being processed

documents: array of object { id, createdAt, customId, 6 more }
id: string

Unique identifier of the document.

minLength22
maxLength22
createdAt: string

Creation timestamp

formatdatetime
customId: string

Optional custom ID of the document. This could be an ID from your database that will uniquely identify this document.

maxLength255
metadata: string or number or boolean or 2 more

Optional metadata for the document. This is used to store additional information about the document. You can use this to store any additional information you need about the document. Metadata can be filtered through. Keys must be strings and are case sensitive. Values can be strings, numbers, or booleans. You cannot nest objects.

One of the following:
string
number
boolean
map[unknown]
array of unknown
status: "unknown" or "queued" or "extracting" or 5 more

Status of the document

One of the following:
"unknown"
"queued"
"extracting"
"chunking"
"embedding"
"indexing"
"done"
"failed"
title: string

Title of the document

type: "text" or "pdf" or "tweet" or 10 more

Type of the document

One of the following:
"text"
"pdf"
"tweet"
"google_doc"
"google_slide"
"google_sheet"
"image"
"video"
"audio"
"notion_doc"
"webpage"
"onedrive"
"github_markdown"
updatedAt: string

Last update timestamp

formatdatetime
DeprecatedcontainerTags: optional array of string

Optional tags this document should be containerized by. This can be an ID for your user, a project ID, or any other identifier you wish to use to group documents.

totalCount: number

Total number of processing documents