# Statsig CLI ("Siggy")

> For AI agents: a documentation index is available at [/llms.txt](/llms.txt). Append `.md` to any page URL for markdown, or send `Accept: text/markdown`.

## How the Statsig CLI works

The Statsig CLI is a command-line interface that helps manage Feature Gates, Experiments, and Dynamic Configs within the Statsig platform. This tool lets you create, manage, and delete configs from the command line, and you can also use it within scripts.

## Why use the Statsig CLI

### Efficiency

The Statsig CLI provides a fast way to interact with Statsig, reducing the need for manual actions through the Console interface. It allows quick execution of tasks with simple commands.

### Automation

You can integrate the CLI into CI/CD pipelines to automate the management of Feature Gates and Experiments.

### Consistency

The CLI enables scriptable and repeatable actions, which promotes best practices and reduces the risk of human error.

## Installation

### Prerequisites

- Node.js (version 14 or higher)
- npm (Node Package Manager)

### Install and configure

1. Install the Statsig CLI using npm:

```bash
$ npm install -g @statsig/siggy
```

2. Check install

```bash
$ siggy --version
```

> **Info:**
>
> If you get a `command not found` error, add your node global bin folder to your path.
>
> Run `export PATH=$PATH:$(npm get prefix -g)/bin` to add the folder.
>
> If that doesn't work, run the CLI by prefixing `npx` in the command line:
>
> ```bash
> $ npx siggy --version
> ```

3. Configure the API keys by running:

```bash
$ siggy config -c <console-api-key>
$ siggy config -k <client-api-key>
```

> **Info:**
>
> Retrieve these keys from your Statsig project. Log in to Statsig Console at https://console.statsig.com and go to the Settings page (https://console.statsig.com/settings). Select the **Keys & Environments** panel within _Project Settings_, then copy both the Console API Key and Client API Key, and paste them in the Settings dialog.
>
> ![Statsig Console API keys configuration screen](https://docs.statsig.com/images/guides/sidecar-experiments/setup/754cc245-1821-4f75-a87d-08b536422587.png)

### Next steps: [Commands in CLI](https://docs.statsig.com/statsigcli/commands)
