Skip to main content
Glama
taylorwilsdon

Google Workspace MCP Server - Control Gmail, Calendar, Docs, Sheets, Slides, Chat, Forms & Drive

create_sheet

Add a new sheet to an existing Google Spreadsheet by specifying the user's email, spreadsheet ID, and desired sheet name. Returns a confirmation message upon successful creation.

Instructions

Creates a new sheet within an existing spreadsheet.

Args:
    user_google_email (str): The user's Google email address. Required.
    spreadsheet_id (str): The ID of the spreadsheet. Required.
    sheet_name (str): The name of the new sheet. Required.

Returns:
    str: Confirmation message of the successful sheet creation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
serviceYes
sheet_nameYes
spreadsheet_idYes
user_google_emailYes

Implementation Reference

  • The handler function decorated with @server.tool() that implements the create_sheet tool. It uses the Google Sheets API to add a new sheet to an existing spreadsheet via batchUpdate request.
    @server.tool()
    @handle_http_errors("create_sheet", service_type="sheets")
    @require_google_service("sheets", "sheets_write")
    async def create_sheet(
        service,
        user_google_email: str,
        spreadsheet_id: str,
        sheet_name: str,
    ) -> str:
        """
        Creates a new sheet within an existing spreadsheet.
    
        Args:
            user_google_email (str): The user's Google email address. Required.
            spreadsheet_id (str): The ID of the spreadsheet. Required.
            sheet_name (str): The name of the new sheet. Required.
    
        Returns:
            str: Confirmation message of the successful sheet creation.
        """
        logger.info(f"[create_sheet] Invoked. Email: '{user_google_email}', Spreadsheet: {spreadsheet_id}, Sheet: {sheet_name}")
    
        request_body = {
            "requests": [
                {
                    "addSheet": {
                        "properties": {
                            "title": sheet_name
                        }
                    }
                }
            ]
        }
    
        response = await asyncio.to_thread(
            service.spreadsheets()
            .batchUpdate(spreadsheetId=spreadsheet_id, body=request_body)
            .execute
        )
    
        sheet_id = response["replies"][0]["addSheet"]["properties"]["sheetId"]
    
        text_output = (
            f"Successfully created sheet '{sheet_name}' (ID: {sheet_id}) in spreadsheet {spreadsheet_id} for {user_google_email}."
        )
    
        logger.info(f"Successfully created sheet for {user_google_email}. Sheet ID: {sheet_id}")
        return text_output
  • Exports the create_sheet tool function for use in the gsheets package, facilitating its availability and registration upon module import.
    from .sheets_tools import (
        list_spreadsheets,
        get_spreadsheet_info,
        read_sheet_values,
        modify_sheet_values,
        create_spreadsheet,
        create_sheet,
    )
    
    __all__ = [
        "list_spreadsheets",
        "get_spreadsheet_info", 
        "read_sheet_values",
        "modify_sheet_values",
        "create_spreadsheet",
        "create_sheet",
    ]
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool creates a new sheet, implying a write operation, but doesn't mention permissions required (e.g., edit access to the spreadsheet), potential side effects (e.g., if a sheet with the same name exists), or error handling. The return value is briefly noted, but without details on format or error messages. This leaves significant gaps for a mutation tool.

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

Conciseness4/5

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

The description is well-structured and appropriately sized, with a clear purpose statement followed by parameter and return sections. Each sentence adds value, and there's no redundant information. However, it could be more front-loaded by integrating key usage notes into the opening sentence for faster comprehension.

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

Completeness2/5

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

Given the complexity of a write operation with 4 parameters, no annotations, and no output schema, the description is incomplete. It lacks critical context such as authentication requirements, error conditions, and detailed return value information. For a tool that modifies data, this leaves the agent with insufficient guidance to use it reliably.

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?

The description lists all four parameters with brief explanations, but the schema description coverage is 0%, so the schema provides no additional details. The description adds basic semantics (e.g., 'user's Google email address'), but it doesn't clarify the purpose of the 'service' parameter or provide examples or constraints (e.g., email format, spreadsheet ID structure). This compensates somewhat for the schema gap but remains minimal.

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 clearly states the tool's purpose: 'Creates a new sheet within an existing spreadsheet.' It specifies the verb ('creates') and resource ('new sheet within an existing spreadsheet'), making the action unambiguous. However, it doesn't explicitly differentiate from sibling tools like 'create_spreadsheet' or 'modify_sheet_values', which would require mentioning that this adds a sheet to an existing spreadsheet rather than creating a new spreadsheet or modifying existing sheets.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'create_spreadsheet' (for creating new spreadsheets) or 'modify_sheet_values' (for editing sheets), nor does it specify prerequisites such as needing an existing spreadsheet ID. The user must infer usage from the purpose alone, which is insufficient for clear decision-making.

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

Related 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/taylorwilsdon/google_workspace_mcp'

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