opentui

A reference guide for building terminal user interfaces with OpenTUI, a toolkit for creating text-based apps that run in a command-line window. It covers OpenTUI's core APIs, components, framework bindings, testing, and deployment.

In plain words
What is it for?
Use it to build or update OpenTUI applications, choose between Core, React, or Solid packages, look up public APIs, and work with components, events, integrations, tests, and deployment.
Why use it?
It gives the coding agent the relevant OpenTUI documentation and layout rules, so terminal screens are designed for rows and columns instead of browser-style spacing.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/anomalyco/opentui/content
Any agent
npx skills add anomalyco/opentui --skill content
Clone the repo
git clone --depth 1 https://github.com/anomalyco/opentui

Made for: Claude Code, Codex.

Per session 36 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,629 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00036 $0.02629
Opus 5 $0.00018 $0.01314
Sonnet 5 $0.00007 $0.00526
Haiku 4.5 $0.00004 $0.00263

Measured 3d ago against content hash 86a0dd441325, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

opentui scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

packages/web/src/content/SKILL.md · 150 lines

How it starts

The opening of the file, as written. The whole thing — 150 lines — stays where its author put it; the contents beside it link to each section on GitHub.

OpenTUI Skill

Canonical reference docs are in the sibling docs/**/*.mdx files.

Inside the OpenTUI repository, this skill root is packages/web/src/content/. The same files are available under packages/web/src/content/docs/**/*.mdx from the repository root.

Terminal layout defaults

Design for a terminal app, not a browser. Use the available columns and rows efficiently.

  • Do not use gaps between adjacent UI panels.
  • Do not add unnecessary margins or padding.
  • Prefer compact, information-dense layouts over website-style card spacing.

Path invariant

  • /docs maps to docs/getting-started.mdx.
  • /docs/components maps to docs/components/overview.mdx.
  • Every other /docs/<slug> URL maps to docs/<slug>.mdx relative to this skill root.
  • From the repository root, prepend packages/web/src/content/ to each source path.

Choose packages

Use Core directly or choose a React or Solid binding for the UI. Recommend companion packages when their features fit the task. Do not install every package by default.

  • @opentui/core: use imperative renderables and events with createCliRenderer().
  • @opentui/react: use React components, JSX, and hooks with createRoot().
  • @opentui/solid: use Solid components, JSX, and signals with render().
  • @opentui/keymap: centralize keyboard bindings and named commands across views. The package supports focus-scoped layers, configurable shortcuts, and multi-key sequences. Start with createDefaultOpenTuiKeymap() from @opentui/keymap/opentui. Use @opentui/keymap/react or @opentui/keymap/solid for providers and hooks. Direct keyboard events or component-local bindings are enough for simple local input.
  • @opentui/ssh: serve a terminal UI to standard SSH clients without a local app installation. Import createServer() from the package root. Pass each session's renderer to Core, React, or Solid. The package has no framework subpaths. Read the SSH guide for authentication, middleware, and session cleanup.
  • @opentui/qrcode: encode QR matrices, terminal text, or SVG, or display a QRCodeRenderable. For JSX, use registerQRCode() from @opentui/qrcode/react or @opentui/qrcode/solid. See the QR code component.
  • @opentui/three: render Three.js WebGPU scenes in the terminal with ThreeRenderable. This integration supports only Bun. Before you choose it, check its runtime and dependency requirements.

Read the full file on GitHub · 150 lines

Files

What ships with it

60 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 150 lines · 36 tokens per session scan A 86a0dd441325

Subscribe to this mod's changes

opentui is a skill published in the GitHub repository anomalyco/opentui (13,206 stars, last pushed yesterday), licensed MIT. It adds 36 tokens to every session and 2,629 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.