CLI Overview
The vfrog CLI provides fast, scriptable access to the vfrog platform from the command line. Use it to manage projects, upload datasets, run SSAT workflows, train models, run inference, and export data — all without the web UI.
Installation
Download the binary for your platform:
# macOS (Apple Silicon)
curl -L https://github.com/vfrog-ai/vfrog-cli/releases/latest/download/vfrog-darwin-arm64 -o vfrog
chmod +x vfrog && sudo mv vfrog /usr/local/bin/
# macOS (Intel)
curl -L https://github.com/vfrog-ai/vfrog-cli/releases/latest/download/vfrog-darwin-amd64 -o vfrog
chmod +x vfrog && sudo mv vfrog /usr/local/bin/
# Linux (AMD64)
curl -L https://github.com/vfrog-ai/vfrog-cli/releases/latest/download/vfrog-linux-amd64 -o vfrog
chmod +x vfrog && sudo mv vfrog /usr/local/bin/
Windows: Download vfrog-windows-amd64.exe from the latest release, rename it to vfrog.exe, and add its directory to your PATH.
Verify the installation:
vfrog version
Environment Binaries
Each release includes binaries preconfigured for different environments:
| Binary | Environment | API URL |
|---|---|---|
vfrog | Production | https://api.vfrog.ai |
vfrog-staging | Staging | https://api-staging.vfrog.ai |
vfrog-dev | Development | https://api-dev.vfrog.ai |
Credentials are baked into each binary at build time. You can run multiple environment binaries side-by-side without conflicts.
Authentication
Log in with your vfrog platform credentials:
# Interactive login (prompts for email and password)
vfrog login
# Non-interactive login (for scripts and CI/CD)
vfrog login --email user@example.com --password "$VFROG_PASSWORD"
Authentication tokens are stored locally and refresh automatically when expired.
The CLI uses email/password authentication, which is separate from the API key authentication used by the REST API. See the API authentication guide for API key setup.
Configuration
The CLI uses a hierarchical context system. Most commands require an active organisation and project:
Organisation → Project → Object
Set your context after logging in:
# List and set organisation
vfrog organisations list
vfrog config set organisation --organisation_id <org_id>
# List and set project
vfrog projects list
vfrog config set project --project_id <project_id>
# List and set object (needed for iteration commands)
vfrog objects list
vfrog config set object --object_id <object_id>
View the current configuration:
vfrog config show
Changing the active organisation automatically clears the active project. Changing the active project automatically clears the active object.
Context Requirements
| Commands | Requires |
|---|---|
projects | organisation_id |
dataset_images, objects, iterations, export | organisation_id + project_id |
iterations list, iteration number lookups | object_id |
Config File Locations
Each environment binary uses a separate config file:
| Binary | Config File |
|---|---|
vfrog (production) | ~/.vfrog/config-production.json |
vfrog-staging | ~/.vfrog/config-staging.json |
vfrog-dev | ~/.vfrog/config-dev.json |
On Windows, config files are stored in %USERPROFILE%\.vfrog\.
API Key Precedence
For inference commands, API keys are resolved in this order:
--api-keyflagVFROG_API_KEYenvironment variableapi_keyin the config file
Global Flags
| Flag | Type | Description |
|---|---|---|
--json | boolean | Output in JSON format (supported by all commands) |
--config | string | Custom config file path |
-h, --help | boolean | Help for any command |
Shell Autocompletion
The CLI supports autocompletion for bash, zsh, fish, and PowerShell:
# Zsh (add to ~/.zshrc)
source <(vfrog completion zsh)
# Bash (add to ~/.bashrc)
source <(vfrog completion bash)
# Fish
vfrog completion fish > ~/.config/fish/completions/vfrog.fish
# PowerShell
vfrog completion powershell | Out-String | Invoke-Expression
Next Steps
- CLI Workflows — End-to-end examples for common tasks
- CLI Reference — Complete command reference
- Quickstart — Make your first API call