Skip to main content
shipi18n logo|Documentation

CLI Commands

Complete reference for the v2 CLI.

translate

shipi18n translate <input> [options]

<input> is the source locale file, for example locales/en.json.

Options

OptionDefaultDescription
-t, --target <languages>es,frComma-separated target language codes
-s, --source <language>enSource language code
-o, --output <dir>./localesDirectory the translated files are written to
-p, --provider <name>anthropicanthropic or openai
--api-key <key>env varPass the key explicitly instead of via the environment
--model <model>provider defaultOverride the model
-i, --incrementaloffReuse existing output files; only translate new or missing keys

Examples

# three languages, default provider
shipi18n translate locales/en.json --target es,fr,de

# only what changed since last time
shipi18n translate locales/en.json --target es,fr --incremental

# OpenAI, custom output directory
shipi18n translate src/i18n/en.json -p openai -t ja,ko -o src/i18n

# translate from German instead of English
shipi18n translate locales/de.json --source de --target en

Removed in v2

shipi18n keys and shipi18n config managed a hosted Shipi18n account. There is no account any more, so both commands are gone. Provider credentials live in your environment instead.