smartling-cli
Run Smartling command-line operations to push files, pull translations, list projects, and manage glossaries, all from a single argument string.
Instructions
Run any smartling-cli command. Pass arguments as a single string exactly as you would on the command line.
Run --help on any command or subcommand to see all available options, e.g. "files push --help" or "mt translate --help".
FILE URI CONVENTION User files are mounted at /smartling inside the container. When pushing a file, ALWAYS specify an explicit argument that strips the /smartling prefix. This ensures the file URI stored in Smartling is a clean relative path (e.g. "en/strings.json"), not an absolute container path (e.g. "/smartling/en/strings.json"). Failing to do so causes double-path issues on download: pulled files would land at /smartling/smartling/... instead of /smartling/... When pulling files, ALWAYS pass --directory /smartling so translated files are written back into the mounted directory at the correct path.
Correct push: files push /smartling/en/strings.json en/strings.json Wrong push: files push /smartling/en/strings.json ← URI becomes /smartling/en/strings.json Correct pull: files pull '.json' -l es-ES --directory /smartling Wrong pull: files pull '.json' -l es-ES ← files land in /app, not /smartling
GLOBAL FLAGS (supported by all commands) -a, --account Override account ID -p, --project Override project ID
ACCOUNT ID Most commands require an account ID. Set the SMARTLING_ACCOUNT_ID environment variable in the Docker config to inject it automatically. If not set, pass -a explicitly. Note: SMARTLING_ACCOUNT_ID is not natively supported by the CLI — this MCP server injects it as a -a flag automatically when the env var is present.
PROJECTS projects list Display all projects in the account (fields: ID, ACCOUNT, NAME, LOCALE, STATUS) projects info Show details about the current project projects locales Display all target project locales with descriptions -s, --short Show locale IDs only --source Display only the source locale --format '' Custom output format, e.g. --format='{{if .Enabled}}{{.LocaleID}}{{end}} '
FILES files list [''] List files in project --short Show URIs only --format '' Custom output format files push [] Upload a file --type Override file type detection (e.g. json, plaintext) --directive Set file-level directive -b, --branch Add branch prefix to URI; use @auto to detect git branch files pull [''] Download translated files --source Download source file only -l Target locale (repeatable: -l es-ES -l fr-FR) files delete [''] Delete files (also accepts piped URIs via -) files rename Rename a file URI in the project files status Show translation progress for all files
MT (Machine Translation) mt detect '' Detect source language of files -s, --short Output locale code only --type Override file type detection --input-directory Source directory for input files --output table|json Output format mt translate '' Machine translate files to target locale(s) -l, --target-locale Target locale (repeatable: -l es-ES -l fr) --source-locale Source language (auto-detected if omitted) --input-directory Source directory for input files --output-directory Destination directory for translated files --type Override file type detection
GLOSSARIES glossaries list List glossaries in the account --name Filter by name --output simple|table|json Output format glossaries create Create a new glossary --locale Add a locale (repeatable) --description Optional description --verification-mode Enable verification mode --fallback-locale :<to[,to]> Fallback locale mapping (repeatable) glossaries export <uid|name> [file] Export glossary entries to a file --file-type csv|xlsx|tbx Export file format (required) --tbx-version v2|v3 TBX version (required when --file-type=tbx) --focus-locale Focus locale for the export --locale Include locale in export (repeatable) --skip-entries Skip glossary entries in the export --filter-query Filter: free-text query to match entries --filter-entry-state Filter: entry state to match --filter-locale Filter: locale ID (repeatable) --filter-entry-uid Filter: entry UID (repeatable) --filter-missing-translation-locale Filter: locale missing a translation --filter-present-translation-locale Filter: locale with a translation --filter-created-date Filter: created date (e.g. 2026-01-02T15:04:05Z) --filter-last-modified-date Filter: last modified date glossaries import <uid|name> Import glossary from CSV/XLSX/TBX --archive-mode Archive entries missing from the imported file --media-type Override media type detection
EXAMPLES projects list projects locales --short projects locales --format='{{if .Enabled}}{{.LocaleID}}{{end}} ' files list files list '.json' --short files push /smartling/en/strings.json en/strings.json --type json files push /smartling/en/strings.json en/strings.json files push '.md' --type plaintext -b feature-branch files push '.md' --branch '@auto' files pull '.json' -l es-ES -l fr-FR --directory /smartling files pull --source --directory /smartling files delete '**.json' files rename old/path.json new/path.json files status mt detect document.txt mt detect '.txt' --output json mt translate document.txt -l es-ES mt translate '.txt' -l es -l fr --output-directory /smartling/translations/ glossaries list glossaries list --name "Product Terms" glossaries create "Product Terms" --locale es-ES --locale fr-FR glossaries export "Product Terms" /smartling/glossary.xlsx --file-type xlsx glossaries export "Product Terms" /smartling/glossary.tbx --file-type tbx --tbx-version v3 glossaries export "Product Terms" /smartling/glossary.csv --file-type csv --locale es-ES glossaries import "Product Terms" /smartling/glossary.xlsx glossaries import "Product Terms" /smartling/glossary.xlsx --archive-mode
Full command reference: https://github.com/Smartling/smartling-cli/wiki/Projects-command-examples https://github.com/Smartling/smartling-cli/wiki/Files-command-examples https://github.com/Smartling/smartling-cli/wiki/MT-command-examples
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| args | Yes | Arguments to pass to smartling-cli, exactly as on the command line. |