npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

xliff-deepl

v0.1.0

Published

Translate XLIFF with DeepL and your glossaries

Readme

XliffDeepl

XliffDeepl is a command-line tool that translates XLIFF 2.1/2.2 files with DeepL, using TypesXLIFF to read the file's own srcLang/trgLang and validate them against the languages DeepL supports. Glossaries can be uploaded to DeepL ahead of time and reused across translation runs.

Installation

Option 1: Install globally with npm

npm install -g xliff-deepl

Option 2: Clone and build from source

git clone https://github.com/maxprograms-com/XliffDeepl.git
cd XliffDeepl
npm install
npm run build

Then run:

./dist/cli.js translate -i <path-to-file.xlf> -o <path-to-output.xlf> -k <apiKey>

Usage

A DeepL API key is required for every command except glossary list. Pass it with -k/--key, or set it once as an environment variable:

export DEEPL_API_KEY=<your-api-key>

Translate a file

xliff-deepl translate -i <input.xlf> -o <output.xlf>

Source and target languages are read from the XLIFF file itself, not passed on the command line. translate rejects files that aren't XLIFF 2.1 or 2.2, and rejects languages DeepL doesn't support.

Apply a previously uploaded glossary, and/or set formality:

xliff-deepl translate -i <input.xlf> -o <output.xlf> -g <glossaryName> -f more

The glossary's source/target languages must match the XLIFF file's; translate checks this against DeepL directly before starting.

For help:

xliff-deepl translate -h

Output:

Usage:
  xliff-deepl translate -i <input.xlf> -o <output.xlf> -k <apiKey> [options]

Required:
  -i, --input <file>        XLIFF file to translate
  -o, --output <file>       Where to write the translated XLIFF file
  -k, --key <apiKey>        DeepL API key (or set DEEPL_API_KEY environment variable)

Options:
  -g, --glossary <name>     Name of a glossary previously uploaded with "glossary upload"
  -f, --formality <value>   `default` | `more` | `less` | `prefer_more` | `prefer_less`
  -h, --help                Show this help message

Manage glossaries

Glossaries live on DeepL's servers; XliffDeepl keeps a local record of their names and ids in ~/.cache/XliffDeepl/glossaries.json so you can refer to them by name.

xliff-deepl glossary upload --name legal-terms --source en --target de --file terms.csv
xliff-deepl glossary list
xliff-deepl glossary delete --name legal-terms
  • upload reads a CSV file of source-term,target-term pairs, creates the glossary on DeepL, and records it locally. It refuses to reuse a name that's already tracked.
  • list only reads the local record, no network access, no API key needed.
  • delete removes the glossary from DeepL first, then from the local record.

For help:

xliff-deepl glossary -h

License

Eclipse Public License 1.0, see LICENSE for details.