Fetch SSH Credentials

Generate SSH credentials that can be used to console in to the instance.

Requires the containers-ssh permission.

Returns

Returns an SSH Connection Document, otherwise returns an Error.

SSH Connection Document
  • address
    string

    The address so connect to via SSH.

  • secret
    string

    The secret to pass as the password to the SSH connection.

  • token
    object

    Information about the SSH token that was requested.

    Show child fields

GET /v1/containers/{CONTAINER_ID}/instances/{INSTANCE_ID}/ssh

Example Request
$ curl https://api.cycle.io/v1/containers/5b9c2a77b6393d0001eb45fd/instances/5cc78aa0db2ab000014a8b98/ssh \
-H
"Authorization: Bearer API_KEY"
\
-H
"X-HUB-ID: HUB_ID"
Example Response
{
"data": {
"token": {
"id": "5d09ac7f4146380001a3ecb5",
"instance_id": "5cc78aa0db2ab000014a8b98",
"container_id": "5cc78a8adb2ab000014a8b8a",
"hub_id": "5a14ddd8b6393d0001976f44",
"creator": {
"id": "59c6f65891238b00012b1d96",
"type": "account"
},
"events": {
"created": "2019-06-19T03:31:11.608559487Z",
"used": "0001-01-01T00:00:00Z",
"expires": "2019-06-19T04:01:11.608559827Z"
},
"valid": true
},
"secret": "I5qQGoaU9s63RFnm5KQE52JIm",
"address": "5cc78aa0db2ab000014a8b98@console.dev.cycle.io:22"
}
}