# Smartling MCP

> Smartling (Translation Workflow API) automates complex localization tasks. Connect this server to manage projects, upload source files (JSON, XML), and create translation jobs—all through natural language commands. It lets you track job progress, add visual context for translators, and download completed translations without leaving your chat interface.

## Overview
- **Category:** collaboration
- **Price:** Free
- **Tags:** localization, translation-api, i18n, l10n, workflow-automation

## Description

Look, you're managing localization jobs in Smartling; you don't wanna be clicking through a bunch of different dashboards just to get strings translated. You need your AI client—your agent—to handle the whole workflow right here. This server lets you talk to Smartling using natural language commands and manage every part of the content process.

**Viewing and Inspecting Projects:**
You can start by getting an overview of everything you're working on. Use **`list_projects`** to see all the translation initiatives managed in your Smartling account. If you need the deep details on just one job, use **`get_project`** with a specific project ID; it pulls back all the status info you need.

**Preparing Source Content:**
Before a translator can do squat, they gotta have content. You send raw source files—think JSON, XML, or whatever resource bundle format you're using—with **`upload_file`**. It dumps that stuff right into the system for processing. But wait, it gets better. Translators need context to get it right; they can't just guess what a button says. You attach visual assets, like screenshots or HTML snippets, using **`upload_context`**. This helps your linguists write accurate localized strings because they see exactly how the text appears in the app.

**Managing Jobs:**
When you're ready to kick off the translation work, you use **`create_job`** to set up and initialize a brand new job inside an existing project. Once that job is live, and maybe you realize you missed some strings or need to add more specific content chunks—like legal disclaimers or product names—you don't restart everything. You just call **`add_content_to_job`**, which increments the running job with those extra segments. That keeps your whole process super tight for the linguists.

**Getting the Final Output:**
The last thing you wanna do is manually download files from a website. When the translations are done, you use **`download_translated_file`**. You specify the locale and the content set, and boom—it retrieves the final translated file output right into your environment. It's that simple.

Basically, it handles everything: finding what projects exist (**`list_projects`**), digging deep on a specific project (**`get_project`**), feeding the raw files (**`upload_file`**), giving translators pictures to look at (**`upload_context`**), kicking off the work cycle (**`create_job`**), adding more strings mid-stream (**`add_content_to_job`**), and finally, grabbing the finished goods (**`download_translated_file`**). It keeps your whole localization pipeline running without you ever leaving your chat interface.

## Tools

### add_content_to_job
Adds specific content segments to an existing translation job in a project.

### create_job
Sets up and initializes a brand new translation job within a specified project.

### download_translated_file
Retrieves the final translated file output for a given locale and content set.

### get_project
Fetches detailed status information for one specific Smartling project ID.

### list_projects
Returns a list of all available translation projects managed in your Smartling account.

### upload_context
Attaches visual assets or UI context (like screenshots) to assist translators with localization accuracy.

### upload_file
Sends source content files, such as JSON or XML resource bundles, into the translation system.

## Prompt Examples

**Prompt:** 
```
List all my Smartling projects.
```

**Response:** 
```
I've retrieved your projects. You have access to 'Mobile App Localization' (ID: a1b2c3d4) and 'Web Platform' (ID: e5f6g7h8). Which one would you like to manage?
```

**Prompt:** 
```
Create a new translation job called 'Spring Release' in project a1b2c3d4.
```

**Response:** 
```
The job 'Spring Release' has been successfully created in project a1b2c3d4 with UID 'job_98765'. You can now start adding content to it.
```

**Prompt:** 
```
Download the French translation for 'strings.json' from project a1b2c3d4.
```

**Response:** 
```
I've downloaded the 'fr-FR' version of 'strings.json'. The content is ready for use. Would you like me to display the translated strings?
```

## Capabilities

### List and Inspect Projects
View all Smartling projects and retrieve detailed information about a specific project using `list_projects` or `get_project`.

### Upload Source Content
Send raw content files (JSON, XML, etc.) to the system for translation processing via `upload_file`.

### Provide Visual Context
Attach screenshots or HTML context using `upload_context`, helping translators write accurate localized strings.

### Initiate Translation Jobs
Create a new translation job within an existing project using the `create_job` tool.

### Add Content to Job
Incrementally add more specific content segments to a running job using `add_content_to_job`.

### Download Completed Translations
Retrieve the final, translated output file for a given locale with `download_translated_file`.

## Use Cases

### Need to localize a new mobile feature?
A developer needs to translate 'settings.json' for the next release. They start by running `list_projects` to find the 'Mobile App Localization' ID. Then, they use `upload_file` with the new JSON, followed by `create_job`. This sets up a clean workflow and gets the process started.

### A UI element needs better context for translators.
The content team finds that key phrases are being mistranslated because linguists don't know how they look in the app. They use `upload_context` to attach a screenshot of the 'Login Screen'. This visual guide makes sure all future translations are accurate and consistent.

### I need to update content for an ongoing campaign.
The marketing team needs to inject new promotional text into a live project. Instead of starting from scratch, they use `get_project` to check the current job status, and then call `add_content_to_job` to append the fresh copy without disrupting the rest of the work.

### The build is ready, time to download translations.
After monitoring a job's progress via `get_project`, and confirming it's marked 'Complete', the agent runs `download_translated_file` for the German locale. The resulting file is immediately available for the CI/CD pipeline.

## Benefits

- Stop manually tracking job progress. Use `get_project` to pull the real-time status of a specific localization initiative into your conversation, instead of logging into a separate dashboard.
- Never lose source files again. When you run `upload_file`, the system accepts JSON, XML, and HTML formats, handling resource bundles directly from your agent.
- Improve translator accuracy immediately. Running `upload_context` lets you attach screenshots or UI examples alongside your strings, so they know exactly where the text lives in the app.
- Build structured workflows: You can sequence commands—run `list_projects`, then `create_job`, and finally `add_content_to_job`—all without leaving your IDE or chat window.
- Get translations fast. Once work is done, simply call `download_translated_file`. The output file arrives ready for integration into your build pipeline.

## How It Works

The bottom line is you use your AI client to sequence calls across these tools: Discovery -> Preparation -> Execution -> Output.

1. First, run `list_projects` to find the ID of the project you need to work on. Then, use `get_project` to confirm its current status.
2. Next, upload all source data using `upload_file` and add visual guides with `upload_context`. After that, run `create_job` to start the translation process.
3. Finally, monitor progress by checking the job details. When finished, use `download_translated_file` to get the output.

## Frequently Asked Questions

**How do I find all my projects using Smartling (Translation Workflow API)?**
Run `list_projects`. This tool quickly retrieves a list of every translation project you've set up in your account, giving you the IDs needed to work on them.

**Can I upload files and context separately with Smartling (Translation Workflow API)?**
Yes. You use `upload_file` for structured source code like JSON or XML bundles, and then use `upload_context` specifically for visual aids like screenshots.

**What is the difference between creating a job and adding content? (Smartling (Translation Workflow API))**
Use `create_job` to initialize the container—it makes the workspace available. Then, use `add_content_to_job` to put specific resources or strings into that already running job.

**After translations are done, how do I get them? (Smartling (Translation Workflow API))**
You call `download_translated_file`. This tool pulls the final output file for a specific language and project directly into your agent's output.

**How do I authenticate and connect my AI agent to Smartling using this server?**
You must provide your Smartling User Identifier and User Secret credentials when setting up the connection. The agent uses these keys to authorize all subsequent calls, ensuring only your account can manage jobs.

**If I use `add_content_to_job` but include an incorrect Job ID, what happens?**
The server will immediately reject the request and return a specific error code. This tells you that the job doesn't exist or that your agent lacks permission to modify it.

**How can I use `get_project` to check which locales are available for translation?**
The tool returns comprehensive metadata for a specific Smartling project. Look for the 'locales' array in the response payload; this lists every language code currently attached to that project.

**When I call `upload_file`, how do I ensure content is authorized right away?**
The file upload tool accepts an authorization flag in the payload. Including this parameter forces Smartling to automatically authorize the content upon successful upload, skipping manual review steps.

**Can I upload a file and have it immediately ready for translation?**
Yes! When using the `upload_file` tool, set the `authorize` parameter to true. This will automatically authorize the content for translation in your project.

**How do I group multiple files into a single translation task?**
First, use `create_job` to create a new translation job. Then, use `add_content_to_job` for each file URI you want to associate with that specific job UID.

**Can I provide visual context to help translators?**
Absolutely. Use the `upload_context` tool to send visual references (like screenshots or HTML) to your project, ensuring higher translation quality.