kb_documents_edit_begin
Open a surgical edit session on a document and snapshot its current revision. Stage edits with kb_documents_edit_apply, then kb_documents_edit_commit (lands one revision) or kb_documents_edit_discard. Calling this again for a document you already have an open session on resumes that session (resumed=true).
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": {
"document_id": "<document_id>"
},
"name": "kb_documents_edit_begin"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| document_id | Yes | Document id to edit (required) | |
| tenant_slug | No | Tenant slug to target. Required when your token grants several workspaces; omit when it grants one. If you omit it with several, the refusal names your default workspace; call kb_tenants_list to see every workspace the token grants. | |
| include_body | No | Echo the full working buffer back (default false; the body you open is the document you already have - request it only for a server-confirmed snapshot). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| resumed | Yes | ||
| expires_at | Yes | ||
| session_id | Yes | ||
| document_id | Yes | ||
| working_body_md | No |