Terminal session recording CLI for capturing, replaying, streaming, and sharing shell sessions as asciicast text logs.
$cargo install --locked --git https://github.com/asciinema/asciinema
Agent Compatibility
JSON Output
Agent Skill
MCP Support
AI Analysis
asciinema records terminal sessions into the asciicast format and can also replay, stream, convert, concatenate, and upload those recordings. It is mainly a capture-and-sharing tool for shell workflows rather than a general service administration CLI.
What It Enables
- Record a shell command or full session to asciicast, raw terminal output, or plain text, including unattended runs with
--headless. - Stream a live terminal session over a local HTTP server or an asciinema server, then upload recordings for sharing or documentation.
- Concatenate recordings and convert between asciicast v1 or v2 or v3, raw output, and plain text for docs, demos, or regression artifacts.
Agent Fit
--headlessand--returnmake it usable in scripted runs where an agent needs to capture terminal behavior and preserve the wrapped command's exit status.- Structured asciicast v2 or v3 output can be written to files or stdout, which gives agents a machine-readable artifact to parse, store, or post-process.
- Best for documentation, demos, bug repros, and audit trails; it is less useful as a direct inspect-or-mutate primitive against external systems.
Caveats
- Remote upload and public streaming depend on browser-based authentication and an asciinema server account or self-hosted deployment.
- Playback and the local stream viewer are human-facing experiences, so much of the value comes after the capture step rather than during autonomous execution.