JSON Translations MCP Server

by schmkls

174 downloads Not rated yet MIT
GitHub

About

# JSON Translations MCP Server A Model Context Protocol (MCP) server for updating and retrieving translations in JSON files. ## Overview This MCP server provides two tools: `update-translation` and `get-translation`. These tools allow you to update and retrieve translations in JSON files for different languages. It's…

Details

License
MIT

Explore

- Update translations in JSON files using a dot-notation path
- Retrieve translations from JSON files using a dot-notation path
- Support for multiple language files
- Preserves JSON structure and formatting
- Handles nested translation keys
- Graceful error handling
- Optional default translations path

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name JSON Translations MCP Server
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

- Node.js or Bun

json-translations-mcp-server --path /path/to/translations

bun start --path /path/to/translations

{
  "mcpServers": {
    "json-translations-mcp-server": {
      "command": "json-translations-mcp-server",
      "args": ["--path", "/path/to/translations"]
    }
  }
}

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "json translations mcp server": {
            "JSON-translations-MCP-server": {
                "command": "bun",
                "args": [
                    "run",
                    "build"
                ]
            }
        }
    }
}

McpServers

{
    "JSON-translations-MCP-server": {
        "command": "bun",
        "args": [
            "run",
            "build"
        ]
    }
}

A Model Context Protocol (MCP) server for updating and retrieving translations in JSON files.

Overview

This MCP server provides two tools: update-translation and get-translation. These tools allow you to update and retrieve translations in JSON files for different languages. It's designed to work with nested translation structures where keys are separated by dots.

Features

- Update translations in JSON files using a dot-notation path
- Retrieve translations from JSON files using a dot-notation path
- Support for multiple language files
- Preserves JSON structure and formatting
- Handles nested translation keys
- Graceful error handling
- Optional default translations path

Tool: update-translation

Parameters

- translationId - The translation ID using dot notation (e.g., "common.buttons.save")
- language - The language code for the translation file (e.g., "sv", "en", ...)
- path - (Optional) Path to the folder containing translation files. If not provided, the default path set during server initialization will be used.
- translation - The new translation value to be inserted

Example

{
  "translationId": "common.buttons.save",
  "language": "en",
  "translation": "Save"
}

Tool: get-translation

Parameters

- translationId - The translation ID using dot notation (e.g., "homepage.welcome.message")
- language - The language code for the translation file (e.g., "sv", "en", ...)
- path - (Optional) Path to the folder containing translation files. If not provided, the default path set during server initialization will be used.

Example

{
  "translationId": "homepage.welcome.message",
  "language": "en"
}

Setup and Usage

Prerequisites

- Node.js or Bun

Installation

From npm
npm install -g json-translations-mcp-server
From source

1. Clone the repository
2. Install dependencies:

```bash
bun install

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.