Getting Started with the Structure CLI

In addition to the web interface, Structure has a command-line interface (CLI) that makes it easy to use Structure through the terminal. With the Structure CLI package, you can create and deploy applications, manage their lifecycles, view their logs, and more.

Installing the CLI

Currently, the Structure CLI is supported on macOS and Linux. Structure is installable through the pip package manager by running:
sudo pip install structure
If the install command doesn't work, try using the --ignore-installed flag:
sudo pip install --ignore-installed structure
If you don't have pip installed, you can install it on macOS by running:
sudo easy_install pip

Getting started with the CLI

Once you've installed the Structure package, you'll need to log in:
structure login
Note: The CLI will issue you an API token that will be saved locally on your computer to authenticate you for future commands. On macOS, the token is saved in the ~/.netrc file. It's important to keep this token safe to prevent others from accessing your Structure account.
Finally, run structure help to see the available commands!

Updating the CLI

We'll regularly update the Structure package with new features and fixes. You can update to the latest version with pip:
sudo pip install --upgrade structure