v1

latestOpenAPI 3.0.0BSD-3-Clause2026-07-146135105.7 KB
database

Create Document

Create a new Document. Before using this route, you should create a new collection resource using either a server integration API or directly from your database console.

post/database/collections/{collectionId}/documents

Path parameters

collectionIdstring required

Collection unique ID. You can create a new collection with validation rules using the Database service server integration.

Request body

dataobject required

Document data as JSON object.

parentDocumentstring

Parent document unique ID. Use when you want your new document to be a child of a parent document.

parentPropertystring

Parent document property name. Use when you want your new document to be a child of a parent document.

parentPropertyTypestring

Parent document property connection type. You can set this value to assign, append or prepend, default value is assign. Use when you want your new document to be a child of a parent document.

readstring[]

An array of strings with read permissions. By default only the current user is granted with read permissions. learn more about permissions and get a full list of available permissions.

writestring[]

An array of strings with write permissions. By default only the current user is granted with write permissions. learn more about permissions and get a full list of available permissions.

Response

Document

$collectionstring required

Collection ID.

$idstring required

Document ID.

$permissionsobject required

Document permissions.