Skip to main content
Glama
gworkspace-mcp
by ctschak

Insert text

docs_insert

Insert text into Google Docs at an index, at the end, or before/after existing text; back-to-front batching prevents index shifts, and dry-run previews requests.

Instructions

Insert text at an index, at the end of the body, or before/after existing text. Several insertions are applied back-to-front in one batch so earlier ones cannot shift the indices later ones rely on. Supports dryRun.

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": "<document>",
      "insertions": "<insertions>"
    },
    "name": "docs_insert"
  }
}

Input Schema

NameRequiredDescriptionDefault
tabNoTab id or title, for documents with several tabs. Reads default to the first tab; writes to a multi-tab document REQUIRE this rather than guessing. Get ids from docs_describe.
dryRunNoReturn the exact requests that would be sent, in the order they would be applied, and send nothing.
accountNoGoogle account to act as. Optional when one is authorised or a default is set.
documentYesDocument URL or file id. Both accepted.
insertionsYesText insertions. Applied back-to-front so earlier ones cannot shift later indices.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations, the description carries the full burden and does disclose the important back-to-front batching behavior so insertions do not shift later indices. It also mentions dryRun, but it does not cover permissions, irreversibility, or tab/account write requirements beyond what the schema already states.

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?

The description is three focused sentences, front-loads the action and supported placements, then explains the batching order guarantee and dryRun support. There is no redundant wording.

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

Completeness3/5

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

For a mutation tool with no annotations, the description covers the core insertion modes and an important ordering behavior. However, it leaves gaps around when to choose this over sibling tools, multi-tab write requirements, and the effects of applying multiple insertions.

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

Parameters3/5

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

Schema description coverage is 100%, so the parameter schema already documents document, tab, account, dryRun, and insertion location variants. The description adds some meaning about placement modes and ordering, but does not add syntax or constraints beyond the schema.

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

Purpose4/5

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

The description gives a specific verb and resource: insert text into a document, with the supported placement modes (index, end, before/after text). It does not explicitly distinguish itself from the sibling docs_replace_text, but the insertion focus is clear.

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

Usage Guidelines3/5

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

The description implies when the tool is appropriate by listing insertion locations and batching behavior, but it gives no explicit guidance on when to use this versus docs_replace_text or docs_batch_update_raw, and no exclusions or prerequisites.

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