update_block
Replace a OneNote block with Markdown, edit a block’s text substring, or update page title/body; use get_page IDs and baseline content to prevent overwrite conflicts.
Instructions
Replace a block with Markdown, edit a block text substring, or update the page title/body. Get current Graph element IDs and baseline content from get_page.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"page": "<page>"
},
"name": "update_block"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| page | Yes | ||
| force | No | Override conflict check when true | |
| title | No | ||
| compact | No | Default true. Set false to include the full page object in the response. | |
| section | No | Optional section name, Notebook/Section path, ID, or scoped key to narrow title lookup | |
| block_id | No | Graph element ID from get_page (e.g. `p:{...}`) | |
| markdown | No | ||
| with_text | No | New text for replace_text | |
| replace_text | No | Exact text to replace in block_id; provide with_text and omit markdown | |
| expected_content | No | Baseline block/page content from prior read; aborts with conflict if remote changed |