Documents

API for knowledge base documents

List documents

get

List a document on a given workspace and folder for a knowledge base.

Path parameters
workspaceIdstringRequired
Query parameters
limitinteger · min: 1 · max: 100Optional

Limits the project of results to return

Default: 10
pageTokenstring · max: 8000Optional

Pagination token that keeps of track of the current position in the list

reversebooleanOptional

Order in which to retrieve the results

Default: false
authorIdsstring · uuid[] | nullableOptional

Filter documents that were edited by at least one user from the list

tagsstring[] | nullableOptional

Filter documents that have at least one of the provided tags

folderPathsstring[] | nullableOptional

Paths of the folder. This can be used to narrow search to a specific folder

orderBystringOptional

Special ordering setting for the result documents

Example: createdAt:asc
statusstring · enum | nullableOptional

Filter documents based on status

Possible values:
titlestring | nullableOptional

Filter documents based on title

Responses
200

OK

application/json
get
/workspaces/{workspaceId}/content/documents

Create document

post

Create a document on a given workspace and folder for a knowledge base.

Path parameters
workspaceIdstringRequired
Query parameters
asyncEmbeddingbooleanOptional

Indicates if embedding should be done asynchronously

Body
bodystringRequired

Contents of the document, can be markdown or plain text

folderIdstring · uuid | nullableOptional

ID of the folder to store the document

folderPathstring | nullableOptional

Path of the folder to store the document

statusstring · enumRequired

Status of the document. If you want your document to be visible and used by other systems, make it 'active'

Possible values:
tagsstring[]Optional

Tags can be used to label the content and used in search

titlestringRequired

Title of the document

Responses
post
/workspaces/{workspaceId}/content/documents

Get document

get

Get a document on a given workspace an folder for a knowledge base.

Path parameters
workspaceIdstringRequired
contentPathstringRequired
Responses
200

OK

application/json
get
/workspaces/{workspaceId}/content/documents/{contentPath}

Delete documents

delete

Delete a folder on a given workspace and folder for a knowledge base.

Path parameters
workspaceIdstringRequired
contentPathstringRequired
Responses
delete
/workspaces/{workspaceId}/content/documents/{contentPath}

No content

Update Document

patch

Update a document on a given workspace for a knowledge base.

Path parameters
workspaceIdstringRequired
contentPathstringRequired
Query parameters
asyncEmbeddingbooleanOptional

Indicates if embedding should be done asynchronously

Body
bodystringOptional

Contents of the document, can be markdown or plain text

folderIdstring · uuid | nullableOptional

ID of the folder to store the document

folderPathstring | nullableOptional

Path of the folder to store the document

statusstring · enumOptional

Status of the document. If you want your document to be visible and used by other systems, make it 'active'

Possible values:
tagsstring[]Optional
titlestringOptional

Title of the document

Responses
200

Updated

application/json
patch
/workspaces/{workspaceId}/content/documents/{contentPath}

Was this helpful?