Skip to main content
Glama

update_document

Destructive

Update the title or content of an existing document, replace entire content, append new text, or convert between document and template.

Instructions

    Modifies an existing document's title or content.

    IMPORTANT: This tool replaces the document content
    rather than just adding to it. For partial edits
    (changing specific text), prefer the edit_document
    tool instead.

    Use this tool when you need to:
    - Replace the entire document content
    - Change a document's title
    - Append new content to an existing document
    - Convert a document to or from a template

    Note: For Mermaid diagrams, use ```mermaidjs
    (not ```mermaid) as the code fence language
    identifier for proper rendering.

    Args:
        document_id: The document ID to update
        title: New title (if None, keeps existing title)
        text: New content (if None, keeps existing)
        append: If True, adds text to end of document
            instead of replacing
        template: If True, converts to a template.
            If False, converts a template back to a
            regular document.
        icon: Optional emoji character to use as the
            document icon (e.g. "📋", "🚀"). If None,
            keeps existing icon. Pass an empty string
            to remove the icon.

    Returns:
        Result message confirming update
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
iconNo
textNo
titleNo
appendNo
templateNo
document_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already indicate destructiveHint=true, and the description adds that it replaces content rather than appending. It also explains the append parameter. No contradictions. It doesn't detail further side effects, but the annotations handle safety profile adequately.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well-structured with a summary, warning, bullet list, and parameter descriptions. Front-loaded with the core action. No unnecessary sentences; each part adds value.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Comprehensive: covers all parameters, behavior, usage guidance, and a rendering note. Output schema exists, so the vague return mention is acceptable. Adequate for a tool with 6 params and 1 required.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, but the description's Args section fully explains each parameter's purpose, default behavior (e.g., None keeps existing), and special cases (e.g., icon empty string removes). Adds significant value.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states it modifies an existing document's title or content, and lists specific use cases. It distinguishes from the sibling tool 'edit_document' by noting that this tool replaces content rather than making partial edits.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit guidance is provided: for partial edits, prefer 'edit_document'. It lists when to use this tool (replace entire content, change title, append, convert template) and includes a note about Mermaid diagram syntax.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Vortiago/mcp-outline'

If you have feedback or need assistance with the MCP directory API, please join our Discord server