Update Block
update_blockPartially update a paragraph, heading, quote, list, or code block by block id, changing only the fields you provide while preserving the block id.
Instructions
Partially update one paragraph, heading, quote, list, or code block while preserving its block id. Omitted fields remain unchanged. Paragraph/heading/quote conversions preserve ids; cross-flavour conversions are rejected.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | No | Replacement block text. Delta arrays preserve inline attributes. For LinkedPage references, set insert to one ASCII space and pass the pageId in reference attributes; visible labels are resolved by AFFiNE. Omit to preserve the current text. | |
| type | No | Resulting logical block type. | |
| docId | Yes | AFFiNE document id. | |
| level | No | Heading level. Only valid when the resulting type is heading. | |
| style | No | Resulting list style. Only valid for list blocks. | |
| blockId | Yes | Block id to update. | |
| checked | No | Todo checked state. Only valid for a list whose resulting style is todo. | |
| workspaceId | No | AFFiNE workspace id. Omit only when AFFINE_WORKSPACE_ID is configured. | |
| expectedRevision | No | Optional read_doc revision of this primary document. Reject stale content before writing. Covers document content, not workspace metadata; requires all writers to share one MCP server. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | No | ||
| code | No | ||
| block | No | ||
| error | No | ||
| blockId | No | ||
| changed | No | ||
| details | No | ||
| updated | No | ||
| previous | No | ||
| causeCode | No | ||
| retryable | No | ||
| recoveryGuidance | No |