Skip to main content
Glama
fabkho
by fabkho

Rename Translation Key

rename_translation_key

Rename a translation key across all locale files in a layer while preserving every value. Use dryRun to preview changes before applying them.

Instructions

Rename/move a translation key across ALL locale files in a layer. Preserves the value in every locale. Use dryRun to preview changes before applying them.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
layerYesLayer name from discover (e.g., "root", "app-admin"). The key will be renamed in ALL locale files in this layer.
dryRunNoWhen true, returns a preview of what would be renamed without writing any files. Default: false.
newKeyYesNew dot-separated key path after renaming. Example: "common.buttons.save". Must not already exist.
oldKeyYesCurrent dot-separated key path to rename. Example: "common.actions.save".
projectDirNoAbsolute path to the Nuxt project root. Defaults to I18N_PROJECT_DIR, then server cwd. Example: "/home/user/my-app".
Behavior4/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. It discloses that the operation preserves values in every locale, which is a key behavioral trait. It also mentions dryRun for previewing without writing files, which is important for safety. However, it does not mention potential side effects like overwriting existing keys (though the schema says newKey must not exist) or whether the operation is reversible. Still, the description adds meaningful behavioral context beyond the schema.

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 two sentences, front-loaded with the core purpose, and includes a practical tip about dryRun. Every word earns its place; no fluff or repetition.

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

Completeness4/5

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

Given the tool's complexity (5 params, no output schema, no annotations), the description covers the essential purpose, scope, and safety preview. It doesn't explain return values, but since there's no output schema, that's a minor gap. The description is sufficient for an agent to understand the tool's function and when to use it.

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 schema description coverage is 100%, so the schema already documents all parameters well. The description adds minimal extra meaning beyond the schema, but it does reinforce the scope ('ALL locale files') and the dryRun behavior. Since the schema is comprehensive, a baseline of 3 is appropriate.

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

Purpose5/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: 'Rename/move a translation key across ALL locale files in a layer.' It specifies the verb (rename/move), the resource (translation key), and the scope (all locale files in a layer). It also distinguishes from siblings by emphasizing the cross-locale scope, which is unique among the listed tools.

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

Usage Guidelines4/5

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

The description provides clear context on when to use the tool: when renaming a key across all locale files. It also mentions the dryRun option to preview changes, which is a usage hint. However, it does not explicitly state when NOT to use it or mention alternatives (e.g., for single-file renames), but the context is clear enough for an agent to decide.

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/fabkho/the-i18n-kit'

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