Freestyle Docs

Freestyle / Docs

Freestyle CLI

Install and use the Freestyle CLI for local VM and Git workflows.

The Freestyle CLI is for one-off operations while developing, debugging, or automating local workflows. Use the SDK for application code, and use the CLI when you want to inspect or operate on VMs and Git repositories from a terminal.

Install

Run the CLI without installing it globally:

npx freestyle --help

Or install the package globally:

pnpm add -g freestyle
bun add -g freestyle
npm install -g freestyle
yarn global add freestyle

Then verify the command is available:

freestyle --help

Authenticate

Authenticate the CLI in one of two ways.

Log in through your browser with OAuth. This stores your credentials and sets a default team, so it’s the easiest option for local development:

freestyle login

Or set an API key directly, which is the better fit for CI and scripts:

export FREESTYLE_API_KEY="your-api-key"

If FREESTYLE_API_KEY is set, the CLI uses it. Otherwise it falls back to your freestyle login session.

VM Commands

Create a VM and run a command:

npx freestyle vm create --exec 'uname -a'

Start a temporary SSH session:

npx freestyle vm create --ssh --delete

See VM CLI for VM list, exec, SSH, and delete commands.

Git Commands

Create a repository:

npx freestyle git create

List repositories:

npx freestyle git list --limit 20

See Git CLI for repository lifecycle commands and native Git usage.

esc