# CLI reference

The protect CLI provides a command-line interface for managing and protecting your workloads, zones, images, and more.

## Getting started [Permalink for this section](https://docs.edera.dev/reference/cli/#getting-started)

Select a version to view the specific CLI reference documentation:

CLI VERSION

[v1.10.0 (Latest)](https://docs.edera.dev/reference/cli/v1.10.0/) [v1.6.0](https://docs.edera.dev/reference/cli/v1.6.0/) [v1.3.0](https://docs.edera.dev/reference/cli/v1.3.0/) [v0.0.1](https://docs.edera.dev/reference/cli/v0.0.1/)

## Quick reference [Permalink for this section](https://docs.edera.dev/reference/cli/#quick-reference)

To get the version of protect you are running:

```bash
protect --version
```

For a complete list of commands and options, run:

```bash
protect --help
```

### Enabling shell autocompletion [Permalink for this section](https://docs.edera.dev/reference/cli/#enabling-shell-autocompletion)

Save yourself some keystrokes—enable tab-completion so you don’t have to remember every `protect` subcommand or flag.

The `protect completion` command prints out the script required to enable tab-completion for your shell.
Once set up, you can hit `protect` `TAB` to complete commands and flags.

#### Bash [Permalink for this section](https://docs.edera.dev/reference/cli/#bash)

```bash
# Add the completion script to your current session
source <(protect completion bash)

# To make this persistent across sessions
echo 'source <(protect completion bash)' >>~/.bashrc
```

#### Zsh [Permalink for this section](https://docs.edera.dev/reference/cli/#zsh)

```bash
# Enable completion
protect completion zsh > "${fpath[1]}/_protect"

# Or append it to your ~/.zshrc
echo 'source <(protect completion zsh)' >>~/.zshrc
```

Make sure `compinit` is enabled in your `.zshrc`:

```bash
autoload -Uz compinit
compinit
```

## Available commands [Permalink for this section](https://docs.edera.dev/reference/cli/#available-commands)

The CLI includes commands for:

- **zone** Manage the zones on Edera Protect
- **workload** Manage the workloads on Edera Protect
- **image** Manage the images on Edera Protect
- **network** Manage the network on Edera Protect
- **device** Manage the devices on Edera Protect
- **host** Manage the host of Edera Protect
- **completion** Output shell completion code for the specified shell

Last updated on 2025-10-02
