Skip to main content
Glama

Add a string and translate it

add_phrase
Destructive

Use this when someone asks to add a new string or key to their app's translations. Returns the created key with one machine translation per configured locale, made from the source text in the default locale. A key that already exists returns already-exists and is left unchanged. Not for changing an existing translation.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyYesNew key, 1 to 256 characters
modelNoTranslation model id; defaults to gpt-6-luna
valueNoSource text in the default locale, up to 2,000 characters; defaults to the key itself
contextNoNote for the translator that disambiguates the string, up to 600 characters
projectYesProject id or name

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
keyYes
statusYes
localesYes
projectYes
defaultLocaleYes
translationCountYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • changedInput schema / properties / context / description
      Previous value: -"Optional context that helps translators disambiguate the phrase."New value: +"Note for the translator that disambiguates the string, up to 600 characters"
    • changedInput schema / properties / key / description
      Previous value: -"New exact phrase key"New value: +"New key, 1 to 256 characters"
    • changedInput schema / properties / model / description
      Previous value: -"Translation model to use. Defaults to gpt-6-luna."New value: +"Translation model id; defaults to gpt-6-luna"
    • changedInput schema / properties / project / description
      Previous value: -"Project name (slug) to add the key to"New value: +"Project id or name"
    • changedInput schema / properties / value / description
      Previous value: -"Source value in the default locale. Omit to use the key itself."New value: +"Source text in the default locale, up to 2,000 characters; defaults to the key itself"
  2. Changed1 schema field changed
    • changedInput schema / properties / model / description
      Previous value: -"Translation model to use. Defaults to gpt-5.6-luna."New value: +"Translation model to use. Defaults to gpt-6-luna."
  3. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already flag destructiveHint=true and idempotentHint=false, and the description adds genuinely non-obvious behavior: the collision case returns already-exists and leaves the key unchanged, and creation auto-generates one translation per configured locale from the default-locale source text. It does not explain why the operation is flagged destructive or whether generated translations overwrite anything, leaving a small gap.

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?

Three tight sentences: trigger, behavior/return, and exclusion. The most decision-relevant information (when to use it and what it returns) is front-loaded with no filler.

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

Completeness5/5

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

Return values are covered by an output schema and the safety profile by annotations, so the description's remaining job is trigger conditions and edge behavior — both supplied via the already-exists no-op rule. An agent has everything needed to call this correctly.

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 every parameter (key length, model default, value default, context, project) is already documented in the schema. The description restates the value/model semantics at a high level ("source text in the default locale") without adding syntax or format detail, so the baseline 3 applies.

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?

States a specific verb+resource (add a string/key to translations) and summarizes the return payload: the created key plus one machine translation per configured locale. It is clearly distinguishable from update_phrase and delete_phrase, and the sibling set confirms this is the creation path.

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?

"Use this when someone asks to add a new string or key" gives a clear trigger condition, and "Not for changing an existing translation" supplies an explicit exclusion. It stops short of naming update_phrase as the alternative for that case, so the routing is implied rather than stated.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources