Skip to content

Feature Request: Add tabId parameter to applyParagraphStyle and applyTextStyle #39

@chrisblattman

Description

@chrisblattman

Summary

The readGoogleDoc, appendToGoogleDoc, and insertText tools support a tabId parameter for multi-tab documents, but applyParagraphStyle
and applyTextStyle do not. This means formatting can only be applied to Tab 1 content.

Use Case

When programmatically managing documents with multiple tabs (e.g., project management docs with separate tabs for Overview, Meeting Notes, Action
Items), users need to apply formatting to content in any tab, not just the first one.

Current Behavior

applyParagraphStyle with target: {textToFind: "Meeting Notes"}
→ Error: Could not find "Meeting Notes" in the document

The text exists in Tab 2, but the tool only searches Tab 1.

Proposed Solution

Add optional tabId parameter to:

  • applyParagraphStyle
  • applyTextStyle
  • formatMatchingText
  • Any other tools that search/modify document content

This would match the pattern already used by readGoogleDoc, appendToGoogleDoc, and insertText.

API Support

The Google Docs API batchUpdate requests support tabId in the range specification:

{                                                                                                                                                
  "updateParagraphStyle": {                                                                                                                      
    "range": {                                                                                                                                   
      "startIndex": 1,                                                                                                                           
      "endIndex": 50,                                                                                                                            
      "tabId": "t.abc123"                                                                                                                        
    },                                                                                                                                           
    "paragraphStyle": {"namedStyleType": "HEADING_1"},                                                                                           
    "fields": "namedStyleType"                                                                                                                   
  }                                                                                                                                              
}                                                                                                                                                
                                                                                                                                                 
Environment                                                                                                                                      
                                                                                                                                                 
Tested with google-docs-mcp on January 31, 2026. Tab read/write works; formatting is Tab-1 only.                                                 
                                                                                                                                                 
Thank you for this excellent MCP server - the tab support for read/write is already a huge improvement! 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions