Skip to navigation

Get the SSH connection target for a computer asset

Beta

Return the SSH gateway host, port, username, and ready-made command for connecting to a computer with a registered SSH public key (see add_ssh_key). The username is the computer’s asset id; the gateway authorizes the connection against your current edit permission on the computer and starts it if it is stopped. Unlike create_ssh_access, this mints nothing and never wakes the computer. key_auth_enabled is false where the environment’s gateway accepts tokens only. Returns 409 when the computer’s provider does not support SSH.

Authentication

X-API-KEYstring
API Key authentication via header

Path parameters

asset_idstringRequired

Headers

X-Athena-Session-CredentialstringOptional

Response

Successful Response
commandstring

Ready-to-run ssh [-p <port>] <asset_id>@<host>.

hoststring
SSH gateway hostname for this environment.
key_auth_enabledboolean

Whether this environment’s SSH gateway accepts registered-key logins. When false, command is refused at the gateway; connect with a temporary token from create_ssh_access instead.

portinteger
SSH gateway port.
token_expiry_minutes_optionslist of integers

Lifetimes, in minutes, this environment offers for a temporary token from create_ssh_access, ascending. The first is the default when none is requested; a request above the last is refused.

usernamestring

The SSH username — the computer’s asset id, which selects identity (registered-key) authentication at the gateway.

Errors

401
Unauthorized Error
404
Not Found Error
409
Conflict Error
422
Unprocessable Entity Error