Get Started
Package: @localess/cli — v3.0.0
Package: @localess/cli — v3.0.0
The @localess/cli package is the official command-line interface for the Localess headless CMS platform. It provides commands to authenticate with your Localess instance, synchronize translations, and generate TypeScript type definitions from your content schemas.
The CLI is a standalone tool — framework-agnostic and independent of the SDK packages. Install it once per project (or globally) regardless of which framework you use on the application side.
Requirements
- Node.js >= 20.0.0
Installation
# Install as a project dev dependency (recommended)
npm install @localess/cli -D
# Or install globally
npm install @localess/cli -gFeatures
- Authentication — Secure credential storage for CLI and CI/CD environments
- Translations — Push and pull translation files to/from your Localess space
- Type Generation — Generate TypeScript type definitions from your Localess content schemas for end-to-end type safety
Stored Files
| File | Description |
|---|---|
.localess/credentials.json | Stored login credentials (created by localess login) |
.localess/localess.d.ts | Generated TypeScript definitions (created by localess types generate) |
It is recommended to add
.localess/credentials.jsonto your.gitignoreto avoid committing sensitive credentials.
AI Coding Agents
This package ships a SKILL.md file that provides AI coding agents (GitHub Copilot, Claude Code, Cursor, and others) with accurate, up-to-date APIs, patterns, and best practices.
Reference it from your project's AGENTS.md:
## Localess
@node_modules/@localess/cli/SKILL.mdLicense
Astro
A dedicated @localess/astro package is on the roadmap. Until it ships, integrate Astro with Localess by fetching content with the framework-agnostic JavaScript client and (optionally) injecting the Visual Editor sync script.
Login
Authenticate with your Localess instance and store credentials securely.