MCP.so
登录

MCP I18n Extractor

@martincik

关于 MCP I18n Extractor

MCP server to help with i18n translations

基本信息

分类

其他

许可证

MIT license

运行时

html

传输方式

stdio

发布者

martincik

配置

暂无标准配置

该服务器的 README 中没有可解析的 MCP 配置块,请前往代码仓库查看安装说明。

代码仓库

工具

未检测到工具

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is MCP I18n Extractor?

MCP I18n Extractor is an MCP server that extracts i18n (internationalization) strings from JavaScript/TypeScript source files and outputs them as structured JSON files. It is designed for developers working on multilingual applications who need to automate the initial extraction of translation keys from their codebase.

How to use MCP I18n Extractor?

Install the npm package (@access-intelligence/mcp-i18n), then configure your MCP client to use the server. The server exposes a single tool operation, extract_i18n, which requires a sourcePath (path to the JS/TS file) and a targetPath (path for the output JSON).

Key features of MCP I18n Extractor

  • Extracts i18n strings from direct object exports (export default { ... })
  • Preserves nested objects and arrays in the output JSON
  • Handles template strings with variable interpolation
  • Supports strings, numbers, booleans, null, and undefined
  • Merges with existing JSON files instead of overwriting
  • Replaces source files with a configurable migration message (can be disabled)

Use cases of MCP I18n Extractor

  • Automatically generate a JSON translation file from a single JS/TS i18n module
  • Migrate a codebase by replacing old i18n source files with a warning placeholder
  • Integrate i18n extraction into a CI/CD pipeline via MCP client automation

FAQ from MCP I18n Extractor

What kind of i18n structures can it extract?

It extracts strings from direct object exports (e.g., export default { key: "value" }) and supports nested objects, arrays, template strings with variables, and basic data types (string, number, boolean, null, undefined).

Does the tool overwrite existing translation files?

No. When the target JSON file already exists, the extracted strings are merged into it, preserving any existing keys.

Can I prevent the source file from being replaced?

Yes. Set the environment variable DISABLE_SOURCE_REPLACEMENT to 'true' to keep the original source file intact after extraction.

What runtime or dependencies does it require?

It is an npm package that runs on Node.js. The README does not specify a minimum Node version but lists npm test for testing, implying a typical Node environment.

How do I customize the warning message added to replaced source files?

Use the WARNING_MESSAGE environment variable to set a custom string that will be written into the source file after extraction (if not disabled).

评论

其他 分类下的更多 MCP 服务器