Docs TUI — terminal user interface

TUI — terminal user interface

mockarty-cli tui opens an interactive terminal UI for the same Mockarty server
the CLI commands talk to. Use it when you work over SSH, inside tmux, or on a
machine without a browser.

Every screen calls the same server API as the non-interactive commands, so the
data is the same one the web UI shows. Each screen also has a deep link:
mockarty-cli tui <name> opens it directly from a shell alias or a CI step.

Why use the TUI

  • No browser. Works over SSH and on minimal Linux images.
  • Fast. Key presses translate straight to API calls.
  • Discoverable. The welcome menu lists every screen; ? shows the keys of
    the current screen.
  • Usable before signing in. Without a server or token it still starts and
    shows the welcome menu, the docs link and the login entry point.

Launch

Command Opens
mockarty-cli tui Welcome menu
mockarty-cli tui auth Auth status
mockarty-cli tui login Sign-in screen (also switches server)
mockarty-cli tui test-plans Test Plan picker
mockarty-cli tui results [--plan ID] Results viewer
mockarty-cli tui mocks Mock list
mockarty-cli tui perf Performance configurations
mockarty-cli tui fuzz Fuzz targets
mockarty-cli tui chaos Chaos experiments

The interface language follows the terminal locale. Set it explicitly when the
locale is not what you want:

MOCKARTY_LANG=ru mockarty-cli tui

Language resolution: MOCKARTY_LANG, then LC_ALL / LANG / LANGUAGE, then
English.

Welcome menu

Press the lowercase key for the screen you want:

Key Screen
a Auth status — mode, role, namespace
t Test Plans
r Recent results
k Mocks
p Performance configurations
f Fuzz targets
c Chaos experiments
l Login / switch server
? Help for the current screen
q Quit

Enter is a shortcut to Auth status, the most common first action.

Global keys

Key Action
? Help for the current screen
q Quit
ctrl+c Quit from anywhere, including inside a text field
esc Back to the parent screen
tab / shift+tab Next / previous field or pane
enter Confirm or drill into the highlighted item
↑ / ↓ Move within a list
p / n Previous / next page in long lists

While a text field is focused, q and ? are typed as text instead of acting
as shortcuts. ctrl+c always quits.

Screen tour

Auth status (a or tui auth)

Without a token, shows how to sign in. After sign-in, shows your login, email,
system role, server URL and active namespace.

Test Plans (t or tui test-plans)

Lists the Test Plans in the active namespace with owner, last run status and
last change. Enter opens a plan’s items, r starts a run, l shows earlier
runs.

Results (r or tui results [--plan ID])

The latest result rows with pass/fail, duration and the link to the full report.
Without --plan it lists results for the namespace; with --plan it shows that
plan’s history.

Mocks (k or tui mocks)

Browse the mocks in the active namespace. Type in the filter box to narrow by
method or path; Enter opens the stub details (headers, conditions, response
preview), I opens the file importer, r refreshes the list.

Performance configurations (p or tui perf)

Saved load-test configurations. Enter opens a configuration, r refreshes the
list, N creates a new configuration. From a configuration’s details, Enter
starts a run and shows its progress.

Fuzz targets (f or tui fuzz)

Saved fuzz targets (endpoint plus mutation strategy). Enter opens the target’s
runs, r starts a new one.

Chaos experiments (c or tui chaos)

Prior experiments with status and target, plus a wizard
(name → target → fault → schedule → review) for a new one. Press r to
refresh the table.

Fault injection changes a live cluster, so the mutating actions ask for an
explicit acknowledgement: pass --i-know-this-is-preview or set
MOCKARTY_CHAOS_PREVIEW=1. Read-only screens work without it.

Appearance

The TUI adapts to the terminal’s colour profile:

  • NO_COLOR=1 disables colour — useful on dumb terminals.
  • TERM=xterm-256color enables 256-colour mode.
  • COLORTERM=truecolor enables 24-bit colour.

Troubleshooting

Symptom Cause / fix
Screen flickers or characters drift Terminal is too narrow. Resize to at least 80 columns, then press any key.
Cyrillic labels render as boxes The terminal font lacks Cyrillic glyphs. Install a Unicode-complete font.
Colours look wrong on a light background The terminal mis-reports its background. Try another terminal or NO_COLOR=1.
? types a question mark A text field is focused. Press esc, then ?.
Only the welcome menu opens No usable connection. Run mockarty-cli tui login or mockarty-cli auth login.
mockarty-cli tui exits immediately It needs an interactive terminal. Run it directly, not through a pipe.

Connection and language

The TUI uses the same connection settings as the CLI: the saved connection
(mockarty-cli login / mockarty-cli auth login), or MOCKARTY_SERVER and
MOCKARTY_API_TOKEN from the environment. If the server is unreachable, the
auth screen shows the connection error — check the URL and the network.

Language: MOCKARTY_LANG, then LC_ALL / LANG / LANGUAGE, then English.

See Mockarty CLI for the non-interactive commands and
OAuth login for browser sign-in.