docs

Linguana CLI

The Linguana CLI creates complete multilingual apps from templates and connects apps to your Linguana account. It is published as @linguanahq/cli, installs a linguana executable, and is MIT licensed.

Use it to:

  • Create a standalone blog, SaaS landing page, or storefront in React, Vue, Svelte, SolidJS, or TanStack Start.
  • Try a working multilingual app in demo mode with no account and no Linguana API requests.
  • Sign in through your browser, then create or select an organization and project without copying IDs from the dashboard.
  • Write project linkage and environment credentials into ignored local files, and check the result with doctor.

Requirements

The CLI runs on Node.js 22.12 or later and also runs on Bun. It works with npm, pnpm, Yarn, and Bun projects.

Run it without installing, or install it globally to use the shorter linguana command:

terminal
npx @linguanahq/cli --help
terminal
pnpm dlx @linguanahq/cli --help
terminal
bunx @linguanahq/cli --help
terminal
npm install --global @linguanahq/cli
linguana --help

Examples in these docs use npx @linguanahq/cli. With a global install, replace it with linguana. Run --version to print the installed CLI version.

Quickstart: a demo app in one minute

terminal
npx @linguanahq/cli create app my-blog --framework solidjs --template blog --demo
cd my-blog
npm run dev

Open the local address Vite prints and switch between English, French, Spanish, and Arabic. Arabic switches the page to right-to-left. Demo mode bundles its translations and makes no Linguana API requests.

Run create app with no options to choose the template, framework, directory, package manager, and mode interactively:

terminal
npx @linguanahq/cli create app

Choose a template

TemplateAppIncluded interactions
blogElsewhereSix complete articles, Search and categories, Localized dates
saasRelayInteractive product preview, Monthly and annual pricing, Accessible demo forms
storefrontCommon GoodsEight original products, Search, sort, and filters, Persistent shopping cart

Registry version 0.1.0 includes 15 standalone apps. Every template supports react, vue, svelte, solidjs, tanstack-start. solid is accepted as an alias for solidjs. TanStack Start includes server rendering and locale hydration. All variants include local illustrations, responsive layouts, language persistence, and Arabic right-to-left support.

List templates and any hosted demos from your terminal:

terminal
npx @linguanahq/cli templates list

The new CLI and template code is MIT licensed. Demo forms do not send information, and checkout does not collect payments or create orders. Bring your own backend when you need those features. See Create an app for every option and the files each template contains.

Demo mode and connected mode

Demo modeConnected mode
Select with--demo--connect, or link later
Account requiredNoYes, with Owner or Admin access
Linguana API requestsNoneSign-in, project setup, and build uploads
Translations shownBundled English, French, Spanish, and ArabicYour project's published catalogs, with English source fallback
Files writtenlinguana.json with "mode": "demo"linguana.json with project IDs, plus an ignored .env.local

You can start in demo mode and connect later. Run npx @linguanahq/cli link inside the app; the CLI keeps your code and switches the app to your project. Connected templates stop using bundled demo catalogs, so they cannot conceal what your project actually publishes.

Creating or connecting an app never starts paid translation and never publishes a catalog. Those remain explicit actions in the dashboard.

Commands at a glance

CommandWhat it doesGuide
create app [directory]Scaffold a template app in demo or connected modeCreate an app
templates listList templates, frameworks, and hosted demosCreate an app
login / logout / whoamiManage the CLI account sessionSign in from the terminal
orgs list / projects listLook up organization and project IDsConnect an existing app
linkConnect the current app and write credentialsConnect an existing app
env pullRefresh credentials for an environmentConnect an existing app
doctorCheck SDK, Vite, linkage, session, and token setupCheck your setup

Every command accepts --json, --yes, and --api-url. See the command reference for each flag, output shape, exit code, and environment variable, and Scripts and CI for noninteractive use.

Supported frameworks

Templates, link, and doctor target Vite apps using React, Vue, Svelte, or SolidJS, and TanStack Start. These match the framework integrations built on @linguanahq/vite.

Next.js uses a separate integration, @linguanahq/next. There is no Next.js template yet, and link and doctor do not recognize Next.js. You can still use link to provision a project and credentials for a Next.js app; see Next.js apps.

How the CLI keeps credentials safe

  • The CLI account session is stored in your user configuration directory, never in the app. It is separate for each API origin and is written with owner-only file permissions.
  • The project build token goes only into an ignored .env.local (or .env.<environment>.local) file. The CLI refuses to write credentials into files tracked by Git or through symbolic links.
  • Browser variables receive only the public project ID, environment, API URL, and publishable key. Build tokens are never given a VITE_ prefix.
  • --json output and error messages never contain session or project tokens.
  • Authenticated requests require HTTPS (HTTP only for loopback development) and never follow redirects to another origin.

Did this page get you to a working result?

On this page

No Headings