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

# Inworld CLI

> Send chat completions, list models, and manage API keys from your terminal

The [Inworld CLI](https://www.npmjs.com/package/@inworld/cli) is the fastest way to use Inworld from your terminal — authenticate, create API keys, synthesize speech, generate audiobooks, transcribe audio, chat through the LLM Router, and run the Inworld MCP server. It's a single global package with no project setup or SDK installation required.

It's also built for AI coding agents: an agent can log in, mint an API key, and call Inworld APIs directly from the shell — no MCP server configuration needed.

```bash theme={"system"}
npm install -g @inworld/cli
```

Requires Node.js 20+. The package installs two commands: `inworld` (the CLI) and `inworld-mcp` (the standalone MCP server, equivalent to `inworld mcp`).

## Authentication

```bash theme={"system"}
# Authenticate with Inworld Platform (opens browser)
inworld login

# Check current authentication status and configuration
inworld status
```

Credentials are stored securely on your machine (macOS Keychain, Windows Credential Manager, or an encrypted file on Linux) and refreshed automatically.

For CI or other non-interactive environments, either authenticate with a Firebase ID token or set an API key directly:

```bash theme={"system"}
# Exchange a Firebase ID token (e.g., from your CI's OIDC flow)
inworld auth login-ci --token "$FIREBASE_ID_TOKEN" --email you@example.com

# Or skip login entirely with an API key
export INWORLD_API_KEY="..."
```

## Workspaces and API keys

```bash theme={"system"}
# Select a workspace for CLI operations
inworld workspace select

# Create a new API key (read-only by default)
inworld workspace add-key --name my-key

# Create a key with read/write permissions for voices and router
inworld workspace add-key --write --name my-key

# Make a key the active one for CLI commands (new keys are not auto-selected)
inworld workspace select-key

# Print the current API key (e.g., to export it as an environment variable)
inworld auth print-api-key
```

## Text-to-Speech

```bash theme={"system"}
# List available voices
inworld tts list-voices

# Show details for a voice, or listen to its preview sample
inworld tts get-voice Dennis
inworld tts preview Dennis --play

# Synthesize text to speech
inworld tts synthesize "Hello world" --voice Dennis --output hello.mp3

# Synthesize and play through speakers
inworld tts synthesize "[happy] Great to see you!" --play

# Pick a model (inworld-tts-2, inworld-tts-1.5-max, or inworld-tts-1.5-mini)
inworld tts synthesize "Hello world" --model inworld-tts-1.5-mini --voice Dennis

# Clone a voice from an audio file (5-15 seconds, max 4MB)
inworld tts clone sample.wav --name "My Voice"

# Design a voice from a text description (interactive wizard)
inworld tts design "A warm, deep narrator voice with a slight British accent"
```

`synthesize` supports [audio markups](/tts/capabilities/steering) directly in the text: emotions (`[happy]`, `[sad]`), delivery styles (`[whispering]`), vocalizations (`[laugh]`, `[sigh]`), SSML breaks, and IPA pronunciation.

## Audiobooks

Turn a whole book into a single MP3 with chapter markers:

```bash theme={"system"}
# Generate an audiobook from a .txt or .epub file
inworld audiobook generate book.epub --voice Dennis --output book.mp3
```

Chapters are detected automatically (Markdown headings or "Chapter 1"-style lines in `.txt`, the spine in `.epub`) and synthesized in parallel, each on its own TTS session so voice delivery stays consistent within a chapter. Long runs are resumable: pass `--work-dir <dir>` and a re-run skips chapters that already finished.

## Speech-to-Text

```bash theme={"system"}
# Transcribe an audio file
inworld stt transcribe recording.wav

# Transcribe with a specific language
inworld stt transcribe recording.mp3 --lang es-ES
```

## LLM Router

```bash theme={"system"}
# List models available to your workspace
inworld llm models

# Send a chat completion request
inworld llm chat "What is the capital of France?" --model gpt-4o-mini
```

## MCP server

The CLI ships with the full Inworld MCP server — your AI assistant gets real operational tools, not just documentation search: TTS previews, voice design and publishing, STT transcription, LLM chat, workspace search and limits, billing summary, and router + BYOK credential management.

```bash theme={"system"}
# Run as a stdio MCP server (for Claude Code, Cursor, etc.)
inworld mcp        # or the standalone bin: inworld-mcp

# Or run over HTTP
inworld mcp --http --port 3333
```

For example, to add it to Claude Code:

```bash theme={"system"}
claude mcp add inworld -- inworld mcp
```

<Note>
  Many agents don't need the MCP server at all — they can call `inworld` commands directly from the shell.
</Note>

## Telemetry

The CLI collects anonymous usage analytics. To opt out:

```bash theme={"system"}
inworld auth disable_cli_telemetry
```

## Inworld CLI vs. Runtime CLI

The Inworld CLI (`inworld`) covers platform APIs: auth, API keys, TTS, STT, and LLM Router. For Agent Runtime graph development and deployment (`inworld-runtime init/run/deploy`), see the [Runtime CLI](/node/cli/overview).
