Documents & manuscript

13 MCP tools. Each applies to the one project the server was launched with; every mutating call is one undo step and saves immediately.

add_footnote

Adds a footnote or endnote definition to a document. The inline [^id] reference goes in the body (write it with the body/append tools); this defines the note's text. A fresh definition is an orphan until the body cites [^id].

ParameterTypeRequiredDescription
endnotebooleannotrue to make it an endnote (collected at the end) rather than a footnote.
footnote_idstringnoAn id for the [^id] reference; auto-generated when omitted.
idstringnoThe document's id, to disambiguate when several documents share the title.
textstringyesThe note's content (Markdown).
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "add_footnote",
  "arguments": {
    "title": "<title>",
    "text": "<text>"
  }
}

append_to_document

Appends prose to the end of a document's body, preserving its stored format (use this to continue a chapter without resending the whole body).

ParameterTypeRequiredDescription
idstringnoThe document's id, to disambiguate when several documents share the title.
textstringyesThe prose to add at the end of the body (Markdown).
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "append_to_document",
  "arguments": {
    "title": "<title>",
    "text": "<text>"
  }
}

create_document

Creates a document in the manuscript tree, appended after its siblings. Args: title (must be unique), optional kind/body/synopsis/parent.

ParameterTypeRequiredDescription
bodystringnoInitial body as Markdown (Fountain for a screenplay).
kindstringnoDocument kind: prose (default), note, or screenplay.
parentstringnoTitle of the parent document to nest under (omit for top level).
parent_idstringnoId of the parent document, when its title collides.
synopsisstringnoA short synopsis for the outline and corkboard.
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "create_document",
  "arguments": {
    "title": "<title>"
  }
}

find_replace

Project-wide find & replace over document bodies (regex-capable). With dry_run or no replace it lists matches; a replace applies as one undo step.

ParameterTypeRequiredDescription
case_sensitivebooleannoMatch case exactly (default false).
dry_runbooleannoList the matches without changing anything.
findstringyesThe text (or pattern, with regex) to search for.
regexbooleannoInterpret find as a regular expression.
replacestringnoThe replacement text; \1..\9 expand regex capture groups. Omit to only list matches.
scopestringnoTitle of a document to search only within (that document and its subtree); omit to search the whole project.
scope_idstringnoId form of scope, when its title collides.
whole_wordbooleannoMatch whole words only (ignored with regex; use \b).

Example call

{
  "name": "find_replace",
  "arguments": {
    "find": "<find>"
  }
}

get_document

Reads one document: kind, status, point of view, synopsis, word count, and its body as Markdown. Address it by title (or by id when titles collide).

ParameterTypeRequiredDescription
idstringnoThe document's id, to disambiguate when several documents share the title.
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "get_document",
  "arguments": {
    "title": "<title>"
  }
}

get_document_versions

Lists a document's saved version snapshots with labels and timestamps, oldest first.

ParameterTypeRequiredDescription
idstringnoThe document's id, to disambiguate when several documents share the title.
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "get_document_versions",
  "arguments": {
    "title": "<title>"
  }
}

get_manuscript_tree

Shows the manuscript's document tree in reading order, each document with its kind (prose/note/screenplay) and word count.

No parameters.

Example call

{
  "name": "get_manuscript_tree",
  "arguments": {}
}

list_footnotes

Lists a document's footnotes and endnotes in reader numbering (order of first [^id] reference in the body), plus any unreferenced definitions.

ParameterTypeRequiredDescription
idstringnoThe document's id, to disambiguate when several documents share the title.
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "list_footnotes",
  "arguments": {
    "title": "<title>"
  }
}

manage_variants

Manages a document's alternate ('what-if') drafts, distinct from version snapshots. action: list; create (branches a new draft from the current one and makes it active); switch (parks the live body and loads the named draft -- no draft is lost); rename (renames the active draft); delete (removes a named alternate, never the active one). Address drafts by name, which must stay unique.

ParameterTypeRequiredDescription
actionstringnolist (default), create, switch, rename, or delete.
idstringnoThe document's id, to disambiguate when several documents share the title.
namestringnoThe draft name to create / switch to / delete (address alternates by name).
new_namestringnoThe new name for the active draft (rename).
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "manage_variants",
  "arguments": {
    "title": "<title>"
  }
}

remove_footnote

Deletes a footnote definition by id. Any [^id] marker left in the body is reported so it can be removed from the prose too.

ParameterTypeRequiredDescription
footnote_idstringyesThe footnote's id to remove.
idstringnoThe document's id, to disambiguate when several documents share the title.
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "remove_footnote",
  "arguments": {
    "title": "<title>",
    "footnote_id": "<footnote_id>"
  }
}

snapshot_document_version

Saves a version snapshot of a document's current body, so the draft can later be compared against or restored in Easy Writer's Version History.

ParameterTypeRequiredDescription
idstringnoThe document's id, to disambiguate when several documents share the title.
labelstringnoA name for the snapshot (defaults to a timestamped label).
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "snapshot_document_version",
  "arguments": {
    "title": "<title>"
  }
}

update_document

Sparse update of one document: only the keys you pass change (new_title, body, synopsis, status, point_of_view, word_count_target, kind, parent). Omitted keys stay untouched. Reorder among siblings with "order" (first/last), "index" (0-based position), or "before"/"after" (a sibling title) -- alone to reorder in place, or with "parent" to reposition after moving; at most one ordering key.

ParameterTypeRequiredDescription
afterstringnoReorder immediately after the sibling document with this title.
beforestringnoReorder immediately before the sibling document with this title.
bodystringnoReplace the whole body with this Markdown (empty clears it).
idstringnoThe document's id, to disambiguate when several documents share the title.
indexintegernoReorder to this 0-based position among the destination's siblings (0 = first).
kindstringnoChange the kind: prose, note, or screenplay.
new_titlestringnoRename the document to this title.
orderstringnoReorder among the destination's siblings: "first" or "last". Combine with "parent" to reposition after moving, or use alone to reorder in place.
parentstringnoMove the document under this parent title; an empty string moves it to the top level.
parent_idstringnoMove under this parent id, when the parent's title collides.
point_of_viewstringnoThe scene's point-of-view label (empty clears it).
statusstringnoWorkflow status shown in the outline/corkboard, e.g. "Draft", "Revised", "Final" (empty clears it).
synopsisstringnoReplace the synopsis (empty clears it).
titlestringyesThe document's title (case-insensitive).
word_count_targetintegernoA word-count writing goal for the document (0 clears the target).

Example call

{
  "name": "update_document",
  "arguments": {
    "title": "<title>"
  }
}

update_footnote

Edits an existing footnote definition's text and/or endnote flag, by id.

ParameterTypeRequiredDescription
endnotebooleannoSet the endnote flag.
footnote_idstringyesThe footnote's id (as shown by list_footnotes).
idstringnoThe document's id, to disambiguate when several documents share the title.
textstringnoNew content for the note (non-empty).
titlestringyesThe document's title (case-insensitive).

Example call

{
  "name": "update_footnote",
  "arguments": {
    "title": "<title>",
    "footnote_id": "<footnote_id>"
  }
}