Create Document
create_docCreates a new AFFiNE document with optional content, linking it under a parent doc or placing it in a specified folder for immediate sidebar organization.
Instructions
Create a new AFFiNE document with optional content. If parentDocId is provided, the new doc is linked into the sidebar tree immediately. If folderId is provided, the doc is placed inside that folder in the sidebar.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | Optional initial document title. | |
| content | No | Optional initial plain text or markdown-like content. | |
| folderId | No | Optional folder ID to place the doc in. Use list_organize_nodes to find folder IDs. | |
| parentDocId | No | Optional parent doc to link the new doc under in the sidebar. | |
| workspaceId | No | AFFiNE workspace id. Omit only when AFFINE_WORKSPACE_ID is configured. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | ||
| kind | Yes | ||
| docId | Yes | ||
| title | Yes | ||
| folderId | Yes | ||
| warnings | Yes | ||
| parentDocId | Yes | ||
| workspaceId | Yes | ||
| folderLinked | Yes | ||
| folderNodeId | Yes | ||
| linkedToParent | Yes |