Localazy MCP by usefulapi
Read Localazy projects, files, keys and glossary; submit translations, import keys, AI suggestions.
我該用這個嗎
品質與安全性
發現項目(3)
- HIGH
- MEDIUM在 localazy_submit_translation 中
- INFO在 localazy_submit_translation 中
根據工具定義與協定合規性的自動化分析。
上下文成本
這是每次將伺服器的工具載入模型上下文時所消耗的約略 token 數量。數量越高,可用於其他工作的注意力就越少。
安裝
一鍵安裝
將以下內容加入你的 `claude_desktop_config.json` 檔案:
{
"mcpServers": {
"localazy": {
"url": "https://localazy.usefulapi.io/mcp"
}
}
}遠端端點
https://localazy.usefulapi.io/mcpstreamable-http它能做什麼
工具清單
工具(17)
🟢localazy_list_projects(organization, languages)
List the Localazy projects the token can reach (a project token reaches one project): id, slug, name, source language, your role and visibility. Optionally add owning-organization limits (keys used/available, feature flags) and per-language progress counts (active, review, current, translated, sourceChanged, needImprovement). GET /projects.
輸入結構描述
{
"type": "object",
"properties": {
"organization": {
"description": "Add the owning organization's key usage and feature flags.",
"type": "boolean"
},
"languages": {
"description": "Add per-language translation progress.",
"type": "boolean"
}
},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_list_import_formats
List the file types Localazy can store strings as (type id, name, support for plurals/arrays/structured keys). The `json` type is what localazy_import_keys uses. GET /import/formats.
輸入結構描述
{
"type": "object",
"properties": {},
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_list_files(project)
List the files in a project (id, name, type, optional path). Use a file id with localazy_get_file_keys to read its strings. GET /projects/{projectId}/files.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
}
},
"required": [
"project"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_get_file_keys(project, file_id, lang, limit, next, ...)
Read the strings of one file in one language: key id, key path, current translation (a string, an array or a plural object keyed @one/@other). Pages of up to 1000 keys; pass `next` for the following page. Set extra_info for hidden/limit/deprecated/comment, no_content to list keys without text. Counts against the project's daily fetch cap. GET /projects/{projectId}/files/{fileId}/keys/{lang}.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"file_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "File id (from localazy_list_files)."
},
"lang": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Language code, e.g. en, cs, pt_BR, zh#Hans (as listed with localazy_list_projects languages=true)."
},
"limit": {
"description": "Items per page, 1-1000 (default 100 for keys; Localazy's own default for links is 1000).",
"type": "integer",
"minimum": 1,
"maximum": 1000
},
"next": {
"description": "Paging key: pass the previous reply's `next`. Absent `next` = last page.",
"type": "string",
"minLength": 1,
"maxLength": 500
},
"deprecated": {
"description": "Include deprecated keys.",
"type": "boolean"
},
"extra_info": {
"description": "Add hidden, limit, deprecated and comment to each key.",
"type": "boolean"
},
"no_content": {
"description": "Omit the translation text (keys only).",
"type": "boolean"
},
"unapproved": {
"description": "Include translations that are not yet approved.",
"type": "boolean"
}
},
"required": [
"project",
"file_id",
"lang"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_list_key_links(project, limit, next)
List links between duplicate source keys (key id, linked project id, linked key id), paged. Needs the Reviewer role. GET /projects/{projectId}/links.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"limit": {
"description": "Items per page, 1-1000 (default 100 for keys; Localazy's own default for links is 1000).",
"type": "integer",
"minimum": 1,
"maximum": 1000
},
"next": {
"description": "Paging key: pass the previous reply's `next`. Absent `next` = last page.",
"type": "string",
"minLength": 1,
"maxLength": 500
}
},
"required": [
"project"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_list_cdn_metadata(project)
List the Localazy CDN release tags of a project and the URL of each tag's metadata file (languages, plural rules). Needs the Manager role. GET /projects/{projectId}/cdn.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
}
},
"required": [
"project"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_get_import_progress(project, import_batch)
Progress of an import batch started with localazy_import_keys (pass its `import_batch`). The endpoint is used by Localazy's own API client but is not in the public docs yet, so the reply is returned as Localazy sends it. GET /projects/{projectId}/import/{importBatch}.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"import_batch": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "The `import_batch` returned by localazy_import_keys."
}
},
"required": [
"project",
"import_batch"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_get_tm_suggestions(project, key_id, to, from)
Translation Memory suggestions for one source key into a target language: earlier translations of the same text, with the project they came from. Free; no Localazy credits. GET /projects/{projectId}/keys/{keyId}/suggestions/tm.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"key_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Source key id (the `id` of a key from localazy_get_file_keys)."
},
"to": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Target language code."
},
"from": {
"description": "Source language code (default: the project's source language).",
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$"
}
},
"required": [
"project",
"key_id",
"to"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_get_mt_suggestions(project, key_id, to, from)
Machine Translation suggestions (one per engine) for one source key into a target language. Free: it does not consume Localazy credits (Localazy AI does; see localazy_translate_with_ai). The first request for a key can be slower. Nothing is saved. GET /projects/{projectId}/keys/{keyId}/suggestions/mt.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"key_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Source key id (the `id` of a key from localazy_get_file_keys)."
},
"to": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Target language code."
},
"from": {
"description": "Source language code (default: the project's source language).",
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$"
}
},
"required": [
"project",
"key_id",
"to"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_list_glossary(project)
All glossary terms of a project: id, description, translate/case-sensitive/exact-match flags and the term in each language. GET /projects/{projectId}/glossary.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
}
},
"required": [
"project"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🟢localazy_get_glossary_term(project, term_id)
One glossary term by id. GET /projects/{projectId}/glossary/{id}.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"term_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Glossary term id (from localazy_list_glossary)."
}
},
"required": [
"project",
"term_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴localazy_create_glossary_term(project, term, description, translate_term, case_sensitive, ...)
WRITE: add one term to a project's glossary (max 1,000 terms per project). Needs the Reviewer role. The term guides translators and Localazy AI from now on. POST /projects/{projectId}/glossary.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"term": {
"minItems": 1,
"maxItems": 100,
"type": "array",
"items": {
"type": "object",
"properties": {
"lang": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Language code, e.g. en, cs, pt_BR, zh#Hans (as listed with localazy_list_projects languages=true)."
},
"term": {
"type": "string",
"minLength": 1,
"maxLength": 500
}
},
"required": [
"lang",
"term"
]
},
"description": "The term in each language: [{lang, term}]. Include the project's source language."
},
"description": {
"description": "Explanation for translators.",
"type": "string",
"maxLength": 2000
},
"translate_term": {
"description": "true = the term is translated; false = keep it as is in every language.",
"type": "boolean"
},
"case_sensitive": {
"description": "Match case exactly.",
"type": "boolean"
},
"exact_match": {
"description": "Match the exact form only (no inflected forms).",
"type": "boolean"
}
},
"required": [
"project",
"term"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴localazy_update_glossary_term(project, term_id, term, description, translate_term, ...)
WRITE: replace the content of one glossary term (the term list and any flags you pass overwrite the old values). Needs the Reviewer role. Read the term first with localazy_get_glossary_term. PUT /projects/{projectId}/glossary/{id}.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"term_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Glossary term id (from localazy_list_glossary)."
},
"term": {
"minItems": 1,
"maxItems": 100,
"type": "array",
"items": {
"type": "object",
"properties": {
"lang": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Language code, e.g. en, cs, pt_BR, zh#Hans (as listed with localazy_list_projects languages=true)."
},
"term": {
"type": "string",
"minLength": 1,
"maxLength": 500
}
},
"required": [
"lang",
"term"
]
},
"description": "The term in each language: [{lang, term}]. Include the project's source language."
},
"description": {
"description": "Explanation for translators.",
"type": "string",
"maxLength": 2000
},
"translate_term": {
"description": "true = the term is translated; false = keep it as is in every language.",
"type": "boolean"
},
"case_sensitive": {
"description": "Match case exactly.",
"type": "boolean"
},
"exact_match": {
"description": "Match the exact form only (no inflected forms).",
"type": "boolean"
}
},
"required": [
"project",
"term_id",
"term"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴localazy_submit_translation(project, key_id, lang, value)
WRITE: set the translation of ONE source key in ONE target language. Reviewers, managers, owners and trusted translators set it as the current version (it overwrites the existing translation and goes live in the next download/CDN release); a translator's value is stored as a candidate for review. Values are stored as-is, with no placeholder, plural or length check, and the source language cannot be written. Check the reply's `stored`. POST /projects/{projectId}/keys/{keyId}/translations/{lang}.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"key_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Source key id (the `id` of a key from localazy_get_file_keys)."
},
"lang": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Target language code (not the source language)."
},
"value": {
"anyOf": [
{
"type": "string",
"maxLength": 20000
},
{
"minItems": 1,
"maxItems": 100,
"type": "array",
"items": {
"type": "string",
"maxLength": 20000
}
},
{
"type": "object",
"propertyNames": {
"type": "string",
"pattern": "^@?(zero|one|two|few|many|other)$"
},
"additionalProperties": {
"type": "string",
"maxLength": 20000
}
}
],
"description": "The translation: a string for a singular key, an array of strings for an array key, or an object keyed by plural form (zero, one, two, few, many, other; the @one/@other form that localazy_get_file_keys returns is accepted too) for a plural key, with at least one form. It must match the key's form."
}
},
"required": [
"project",
"key_id",
"lang",
"value"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴localazy_import_keys(project, language, keys, file_name, file_path, ...)
WRITE: add or update up to 50 string keys in ONE file, in ONE language (flat key -> text; use a key like "home.title" for the key name). Needs the Owner role. Nothing is deleted or deprecated, and Localazy does not overwrite existing current translations by default (translations identical to the source are skipped). By default the language is the project's source language, so this adds new source keys or changes the source text of existing ones (which marks their translations as changed); pass a different language to import translations, optionally through review with import_as_new. Imports count against the project's daily import cap (Free plan: 100/day). Returns an import_batch id for localazy_get_import_progress. POST /projects/{projectId}/import.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"language": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Language of the strings in `keys`, e.g. en. Use the project's source language to add source keys."
},
"keys": {
"type": "object",
"propertyNames": {
"type": "string",
"minLength": 1,
"maxLength": 512
},
"additionalProperties": {
"type": "string",
"maxLength": 5000
},
"description": "Key name -> text, 1-50 entries (e.g. {\"home.title\": \"Welcome\"})."
},
"file_name": {
"description": "Target file name in the project (default content.json). A new name creates a new file.",
"type": "string",
"minLength": 1,
"maxLength": 200
},
"file_path": {
"description": "Optional path of the file in the project, without the file name.",
"type": "string",
"minLength": 1,
"maxLength": 500
},
"import_as_new": {
"description": "Send the imported translations through the review process (recommended for translations you are unsure about).",
"type": "boolean"
}
},
"required": [
"project",
"language",
"keys"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴localazy_update_key_properties(project, key_id, comment, limit, hidden)
WRITE: change a source key's translator comment, maximum translation length, or hidden flag (fields you omit stay as they are). Needs the Manager role. It does not change texts and cannot deprecate or delete the key. PUT /projects/{projectId}/keys/{keyId}.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"key_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Source key id (the `id` of a key from localazy_get_file_keys)."
},
"comment": {
"description": "Context note for translators.",
"type": "string",
"maxLength": 2000
},
"limit": {
"description": "Maximum translation length; -1 removes the limit.",
"type": "integer",
"minimum": -1,
"maximum": 100000
},
"hidden": {
"description": "Hide the key from translators.",
"type": "boolean"
}
},
"required": [
"project",
"key_id"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}🔴localazy_translate_with_ai(project, from, to, items, fallback)
COSTS CREDITS: translate up to 10 texts with Localazy AI. Every call consumes Localazy credits from the account balance, by the number of translated words (see localazy.com/pricing); nothing is stored in the project, the translations are only returned. Limits: 10 requests/minute, 32 items and 16,384 characters per request. Beta. Needs the Owner role. POST /projects/{projectId}/ai.
輸入結構描述
{
"type": "object",
"properties": {
"project": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Localazy project id or slug (from localazy_list_projects)."
},
"from": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Source language code, e.g. en."
},
"to": {
"type": "string",
"pattern": "^[A-Za-z0-9_#-]{2,24}$",
"description": "Target language code, e.g. cs."
},
"items": {
"minItems": 1,
"maxItems": 10,
"type": "array",
"items": {
"type": "object",
"properties": {
"source": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"maxLength": 4000
},
{
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"type": "string",
"maxLength": 4000
}
}
],
"description": "Text, or an object of plural forms."
},
"key": {
"description": "Key name, as context.",
"type": "string",
"maxLength": 512
},
"comment": {
"description": "Context note.",
"type": "string",
"maxLength": 1000
},
"length_limit": {
"description": "Maximum characters of the translation.",
"type": "integer",
"minimum": 0,
"maximum": 32767
}
},
"required": [
"source"
]
},
"description": "1-10 texts to translate."
},
"fallback": {
"description": "Engine to use when Localazy AI is unavailable.",
"type": "string",
"enum": [
"google",
"deepl"
]
}
},
"required": [
"project",
"from",
"to",
"items"
],
"$schema": "https://json-schema.org/draft/2020-12/schema"
}社群
證據