Commands
Top-level commands and common workflows.
The CLI groups commands into a small number of operational areas: authentication, project and context management, tunnel operations, declarative management, signaling, remote terminals, and live inventory.
The root command is rstream. It accepts global flags that affect configuration loading and logging:
--configselects the CLI configuration file.--contextselects an Engine API context for commands that connect to the engine.--api-urlselects the Control plane API URL.--regionselects an authorized region exposed by a managed Global project.-vor--verboseenables logs on stderr.-lor--log-levelsetsdebug,info,warn,error, ornone.-for--log-formatsetsauto,json,json-pretty,text, ortext-pretty.--versionprints version information.
Top-level command surface
The main operational commands are:
| Command | Summary |
|---|---|
login | Authenticate the CLI and store a token locally. |
logout | Remove the stored token from the local configuration. |
project | Manage projects, custom domains, reserved TCP addresses, and project contexts. |
context | Create, update, select, and inspect local contexts. |
forward | Create a tunnel and forward traffic to a local target. |
run | Manage tunnels declaratively from YAML or Docker labels. |
tunnel | List tunnels visible through the current engine and token. |
client | List clients visible through the current engine and token. |
events | Subscribe to the event stream over SSE or WebSocket. |
doctor | Diagnose config, auth, context, project, DNS, TLS or QUIC transport, and engine state. |
ui | Open the live terminal UI for WebTTY servers, tunnels, and clients. |
netcat | Open TCP or rstream streams and rstream datagram sessions from the CLI. |
webtty | Run or connect to a WebTTY server. |
The shell completion and built-in help commands are omitted here. The exact subcommands and flags evolve over time, so the installed version should always be checked with the built-in help output.
Region selection applies to managed Global project contexts. The CLI resolves the selected region through the Control plane before connecting to the engine, rejects regions that are not exposed by the project, and rejects an explicit region for a regional project. Use rstream project list to inspect each project's ROUTING mode and REGIONS. An explicit --region cannot be combined with an explicit engine override.
Agent-friendly output
Automation should prefer JSON output where available:
rstream login -o json
rstream project list -o json
rstream project use <project-endpoint> -o json
rstream context list -o json
rstream context get <name> -o json
rstream context create <name> --engine <engine> --token-file <file> -o json
rstream tunnel list -o json
rstream client list -o json
rstream events --transport websocket -o json
rstream doctor -o json
rstream forward 8080 -o jsonrstream doctor -o json is the readiness check to run after setup changes or while troubleshooting. It reports configuration, selected context, token claims, Control plane API authentication, project resolution, DNS, TLS or QUIC transport, and engine inventory without printing token values.
Project resources
Custom domains and reserved TCP addresses are Control plane resources. They can be managed without a live engine connection and default to the project selected by the current context. Pass --project-id to target another project.
Register a custom hostname, inspect the DNS records returned by the Control plane, verify it after DNS propagation, and remove it when it is no longer needed:
rstream project domain list
rstream project domain add api.example.com -o yaml
rstream project domain verify api.example.com -o yaml
rstream project domain remove api.example.comReserve, inspect, and release stable TCP addresses by public port:
rstream project tcp-address list
rstream project tcp-address reserve
rstream project tcp-address release <port>Table output is the default. Use -o json or -o yaml when automation needs the complete resource, including DNS configuration and certificate state for a custom domain.
Help and versioning
To inspect a command, use the --help flag:
rstream tunnel --helpTo print the installed CLI version:
rstream --version