get_document_session_state

MCP tool from Che Word MCP by PsychQuant

Legacy session snapshot (preserved for backward compat)

How to use it

get_document_session_state is exposed by the Che Word MCP MCP server. Add the server to your MCP client (Claude Desktop, Cursor, Windsurf and others), and the get_document_session_state tool becomes available to the model automatically. See the full listing for setup details and every tool this server provides.

Install Che Word MCP

$/usr/local/bin/CheWordMCP
FULL CHE WORD MCP LISTING

Other tools in Che Word MCP (39)

apply_style

Apply built-in or custom styles

check_disk_drift

Informational — returns { drifted, diskmtime, storedmtime, diskhashmatches }

close_document

Close an open document (pass discardchanges: true to drop dirty edits)

create_document

Create a new Word document

create_style

Create custom style — extended with 6 v3.10 args: basedon, linkedstyleid, nextstyleid, qformat, hidden, semihidden

delete_paragraph

Delete a paragraph

delete_style

Delete custom style

delete_table

Delete a table

estimate_paragraph_for_page

v3.18.0+ — estimate a Word UI page number to a getparagraphs candidate range (heuristic JSON with confidence + warning)

finalize_document

Save and close in one guarded step

format_text

Apply text formatting (bold, italic, color, font)

get_paragraphs

Get all paragraphs with formatting

get_session_state

Snapshot { sourcepath, diskhashhex, diskmtimeiso8601, isdirty, trackchangesenabled }

get_style_inheritance_chain

Traverse basedOn chain upward to root with cycle detection

get_tables

Get all tables information

get_text

Get plain text content

insert_nested_table

Insert table-in-cell, depth-limited to 5 (throws nestedtoodeep)

insert_paragraph

Insert a new paragraph

insert_table

Insert a table with optional data

link_styles

Bidirectional <w:link> between paragraph and character style pair

list_open_documents

List all open documents

list_styles

List all available styles (Direct Mode supported)

merge_cells

Merge cells horizontally or vertically

open_document

Open an existing .docx file (trackchanges default false since v3.0.0)

reload_from_disk

Cooperative reload; requires force: true on dirty doc

replace_text

Cross-run-safe find & replace with scope (body\

replace_text_batch

v2.2.0 — sequential N-replacement batch, single save at end, dryrun / stoponfirstfailure

revert_to_disk

Re-read source path, discard in-memory edits (destructive-by-design)

save_document

Save document to .docx file

search_text_batch

v2.2.0 — aggregated multi-query search, works in Direct + Session Mode

set_header_row

Mark row as <w:tblHeader/> for repeat-on-page-break

set_paragraph_format

Set paragraph formatting (alignment, spacing)

set_table_conditional_style

Apply firstRow / lastRow / bandedRows etc. (10 region types) via <w:tblStylePr>

set_table_indent

Table-level left indent (<w:tblInd>)

set_table_layout

Switch fixed / autofit

set_table_style

Set table borders and shading

update_cell

Update cell content

update_paragraph

Update paragraph content

update_style

Update style definition — same 6 extended args