API reference

SSH and terminal

The SSH tunnel every kiste ssh, scp and forward uses, the host key it pins, and the browser terminal.

The SSH tunnel every kiste ssh, scp and forward uses, the host key it pins, and the browser terminal.

Get the SSH host key

GET /v1/instances/{name}/ssh-host-key

The Kiste's SSH host key with the alias NAME.kiste and a ready known_hosts line. The CLI pins this key, so a connection to anything else fails.

Path parameters:

NameTypeRequiredDescription
namestringyesThe Kiste's name.
curl -sS "https://kiste.run/v1/instances/review-42/ssh-host-key" \
  -H "Authorization: Bearer $KISTE_TOKEN"

Responses:

Errors use the error envelope.

Open the SSH tunnel

GET /v1/instances/{name}/ssh-tunnel

A WebSocket that carries the raw SSH connection to the Kiste's SSH server; kiste proxy is the OpenSSH ProxyCommand that uses it. Binary frames both ways. Before the upgrade it answers 409 when the Kiste is not running, its SSH server is not listening yet, or the account already has 32 tunnels open. An idle tunnel closes after one hour without traffic; stopping, restarting or deleting the Kiste and signing out everywhere close it too.

Path parameters:

NameTypeRequiredDescription
namestringyesThe Kiste's name.

Responses:

  • 101 WebSocket upgrade.

Errors use the error envelope.

Open a browser terminal

POST /v1/instances/{name}/terminal

Issues a short-lived capability for a terminal in the browser, as the console's Terminal page uses it. cols and rows set the initial size.

Path parameters:

NameTypeRequiredDescription
namestringyesThe Kiste's name.
curl -sS -X POST "https://kiste.run/v1/instances/review-42/terminal" \
  -H "Authorization: Bearer $KISTE_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"cols":120,"rows":40}'

Request body: CreateTerminalSessionRequest

FieldTypeRequiredDescription
colsinteger (int32)no
rowsinteger (int32)no

Responses:

Errors use the error envelope.

Connect a browser terminal

GET /v1/terminal/connect

The WebSocket of a browser terminal, opened with the capability from the call above.

Responses:

  • 101 WebSocket upgrade.

Errors use the error envelope.

On this page