Skip to main content

Installation

npm install -g @machine0/cli
The CLI is distributed as @machine0/cli on npm. After installation, the machine0 command is available globally.

Authentication

Log in via browser OAuth:
machine0 login
This opens your browser, you approve access, and the CLI stores a session token at ~/.machine0/auth-token. For automation, set the MACHINE0_API_TOKEN environment variable instead. Log out (revokes the token):
machine0 logout

Command structure

machine0 <command> [arguments] [flags]
Most commands follow the pattern machine0 <resource> <action>, with shortcuts for the most common operations:
ShortcutEquivalent
machine0 newCreate a VM
machine0 lsList VMs
machine0 getShow VM details
machine0 rmDestroy a VM
machine0 sshSSH into a VM

Full command reference

CommandDescription
Machines
new <vm>Create a VM
lsList VMs
get <vm>Show VM details
start <vm>Start a stopped VM
stop <vm>Stop a running VM
reboot <vm>Reboot a VM
rm [vm]Destroy a VM (--all for all)
ssh <vm> [command]SSH into a VM or run a command
update <vm>Rename or toggle proxy
provision <vm> <playbook>Run an Ansible playbook
sizesShow sizes and pricing
Images
images lsList images
images get <image>Show image details
images new <vm> <image>Snapshot a VM
images update <image>Update image settings
images rm [image]Delete an image (--all for all)
SSH Keys
keys lsList keys
keys get <key>Show key details
keys new <key>Add a key
keys update <key>Update key settings
keys rm <key>Delete a key
Account
loginLog in via browser
logoutLog out and revoke token
accountShow account details and balance
topupAdd funds to wallet
config getShow current configuration
config set KEY=VALUESet configuration values
Quick Launch
use openclawCreate an OpenClaw VM and SSH in