docs_insert_text

Pack: google_docs · Endpoint: https://gateway.pipeworx.io/google_docs/mcp

Insert text at a specific position in a Google Doc (e.g., position 0 for start, position 50 for middle).

Parameters

NameTypeRequiredDescription
document_idstringyesDocument ID
textstringyesText to insert
indexnumbernoCharacter index to insert at (1 = start of body)

Example call

Arguments

{
  "document_id": "1BxiMVs0XRA5nFMKUVfGo6Q6XcYBCy_N1LCcFrZkZecc",
  "text": "Executive Summary",
  "index": 1
}

curl

curl -X POST https://gateway.pipeworx.io/google_docs/mcp \
  -H 'Content-Type: application/json' \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"docs_insert_text","arguments":{"document_id":"1BxiMVs0XRA5nFMKUVfGo6Q6XcYBCy_N1LCcFrZkZecc","text":"Executive Summary","index":1}}}'

TypeScript (@pipeworx/sdk)

import { Pipeworx } from '@pipeworx/sdk';
const pipeworx = new Pipeworx();

const result = await pipeworx.call('docs_insert_text', {
  "document_id": "1BxiMVs0XRA5nFMKUVfGo6Q6XcYBCy_N1LCcFrZkZecc",
  "text": "Executive Summary",
  "index": 1
});

More examples

{
  "document_id": "1BxiMVs0XRA5nFMKUVfGo6Q6XcYBCy_N1LCcFrZkZecc",
  "text": "Updated deadline: March 15",
  "index": 150
}

Response shape

FieldTypeDescription
documentIdstringDocument ID
repliesarrayResults of batch update requests
errorstringError code if connection failed
messagestringError message if connection failed
Full JSON Schema
{
  "type": "object",
  "description": "Response from inserting text at specified index",
  "properties": {
    "documentId": {
      "type": "string",
      "description": "Document ID"
    },
    "replies": {
      "type": "array",
      "description": "Results of batch update requests"
    },
    "error": {
      "type": "string",
      "description": "Error code if connection failed"
    },
    "message": {
      "type": "string",
      "description": "Error message if connection failed"
    }
  }
}

Connect

Add this to your MCP client config, or use one-click install buttons:

{
  "mcpServers": {
    "google_docs": {
      "url": "https://gateway.pipeworx.io/google_docs/mcp"
    }
  }
}

See Getting Started for client-specific install steps.

Regenerated from source · build May 9, 2026