Getting Started

CLI Reference

4 min read

The FlagPilot CLI lets you manage environments, toggle flags, and inspect evaluation state directly from your terminal — no dashboard required.

Installation

Install the @flagpilot/cli package globally:

Terminal
npm install -g @flagpilot/cli

Log in to FlagPilot

Authenticate with your API key. Run the login command and paste your key when prompted:

Terminal
flagpilot login

Available commands

CommandDescription
flagpilot loginAuthenticate the CLI with your API key
flagpilot flags listList all flags in the current project
flagpilot toggle <key>Enable or disable a flag immediately
flagpilot flags create <key>Scaffold a new flag configuration
flagpilot flags delete <key>Permanently delete a flag
flagpilot env listShow all configured environments
flagpilot env switch <env>Switch the active environment context
flagpilot auditView the audit log for flag changes

Deploy your project

A typical workflow for shipping a new feature behind a flag:

Terminal
# 1. Create the flag
flagpilot flags create checkout-redesign

# 2. Verify it's off by default
flagpilot flags list

# 3. Enable for yourself first
flagpilot toggle checkout-redesign --env development

# 4. Enable in production when ready
flagpilot toggle checkout-redesign --env production
Was this page helpful?