Skip to main content
Glama

Add or update translations

i18n_upsert_translations
Idempotent

Create or update locale keys with per-locale values in one call. Writes immediately, never deletes, reports conflicts, missing locales, and placeholder mismatches; supports overwrite and dry-run.

Instructions

Create or update keys in one call, with a value per locale. Writes immediately and never deletes keys. An existing value that differs is reported as a conflict unless overwrite:true. Reports missing locales and placeholder mismatches.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dryRunNoPreview only (default false).
entriesYes
overwriteNoReplace values that already differ (default false).
workspaceDirNoSub-directory of the workspace root to operate on. Usually omitted.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

A4.1/5.0
Behavior5/5

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

Annotations already declare write/idempotent/non-destructive, and the description adds genuinely new behavioral context on top: it writes immediately, never deletes keys, treats differing existing values as conflicts unless overwrite:true, and surfaces missing locales and placeholder mismatches. That is exactly the kind of consequence detail an agent needs before mutating translations.

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?

Four short sentences, each carrying distinct information (scope, write/delete behavior, conflict rule, validation reporting), with the write-immediately and never-deletes facts front-loaded. No filler.

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?

With no output schema, the description does describe what gets reported back (missing locales, placeholder mismatches), which covers the key return signal. Minor gaps remain around dryRun behavior and the exact shape of the conflict report, but nothing essential for correct invocation is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 75% and the schema already documents dryRun, overwrite, key format and the values map. The description adds meaning beyond the schema's terse overwrite text by explaining that a differing value is a conflict unless overwrite:true, clarifying the practical effect of the flag rather than restating it.

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?

States a specific verb pair (create/update) and resource (translation keys), plus the per-locale value model, so an agent can tell it apart from i18n_delete_keys and i18n_rename_key by the explicit 'never deletes keys' framing. It stops short of naming a sibling alternative directly, so it is clear but not maximally differentiated.

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

Usage Guidelines3/5

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

Usage is implied rather than stated: create or update keys in one call. The overwrite:true condition is spelled out, which helps routing within the tool, but there is no explicit when-to-use-this-vs-i18n_rename_key or i18n_get_translations guidance and no stated prerequisites.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.