The Immich CLI
Immich has a command line interface (CLI) that allows you to perform certain actions from the command line.
Features
- Upload photos and videos to Immich
- Check server version
More features are planned for the future.
Google Photos Takeout
If you are looking to import your Google Photos takeout, we recommend this community maintained tool immich-go
Requirements
- Node.js 20 or above
- Npm
If you can't install node/npm, there is also a Docker version available below.
Installation (NPM)
npm i -g @immich/cli
NOTE: if you previously installed the legacy CLI, you will need to uninstall it first:
npm uninstall -g immich
Installation (Docker)
If npm is not available on your system you can try the Docker version
docker run -it -v "$(pwd)":/import:ro -e IMMICH_INSTANCE_URL=https://your-immich-instance/api -e IMMICH_API_KEY=your-api-key ghcr.io/immich-app/immich-cli:latest
Please modify the IMMICH_INSTANCE_URL and IMMICH_API_KEY environment variables as suitable. You can also use a Docker env file to store your sensitive API key.
Usage
immich
Usage: immich [options] [command]
Command line interface for Immich
Options:
-V, --version output the version number
-d, --config-directory <directory> Configuration directory where auth.yml will be stored (default: "~/.config/immich/", env:
IMMICH_CONFIG_DIR)
-u, --url [url] Immich server URL (env: IMMICH_INSTANCE_URL)
-k, --key [key] Immich API key (env: IMMICH_API_KEY)
-h, --help display help for command
Commands:
login|login-key <url> <key> Login using an API key
logout Remove stored credentials
server-info Display server information
upload [options] [paths...] Upload assets
help [command] display help for command