Octopus Deploy Documentation

The Octopus Command Line (CLI)

Last updated

The Octopus CLI is a command line tool that builds on top of the Octopus Deploy REST API.

We provide a number of ways to install The Octopus CLI onto your machine:


octo supports the following commands:

General Usage

All commands take the form of:

octo <command> [<options>]

You can see a list of commands using:

octo help

And you can get help for a specific command using:

octo help <command>
octo <command> --help

Arguments are not case sensitive and can take the following forms:

--project OctoFX                # Space between argument name and value
--project=OctoFX                # Equal sign between argument name and value
--project "OctoFX Web Site"     # Argument values with spaces need to be quoted
"--project=OctoFX Web Site"     # If using equals, quote both the name and value, not just the value

All commands require you to pass the URL of the Octopus Server's API endpoint, and an API key which is used to authenticate you.

octo ... --server http://your-octopus-server/ --apiKey API-ABCDEF123456

Most commands also support JSON formatted output.

Creating API keys
Learn about how to create an API key.

The Octopus CLI is built and maintained by the Octopus Deploy team, but it is also open source. You can view the Octopus CLI project on GitHub, which leans heavily on the Octopus Clients library.

The server url, api key, username and password can be set as the environment variables OCTOPUS_CLI_SERVER, OCTOPUS_CLI_API_KEY, OCTOPUS_CLI_USERNAME and OCTOPUS_CLI_PASSWORD respectively. Values set via command line arguments take precedence over environment variables.

Welcome! We use cookies and data about how you use our website allow us to improve the website and your experience, and resolve technical errors. Our website uses cookies and shares some of your data with third party analytics companies for these purposes.

If you decline, we will respect your privacy. A single cookie will be used in your browser to remember your preference.