Catalog npm
Back to packageRELEASE DETAILS

0.2.0

npm

@0xlimao/traduora-cli

Modern Traduora CLI with TypeScript and client_credentials support

clii18ntraduora
Published19 Feb 2026
Direct dependencies10
Transitive dependenciesNot calculated

README

Current package documentation

@0xlimao/traduora-cli

A modern CLI and JavaScript SDK for Traduora with first-class client_credentials support.

  • CLI commands for project status, terms, translations, and exports
  • Interactive init flow to bootstrap credentials and default state
  • SDK package for scripting with both ESM and CommonJS
  • Docusaurus documentation with English, Traditional Chinese, Simplified Chinese, and Japanese

Table of Contents

Highlights

  • Uses term value as the user-facing key (instead of UUIDs)
  • Supports client_credentials as the default auth model
  • Supports interactive account login to create a project client automatically
  • Supports config file logic (json/js/ts) and environment variable fallback

Installation

From npm

pnpm add @0xlimao/traduora-cli

Global CLI install

pnpm add -g @0xlimao/traduora-cli

From source

git clone https://github.com/flyinglimao/traduora-cli.git
cd traduora-cli
pnpm install
pnpm build

Quick Start

Initialize interactively:

traduora init

Show help:

traduora --help
traduora project --help
traduora term --help
traduora translation --help
traduora export --help

Typical flow:

traduora project status
traduora translation use en_GB
traduora term add form.email.required
traduora translation add --term form.email.required --value "E-mail input is required"
traduora export --format jsonnested --output ./i18n/en_GB.json

CLI Usage

Init

traduora init --help

init supports:

  • Input API credentials directly (client_credentials), then prompt for project ID
  • Login with account/password, select a project, then create a project client (--role admin|editor|viewer)

Project

traduora project --help
traduora project status --help

project only provides status. It always uses the current project from state/config.

For term/translation/export commands, project is resolved from currentProjectId in state.

Term

traduora term --help
traduora term add --help
traduora term list --help
traduora term update --help
traduora term delete --help

Translation

traduora translation --help
traduora translation use --help
traduora translation add --help
traduora translation list --help
traduora translation update --help
traduora translation delete --help

Export

traduora export --help

Configuration

Priority order:

  1. Environment variables
  2. Config file
  3. CLI options

Supported config files:

  • traduora.config.json
  • traduora.config.ts
  • traduora.config.js
  • traduora.config.mjs
  • traduora.config.cjs

Supported environment variables:

  • TRADUORA_BASE_URL
  • TRADUORA_GRANT_TYPE
  • TRADUORA_CLIENT_ID
  • TRADUORA_CLIENT_SECRET
  • TRADUORA_USERNAME
  • TRADUORA_PASSWORD
  • TRADUORA_ACCESS_TOKEN

State (currentProjectId, currentLocale) is stored in .traduora.state.json.

JavaScript SDK

ESM

import { createApi } from "@0xlimao/traduora-cli";

const { api } = await createApi();
const terms = await api.listTerms("<projectId>");
console.log(terms);

CommonJS

const { createApi } = require("@0xlimao/traduora-cli");

(async () => {
  const { api } = await createApi();
  const terms = await api.listTerms("<projectId>");
  console.log(terms);
})();

For full method details, see the SDK TypeScript Reference in the docs site.

Documentation Site

Run locally:

cd docs
pnpm install
pnpm start

Development

pnpm install
pnpm build
pnpm typecheck
pnpm dev -- --help

Testing

Local Docker integration test (CLI + SDK against real Traduora instance):

pnpm test:e2e:local

See test instructions in test/README.md.

Release

  • npm publish is handled by GitHub Actions with npm Trusted Publishing (OIDC)
  • Docs are deployed to GitHub Pages by GitHub Actions

Contributing

Issues and pull requests are welcome:

License

MIT. See LICENSE.

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 10

Native requirements
10 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
jiti
Environment
{
  "local_name": "jiti",
  "alias": false,
  "peer_metadata": null
}
^2.6.1runtime
dotenv
Environment
{
  "local_name": "dotenv",
  "alias": false,
  "peer_metadata": null
}
^17.2.3runtime
commander
Environment
{
  "local_name": "commander",
  "alias": false,
  "peer_metadata": null
}
^14.0.1runtime
@inquirer/prompts
Environment
{
  "local_name": "@inquirer/prompts",
  "alias": false,
  "peer_metadata": null
}
^7.9.0runtime
tsx
Environment
{
  "local_name": "tsx",
  "alias": false,
  "peer_metadata": null
}
^4.20.5development
tsup
Environment
{
  "local_name": "tsup",
  "alias": false,
  "peer_metadata": null
}
^8.5.0development
typedoc
Environment
{
  "local_name": "typedoc",
  "alias": false,
  "peer_metadata": null
}
^0.28.17development
typescript
Environment
{
  "local_name": "typescript",
  "alias": false,
  "peer_metadata": null
}
^5.9.2development
@types/node
Environment
{
  "local_name": "@types/node",
  "alias": false,
  "peer_metadata": null
}
^24.3.0development
typedoc-plugin-markdown
Environment
{
  "local_name": "typedoc-plugin-markdown",
  "alias": false,
  "peer_metadata": null
}
^4.10.0development

Distribution files

1 collected
Distribution 1

Source distribution

Source file
Checksums from source
{
  "shasum": "ff60ed97921ea109d9ab404b5b8359afa1d119ad",
  "tarball": "https://registry.npmjs.org/@0xlimao/traduora-cli/-/traduora-cli-0.2.0.tgz",
  "fileCount": 12,
  "integrity": "sha512-oPWB6BkDpcQrA8yh+dfwDSQLFBsu3gx+j+AZHNjgulWOtO55AYEB+qNxxX+vfBkrDmGw4EzHDSiEJCKlPsIilw==",
  "signatures": [
    {
      "sig": "MEQCIB1Iz3griF7FD+8aqVvyW3QuzlbnXFcDR9AubMZ+bz+nAiB9tgPjRdEXNJRZVUnCUT0swYs8szoUF6lDLOcQMGJLYQ==",
      "keyid": "SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"
    }
  ],
  "attestations": {
    "url": "https://registry.npmjs.org/-/npm/v1/attestations/@0xlimao%2ftraduora-cli@0.2.0",
    "provenance": {
      "predicateType": "https://slsa.dev/provenance/v1"
    }
  },
  "unpackedSize": 139399
}

Repository

PENDING
flyinglimao/traduora-cli

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 09:04 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:9fbfed0d4bb6e5bab786e3dbca7f91790f72bfb613c636454545d34e3bb2ba38

Other collected versions

0.2.120 Feb0.1.018 FebView all collected versions →