# Getting Started with Vapor

> Install vapor and vapord, import your local Claude Code, Codex, and Antigravity sign-ins, and launch sessions with automatic in-place account rotation inside Rex.

- Site: VAPOR.TOWN (https://vapor.town)
- Canonical: https://vapor.town/docs/getting-started
- Markdown: https://vapor.town/docs/getting-started.md
- Section: Overview

## What Vapor Does

Vapor is an open-source, Linux-first subscription router and terminal session wrapper for AI coding agents (Claude Code, Codex, and Antigravity), designed to run natively inside Rex.

Instead of manually juggling profile directories or losing scrollback when a subscription hits its 5-hour or 7-day quota cap, wrap your agent with `vapor claude`, `vapor codex`, or `vapor agy`.

- **In-place account rotation**: Verifies quota exhaustion, stages the handoff bundle, boots a replacement on the best available account, checks `NoStaleOriginalStop`, and swaps the child PTY **in-place** — your Rex pane, scrollback, and mobile view never jump.
- **Native usage probing & Codex reset claiming**: `vapord` probes live quota windows via Claude `/usage`, Codex `app-server`, and `agy usage --json`, and can redeem earned Codex resets inline or via `vapor pool claim-reset <account-id>`.
- **Interactive Pool TUI**: Run bare `vapor` (or `vapor tui`) to inspect readiness, quota windows, active leases, and high-resolution charts via the Kitty Graphics Protocol in Rex and Ghostty, with automatic Unicode fallback everywhere else.
- **Native Rex & Mobile Status (`OSC 7501`)**: Emits Program Status Protocol transitions (`working`, `idle`, `blocked`, `done`, `error`) automatically to Rex desktop, Rex iOS, and Moshi.

## Installation

Install prebuilt binaries for macOS ARM64, Linux x86_64, and Linux ARM64 into ~/.local/bin (override with VAPOR_INSTALL_DIR), or build from source with stable Rust.

```sh
# One-Line Install (macOS ARM64 / Linux x86_64 & ARM64)
curl -fsSL https://raw.githubusercontent.com/hraness/vapor/main/scripts/install.sh | sh
# Or build from source with Cargo (stable Rust, edition 2024):
cargo install --git https://github.com/hraness/vapor.git vapor vapord
```

## Quick Start Loop

Import your existing local sign-ins (~/.claude, ~/.codex, ~/.gemini/antigravity-cli, plus any $CLAUDE_CONFIG_DIR, $CODEX_HOME, or ~/.config/vapor/profiles/*), inspect the pool, and wrap your agent.

```bash quickstart.sh
# 1. Import existing local agent accounts into the Vapor pool
vapor pool import
vapor pool ls

# 2. Launch the live Pool TUI (Kitty Graphics in Rex/Ghostty, Unicode elsewhere)
vapor
vapor tui --no-graphics   # Force Unicode-only mode
vapor tui --graphics      # Force Kitty Graphics Protocol

# 3. Launch an agent with automatic in-place rotation
vapor claude
vapor codex
vapor agy

# 4. Inspect pool health and Rex integration
vapor pool status
vapor rex status
```

> **Note:** Vapor never reads, logs, or transmits raw auth tokens. Account credentials stay inside their native provider profile directories on your machines.
