Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Termix-SSH/Termix/llms.txt

Use this file to discover all available pages before exploring further.

The Hosts API manages every server connection Termix tracks: SSH, RDP, VNC, and Telnet. You can create hosts with rich configuration — tunnels, jump hosts, SOCKS5 proxies, port-knock sequences, quick actions, and more — as well as export them and import them in bulk. File-manager state (recent files, pinned paths, and shortcuts) and per-host command history are also surfaced here.
All endpoints require a valid jwt session cookie or Authorization: Bearer <token> header unless stated otherwise. Sensitive fields (password, key, sudoPassword, etc.) are stripped from list responses. Use the export or password endpoints to retrieve them.

Host CRUD

GET /host/db/host

Return all hosts accessible to the authenticated user. This includes hosts the user owns and any hosts that have been shared with them (directly or via role). Sensitive credential fields are stripped; hasPassword, hasKey, and hasSudoPassword booleans replace them.
id
number
Unique host identifier.
userId
string
ID of the owner.
connectionType
string
One of ssh, rdp, vnc, telnet.
name
string
Human-readable host name.
ip
string
Hostname or IP address.
port
number
Target port.
username
string
Login username.
folder
string
Folder the host is grouped under.
tags
string[]
Array of tag strings.
pin
boolean
Whether the host is pinned to the top of the list.
authType
string
One of password, key, credential.
hasPassword
boolean
true when a password is stored (redacted from the response).
hasKey
boolean
true when an SSH key is stored.
enableTerminal
boolean
enableTunnel
boolean
enableFileManager
boolean
enableDocker
boolean
tunnelConnections
object[]
Tunnel configurations.
jumpHosts
object[]
Jump host chain configuration.
isShared
boolean
true when this host was shared with the user rather than owned by them.
permissionLevel
string
Permission level for shared hosts.
curl https://your-termix-instance/host/db/host \
  -b cookies.txt

POST /host/db/host

Create a new host. Accepts application/json or multipart/form-data (when uploading an SSH key file). For multipart requests, send the full JSON body as a data field and the key file as key.
ip
string
required
Hostname or IP address of the target server.
port
number
required
Target port (1–65535).
connectionType
string
default:"ssh"
Connection protocol: ssh, rdp, vnc, or telnet.
name
string
Display name. Defaults to username@ip when omitted.
username
string
Login username.
authType
string
Authentication method: password, key, or credential. Required for SSH.
password
string
Password (required when authType is password, or for non-SSH connections).
key
string
PEM-encoded SSH private key (required when authType is key).
keyPassword
string
Passphrase for an encrypted SSH key.
keyType
string
Key algorithm hint (e.g. ssh-ed25519, ssh-rsa).
credentialId
number
ID of a saved credential (required when authType is credential).
overrideCredentialUsername
boolean
When true, use the host’s username instead of the credential’s username.
folder
string
Folder name to group this host.
tags
string[]
Array of tag strings.
pin
boolean
Pin host to the top of the sidebar.
notes
string
Free-text notes about the host.
sudoPassword
string
Sudo password for elevated commands.
defaultPath
string
Default directory for file manager sessions (e.g. /var/www).
forceKeyboardInteractive
boolean
Force keyboard-interactive SSH authentication.
enableTerminal
boolean
Show terminal tab.
enableTunnel
boolean
Show tunnel tab.
enableFileManager
boolean
Show file manager tab.
enableDocker
boolean
Show Docker tab.
showTerminalInSidebar
boolean
showFileManagerInSidebar
boolean
showTunnelInSidebar
boolean
showDockerInSidebar
boolean
showServerStatsInSidebar
boolean
tunnelConnections
object[]
Array of tunnel configuration objects.
jumpHosts
object[]
Ordered list of jump host definitions for SSH proxying.
quickActions
object[]
Predefined commands or actions shown in the UI.
useSocks5
boolean
Route the connection through a SOCKS5 proxy.
socks5Host
string
SOCKS5 proxy hostname.
socks5Port
number
SOCKS5 proxy port.
socks5Username
string
SOCKS5 proxy username.
socks5Password
string
SOCKS5 proxy password.
socks5ProxyChain
object[]
Array of chained SOCKS5 proxy definitions.
portKnockSequence
object[]
Port knock sequence to send before connecting.
macAddress
string
MAC address for Wake-on-LAN.
domain
string
Windows domain (RDP only).
security
string
RDP security protocol (RDP/VNC only).
ignoreCert
boolean
Ignore TLS certificate errors (RDP/VNC only).
guacamoleConfig
object
Extra Guacamole connection parameters for RDP/VNC/Telnet.
statsConfig
object
Server stats widget configuration.
dockerConfig
object
Docker integration configuration.
terminalConfig
object
Terminal appearance and behaviour settings.
StatusMeaning
200Host created; full host object returned.
400Invalid or missing ip, port, or malformed SSH key.
500Database error.
curl -X POST https://your-termix-instance/host/db/host \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{
    "connectionType": "ssh",
    "name": "Production web",
    "ip": "10.0.0.1",
    "port": 22,
    "username": "ubuntu",
    "authType": "password",
    "password": "s3cr3t",
    "enableTerminal": true,
    "enableFileManager": true
  }'

GET /host/db/host/:id

Return a single host by ID. Only the owning user can retrieve their own host this way.
id
number
required
Host ID.
StatusMeaning
200Host object returned (sensitive fields stripped).
400Invalid userId or id.
404Host not found.
500Database error.
curl https://your-termix-instance/host/db/host/42 \
  -b cookies.txt

PUT /host/db/host/:id

Update an existing host. Accepts the same body fields as POST /host/db/host. Only the host owner can change credentials or auth type; shared users with write permission can update other fields.
id
number
required
Host ID to update.
The request body accepts all the same fields documented for POST /host/db/host.
StatusMeaning
200Updated host returned.
400Validation failure or malformed key.
403No write access, or shared user tried to change credential.
404Host not found.
500Database error.
curl -X PUT https://your-termix-instance/host/db/host/42 \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{
    "ip": "10.0.0.1",
    "port": 22,
    "username": "ubuntu",
    "authType": "password",
    "name": "Updated name",
    "pin": true
  }'

DELETE /host/db/host/:id

Delete a host and all related data (file manager history, command history, session recordings, host-access grants, etc.).
id
number
required
Host ID to delete.
StatusMeaning
200Host deleted.
400Invalid userId or id.
404Host not found.
500Database error.
curl -X DELETE https://your-termix-instance/host/db/host/42 \
  -b cookies.txt

Quick connect

POST /host/quick-connect

Create a temporary, in-memory host configuration for an immediate connection without persisting to the database. Returns a full host object with a negative id (e.g. -1716000000000).
ip
string
required
Hostname or IP address.
port
number
required
Target port.
username
string
required
Login username.
authType
string
required
One of password, key, credential.
password
string
Password (required when authType is password).
key
string
PEM SSH private key (required when authType is key).
keyPassword
string
Passphrase for an encrypted key.
keyType
string
Key algorithm hint.
credentialId
number
Saved credential ID (required when authType is credential).
overrideCredentialUsername
boolean
Use the provided username instead of the credential’s username.
StatusMeaning
200Temporary host object returned.
400Missing required fields.
404Credential not found.
500Internal error.
curl -X POST https://your-termix-instance/host/quick-connect \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{
    "ip": "192.168.1.50",
    "port": 22,
    "username": "root",
    "authType": "password",
    "password": "hunter2"
  }'

Credentials & password retrieval

GET /host/db/host/:id/password

Retrieve the stored password or sudo password for a host. Used by the copy-password UI button.
id
number
required
Host ID.
field
string
default:"password"
Which credential to return: password or sudoPassword.
value
string
The decrypted password string.
StatusMeaning
200Password value returned.
400Invalid field value.
404Host not found or field is empty.
curl "https://your-termix-instance/host/db/host/42/password?field=password" \
  -b cookies.txt

Export & import

GET /host/db/host/:id/export

Export a single host with all credentials decrypted. SSH key contents and passwords are included in the response.
id
number
required
Host ID.
StatusMeaning
200Host object with decrypted secrets.
400Invalid userId or id.
404Host not found.
500Export failed.
curl https://your-termix-instance/host/db/host/42/export \
  -b cookies.txt

GET /host/db/hosts/export

Export all hosts owned by the authenticated user with decrypted credentials.
hosts
object[]
Array of fully decrypted host export objects.
StatusMeaning
200Array of host export objects.
400Invalid userId.
500Export failed.
curl https://your-termix-instance/host/db/hosts/export \
  -b cookies.txt

POST /host/bulk-import

Import up to 100 hosts in a single request. Each host follows the same schema as POST /host/db/host. When overwrite is true, existing hosts with matching ip:port:username are updated instead of duplicated.
hosts
object[]
required
Array of host objects to import (max 100).
overwrite
boolean
When true, matching existing hosts are updated.
success
number
Number of hosts created.
updated
number
Number of hosts updated (only when overwrite is true).
skipped
number
Number of hosts skipped.
failed
number
Number of hosts that failed validation.
errors
string[]
Human-readable error messages for failed hosts.
StatusMeaning
200Import results returned.
400hosts is missing, empty, or exceeds 100 items.
curl -X POST https://your-termix-instance/host/bulk-import \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{
    "hosts": [
      {"ip": "10.0.1.1", "port": 22, "username": "ubuntu", "authType": "password", "password": "pw1"},
      {"ip": "10.0.1.2", "port": 22, "username": "admin",  "authType": "password", "password": "pw2"}
    ],
    "overwrite": false
  }'

PATCH /host/bulk-update

Apply partial field updates to multiple hosts at once. Only the host owner’s hosts are updated; unauthorized IDs are reported in errors but do not cause a failure response.
hostIds
number[]
required
Array of host IDs to update (max 1000).
updates
object
required
Fields to update. Supported: pin, folder, enableTerminal, enableTunnel, enableFileManager, enableDocker, statsConfig.
updated
number
Number of hosts updated.
failed
number
Number of host IDs that were not found or not owned.
errors
string[]
Error messages for any partial failures.
StatusMeaning
200Results returned.
400hostIds or updates missing, or hostIds exceeds 1000.
404No matching hosts found.
curl -X PATCH https://your-termix-instance/host/bulk-update \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{
    "hostIds": [1, 2, 3],
    "updates": {"pin": true, "folder": "Production"}
  }'

Internal endpoints

The following endpoints require the X-Internal-Auth-Token header. They are consumed by internal Termix services and are not intended for direct external use.

GET /host/db/host/internal

Return hosts with at least one auto-start tunnel configured. Only the tunnel connections with autoStart: true are included. Header: X-Internal-Auth-Token: <token>
StatusMeaning
200Array of auto-start host objects.
403Invalid or missing internal token.

GET /host/db/host/internal/all

Return all hosts across all users. Used by the stats service. Header: X-Internal-Auth-Token: <token>
StatusMeaning
200Array of all host objects.
401Invalid or missing internal token.

Folders

GET /host/folders

Return all folder records for the authenticated user.
object[]
Array of folder objects with id, name, color, icon, createdAt, updatedAt.
curl https://your-termix-instance/host/folders \
  -b cookies.txt

PUT /host/folders/rename

Rename a folder. Updates the folder field on all matching hosts and credentials, and the folder metadata record.
oldName
string
required
Current folder name.
newName
string
required
New folder name.
updatedHosts
number
Number of hosts updated.
updatedCredentials
number
Number of credentials updated.
StatusMeaning
200Folder renamed.
400oldName or newName missing.
curl -X PUT https://your-termix-instance/host/folders/rename \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"oldName": "Staging", "newName": "Pre-production"}'

PUT /host/folders/metadata

Update folder display metadata (color and icon). Creates the folder record if it does not exist.
name
string
required
Folder name.
color
string
Hex color string (e.g. #3B82F6).
icon
string
Icon identifier string.
StatusMeaning
200Metadata updated.
400name missing.
curl -X PUT https://your-termix-instance/host/folders/metadata \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"name": "Production", "color": "#EF4444", "icon": "server"}'

DELETE /host/folders/:name/hosts

Delete all hosts in a named folder, including all associated data and the folder record itself.
name
string
required
Folder name (URL-encoded if it contains spaces or special characters).
deletedCount
number
Number of hosts deleted.
StatusMeaning
200Hosts deleted (or no hosts found).
400name missing.
500Database error.
curl -X DELETE "https://your-termix-instance/host/folders/Staging/hosts" \
  -b cookies.txt

File manager state

GET /host/file_manager/recent

Return the 20 most recently opened files for a host.
hostId
number
required
Host ID to fetch recent files for.
curl "https://your-termix-instance/host/file_manager/recent?hostId=42" \
  -b cookies.txt

POST /host/file_manager/recent

Record a file as recently opened. If the path already exists, its lastOpened timestamp is updated.
hostId
number
required
Host ID.
path
string
required
Absolute file path on the remote host.
name
string
Display name. Defaults to the last path component.
curl -X POST https://your-termix-instance/host/file_manager/recent \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"hostId": 42, "path": "/etc/nginx/nginx.conf", "name": "nginx.conf"}'

DELETE /host/file_manager/recent

Remove a file from the recent-files list.
hostId
number
required
path
string
required
Exact path to remove.
curl -X DELETE https://your-termix-instance/host/file_manager/recent \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"hostId": 42, "path": "/etc/nginx/nginx.conf"}'

GET /host/file_manager/pinned

Return all pinned file paths for a host.
hostId
number
required
curl "https://your-termix-instance/host/file_manager/pinned?hostId=42" \
  -b cookies.txt

POST /host/file_manager/pinned

Pin a file path. Returns 409 if the path is already pinned.
hostId
number
required
path
string
required
name
string
StatusMeaning
200File pinned.
409Already pinned.
curl -X POST https://your-termix-instance/host/file_manager/pinned \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"hostId": 42, "path": "/var/log", "name": "logs"}'

DELETE /host/file_manager/pinned

Unpin a file path.
hostId
number
required
path
string
required
curl -X DELETE https://your-termix-instance/host/file_manager/pinned \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"hostId": 42, "path": "/var/log"}'

GET /host/file_manager/shortcuts

Return saved file manager shortcuts for a host.
hostId
number
required
curl "https://your-termix-instance/host/file_manager/shortcuts?hostId=42" \
  -b cookies.txt

POST /host/file_manager/shortcuts

Add a shortcut. Returns 409 if the path already has a shortcut.
hostId
number
required
path
string
required
name
string
StatusMeaning
200Shortcut added.
409Shortcut already exists for this path.
curl -X POST https://your-termix-instance/host/file_manager/shortcuts \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"hostId": 42, "path": "/home/ubuntu", "name": "Home"}'

DELETE /host/file_manager/shortcuts

Remove a shortcut.
hostId
number
required
path
string
required
curl -X DELETE https://your-termix-instance/host/file_manager/shortcuts \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"hostId": 42, "path": "/home/ubuntu"}'

Command history

GET /host/command-history/:hostId

Return up to 200 recent commands executed on a host, ordered newest-first.
hostId
number
required
Host ID.
string[]
Array of command strings.
StatusMeaning
200Command list returned.
400Invalid userId or hostId.
curl https://your-termix-instance/host/command-history/42 \
  -b cookies.txt

DELETE /host/command-history

Remove a specific command from a host’s history.
hostId
number
required
command
string
required
Exact command string to delete.
StatusMeaning
200Command removed.
400Missing hostId or command.
curl -X DELETE https://your-termix-instance/host/command-history \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{"hostId": 42, "command": "rm -rf /tmp/old"}'

Build docs developers (and LLMs) love