Skip to main content
The varg CLI provides commands for authentication, rendering, and quick generation.

Installation

The CLI is included with the vargai package:
Or use directly with bunx:

Authentication Commands

Login

Sign in to varg.ai and save your API key:
Two modes:
  • Email — enter email, receive a 6-digit code, verify. Creates account + API key automatically.
  • API key — paste an existing key from the dashboard.
Credentials are saved to ~/.varg/credentials.

Logout

Clear saved credentials:

Check Balance

View your credit balance:

Top Up

Open the billing page to add credits:

Project Commands

Initialize Project

Set up a new varg project:
This runs login (if needed), installs the varg-ai Agent Skill, creates hello.tsx, output directories, and .gitignore.

Create Hello World

Generate the hello world starter:
Creates hello.tsx with a minimal working example.

Render Video

Render a TSX file to video:
Options: Examples:

Generation Commands

Run individual generation actions:

Generate Image

Generate Video

Generate Voice

Generate Music

Transcribe Audio

List Actions

Environment

The CLI reads VARG_API_KEY from:
  1. Environment variable: export VARG_API_KEY=varg_xxx
  2. .env file: VARG_API_KEY=varg_xxx
  3. Global credentials: ~/.varg/credentials

Output Formats

Default

Quiet (--quiet)

JSON (--json)