Skip to main content
Glama
marekrost

mcp-server-spreadsheet

rename_sheet

Change the name of a sheet in a spreadsheet file by specifying the current name and desired new name.

Instructions

Rename an existing sheet in the workbook.

Returns the new sheet name on success.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fileYesPath to the spreadsheet file
old_nameYesCurrent name of the sheet to rename
new_nameYesNew name for the sheet

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • Handler function for the rename_sheet tool which renames a sheet in a workbook.
    def rename_sheet(
        file: Annotated[str, Field(description="Path to the spreadsheet file")],
        old_name: Annotated[str, Field(description="Current name of the sheet to rename")],
        new_name: Annotated[str, Field(description="New name for the sheet")],
    ) -> str:
        """Rename an existing sheet in the workbook.
    
        Returns the new sheet name on success.
        """
        wb = load_workbook(file)
        ws = wb.get_sheet(old_name)
        ws.title = new_name
        wb.save(file)
        return new_name
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions that the tool renames a sheet and returns the new name on success, but lacks critical details: it doesn't specify error conditions (e.g., if the sheet doesn't exist or the new name is invalid), permission requirements, or side effects (e.g., whether references to the old name break). This is inadequate for a mutation tool with zero annotation coverage.

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 extremely concise and front-loaded: the first sentence states the core action, and the second sentence adds the return value. There is zero waste or redundancy, and every sentence earns its place by providing essential information efficiently.

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?

Given that there is an output schema (implied by 'Has output schema: true'), the description doesn't need to explain return values in detail. However, for a mutation tool with no annotations, the description should provide more behavioral context (e.g., error handling, prerequisites). It's minimally adequate but has clear gaps in completeness for safe and effective use.

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 schema already documents all three parameters ('file', 'old_name', 'new_name') with clear descriptions. The description adds no additional meaning beyond what the schema provides, such as format examples or constraints (e.g., name length limits). With high schema coverage, the baseline score of 3 is appropriate.

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 verb ('Rename') and resource ('an existing sheet in the workbook'), making the purpose unambiguous. It distinguishes from siblings like 'copy_sheet' or 'delete_sheet' by specifying renaming rather than copying or deleting. However, it doesn't explicitly differentiate from tools like 'add_sheet' or 'list_sheets' beyond the action itself.

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 prerequisites (e.g., the sheet must exist), exclusions (e.g., cannot rename to an existing name), or comparisons with sibling tools like 'copy_sheet' for creating renamed copies. Usage is implied by the action but not explicitly contextualized.

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/marekrost/mcp-server-spreadsheet'

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