@aicatch/cli
v1.4.1
Published
AICatch CLI — capture, analyze, export design tokens. Connects to an AICatch Engine.
Downloads
21
Maintainers
Readme
aicatch (CLI)
Client terminal officiel AICatch (protocol canon v1). Toutes les commandes passent par POST /api/v1/command.
Prérequis
- Engine AICatch accessible (self-hosted ou fourni par l'organisation).
- Node 18+.
Installation (public npm)
npm install -g @aicatch/cliOu avec npx :
npx @aicatch/cli pingInstallation (depuis le monorepo)
Depuis la racine :
npm install
npm run build -w @aicatch/protocol
npm run build -w @aicatch/cliConfiguration
| Variable | Description | Défaut |
|----------|-------------|--------|
| AICATCH_ENGINE_URL | URL de base de l'Engine | http://127.0.0.1:3846 |
| AICATCH_API_TOKEN | Token optionnel (header X-AICatch-Token) | — |
Commandes
aicatch ping
aicatch analyze --file <path> # png/jpg → affiche historyId + analyse
aicatch export --analysisId <id> --format css|json|figma [--out <file>]
aicatch history list [--limit N]
aicatch history get --id <entryId>
aicatch helpExemples
# Health check
aicatch ping
# App version: v1.2.0
# Protocol supported: 1.0
# Engine version: 1.2.0
# Engine URL: http://127.0.0.1:3846
# Token: disabled
# Analyser une image (le historyId sert pour export)
aicatch analyze --file ./screenshot.png
# Exporter en CSS dans un fichier
aicatch export --analysisId h-1234567890-abc --format css --out tokens.css
# Lister les 10 dernières entrées
aicatch history list --limit 10
# Récupérer une entrée
aicatch history get --id h-1234567890-abcErreurs
ECONNREFUSED: l'Engine n'est pas joignable (vérifier qu'il tourne sur le port 3846).UNAUTHORIZED: token requis (définirAICATCH_API_TOKENou désactiver le token côté Engine).HISTORY_NOT_FOUND: l'id d'historique n'existe pas (Engine redémarré ou mauvais id).
