> ## Documentation Index
> Fetch the complete documentation index at: https://tryunsora.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# CLI quickstart

> Install the Unsora CLI, authenticate with your API key, and run your first AI generation from the terminal in under five minutes.

The [Unsora CLI](https://github.com/Shipped-Studio/unsora-cli) (`unsora`)
brings the full public API to your terminal: AI video, images, music,
voiceovers, thumbnails, influencer portraits, clipping, media uploads, and
social post scheduling.

## Install

```bash theme={null}
npm install -g unsora-cli
```

Requires Node.js 20+. Verify with:

```bash theme={null}
unsora --version
```

## Authenticate

Create an API key in the [Unsora app](https://app.tryunsora.com) under
**Settings → API Keys**, then:

```bash theme={null}
unsora auth login          # paste your uns_live_… key
unsora credits             # verify it works
```

Instead of saving the key you can set environment variables — useful in CI:

| Variable         | Description                      |
| ---------------- | -------------------------------- |
| `UNSORA_API_KEY` | API key — overrides saved config |
| `UNSORA_API_URL` | API base URL override            |

## First generation

```bash theme={null}
unsora image create --prompt "product photo of sneakers on white background"
```

The CLI queues the job, polls until it finishes, prints the output URL, and
downloads the file to the current directory (`unsora-image-<id>.png`).

Flags that work on every `create` command:

| Flag        | Effect                                |
| ----------- | ------------------------------------- |
| `--no-wait` | Queue the job and return immediately  |
| `--no-save` | Don't download the result file        |
| `-o <file>` | Choose the download path              |
| `--json`    | Machine-readable output for scripting |

## All commands

| Command                             | Description                                         |
| ----------------------------------- | --------------------------------------------------- |
| `unsora image …`                    | Image generation (nano-banana, Seedream, GPT Image) |
| `unsora video …`                    | Seedance 2.0 video generation                       |
| `unsora music …`                    | Mureka music (songs + BGM)                          |
| `unsora voiceover …`                | ElevenLabs Eleven v3 script-to-speech               |
| `unsora thumbnail …`                | YouTube-style 16:9 thumbnails                       |
| `unsora influencer …`               | AI influencer portraits                             |
| `unsora clip …`                     | AI clipping (long video → short clips)              |
| `unsora upload …`                   | [Upload media](/docs/cli/uploads) to your library        |
| `unsora accounts` / `unsora post …` | [Social posting](/docs/cli/social-posting)               |
| `unsora models --all`               | List every available model                          |
| `unsora upgrade`                    | Update the CLI                                      |

Run any command with `--help` for its full options.
