TheDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/gnmyt/Nexterm/llms.txt
Use this file to discover all available pages before exploring further.
nt CLI exposes a set of subcommands that cover the full lifecycle of working with your Nexterm servers from the terminal: authenticating, browsing your inventory, opening interactive sessions, running one-off commands, and forwarding ports. Every subcommand resolves servers by numeric ID, exact name, or fuzzy match, so you rarely need to look anything up first.
You must run
nt login at least once before using any other command. See Installation for setup instructions.nt login
Authenticate with a Nexterm server and save the session token to~/.config/nexterm/config.json.
nt login, you are prompted to:
- Enter (or confirm) your server URL — for example,
https://nexterm.example.com. - Choose an authentication method:
- Code — a one-time code is printed. Enter it in the web UI under Servers → Connect Device.
- Browser — your default browser opens the authorization page automatically.
nt logout
Clear the stored session token. You will need to runnt login again before any authenticated command works.
nt ls
List all servers in a tree that mirrors the folder hierarchy in the Nexterm web UI. Only terminal-based entries (SSH, Telnet, PVE LXC, PVE Shell) are shown.Flags
| Flag | Type | Description |
|---|---|---|
--folder <name> | string | Show only servers inside a folder whose name contains <name> (case-insensitive). |
--tag <name> | string | Show only servers that have a tag whose name contains <name> (case-insensitive). |
--json | boolean | Print the raw server inventory as pretty-printed JSON instead of the tree view. |
Examples
#8), name, protocol, IP address, and any tags. You can pass the ID directly to nt connect to avoid any name ambiguity.
nt connect
Open an interactive terminal session with a server, or run a single command on it non-interactively.<server> argument is resolved in order:
- Numeric ID — matches the
#Nshown bynt ls(for example,nt connect 8). - Exact name — case-insensitive match on the server name.
- Fuzzy match — the closest matching server name or IP is selected automatically.
Running a command non-interactively
Append-- followed by the command you want to run. Standard output and standard error are printed directly, and the remote exit code is forwarded to the calling shell.
nt connect with other shell tools:
nt search
Fuzzy-search across all your servers by name and IP address, then pick one from an interactive ranked list to connect to.Examples
nt recent
Browse your full server list interactively and select one to connect to. Useful when you don’t remember a server’s exact name or ID.nt forward
Forward a remote port to your local machine through a server, similar tossh -L. The tunnel stays open until you press Ctrl+C.
<server> argument follows the same resolution rules as nt connect (numeric ID, exact name, or fuzzy match).
Flags
| Flag | Type | Default | Description |
|---|---|---|---|
--port <n> / -p | number | — | Required. The port on the remote side to expose. |
--local <n> / -l | number | Same as --port | Local port to listen on. |
--remote <host> / -r | string | 127.0.0.1 | Remote host to connect to on the server’s network. |
Examples
3000 becomes available at 127.0.0.1:8080 on your machine. In the second example, the CLI connects through my-server to a host at 10.0.0.5 on the server’s network and exposes its port 5432 locally.
The
--remote flag is useful for reaching databases, internal services, or admin panels that are not directly exposed on the server itself.nt config
View and modify CLI configuration stored in~/.config/nexterm/config.json.
Subcommands
config show
Print all configuration keys and their current values.config set
Set a configuration key to a new value.config get
Print the current value of a single key.Configuration keys
| Key | Description |
|---|---|
server-url | The URL of your Nexterm server. |
accept-invalid-certs | Set to true to allow self-signed SSL certificates. |