Add a string and translate it
add_phraseUse 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.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"project": "<project>",
"key": "<key>"
},
"name": "add_phrase"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | New key, 1 to 256 characters | |
| model | No | Translation model id; defaults to gpt-6-luna | |
| value | No | Source text in the default locale, up to 2,000 characters; defaults to the key itself | |
| context | No | Note for the translator that disambiguates the string, up to 600 characters | |
| project | Yes | Project id or name |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| key | Yes | ||
| status | Yes | ||
| locales | Yes | ||
| project | Yes | ||
| defaultLocale | Yes | ||
| translationCount | Yes |