Scaleway logo
IAM API

An SSH Key (Secure Shell Key) allows passwordless connection to an InstanceOpen in new context. An SSH Key is generated by creating an RSA key pairOpen in new context, consisting of a sensitive identification key, (aka private key) which must be stored securely, and a public key which is uploaded to the Scaleway interface.

The public key is kept in your Scaleway account and transferred to the Instance during the boot process, while the identification key is kept securely on your local computer. When connecting to the Instance via SSH, a trusted connection to the machine is established using the key pair.


List SSH keys

GET
https://api.scaleway.com
/iam/v1alpha1/ssh-keys

List SSH keys. By default, the SSH keys listed are ordered by creation date in ascending order. This can be modified via the order_by field. You can define additional parameters for your query such as organization_id, name, project_id and disabled.

List SSH keys › query Parameters

order_by
​scaleway.iam.v1alpha1.ListSSHKeysRequest.OrderBy · enum

Sort order of the SSH keys.

Enum values:
created_at_asc
created_at_desc
updated_at_asc
updated_at_desc
name_asc
name_desc
Default: created_at_asc
page
​integer · int32

Requested page number. Value must be greater or equal to 1.

page_size
​integer · uint32

Number of items per page. Value must be between 1 and 100.

organization_id
​string

Filter by Organization ID.

name
​string

Name of group to find.

project_id
​string

Filter by Project ID.

disabled
​boolean

Defines whether to include disabled SSH keys or not.

List SSH keys › Responses

200

List of SSH keys.

total_count
​integer · uint32

Total count of SSH keys.


Create an SSH key

POST
https://api.scaleway.com
/iam/v1alpha1/ssh-keys

Add a new SSH key to a Scaleway Project. You must specify the name, public_key and project_id.

Create an SSH key › Request Body

name
​string · required

Name of the SSH key. Max length is 1000.

public_key
​string · required

SSH public key. Currently only the ssh-rsa, ssh-dss (DSA), ssh-ed25519 and ecdsa keys with NIST curves are supported. Max length is 65000.

project_id
​string · required

Project the resource is attributed to.

Create an SSH key › Responses

200
id
​string

ID of SSH key.

name
​string

Name of SSH key.

public_key
​string

Public key of SSH key.

fingerprint
​string

Fingerprint of the SSH key.

created_at
​string | null · date-time

Creation date of SSH key. (RFC 3339 format)

updated_at
​string | null · date-time

Last update date of SSH key. (RFC 3339 format)

organization_id
​string

ID of Organization linked to the SSH key.

project_id
​string

ID of Project linked to the SSH key.

disabled
​boolean

SSH key status.

srn
​string

The SRN of the SSH key.


Get an SSH key

GET
https://api.scaleway.com
/iam/v1alpha1/ssh-keys/{ssh_key_id}

Retrieve information about a given SSH key, specified by the ssh_key_id parameter. The SSH key's full details, including id, name, public_key, and project_id are returned in the response.

Get an SSH key › path Parameters

ssh_key_id
​string · required

ID of the SSH key.

Get an SSH key › Responses

200
id
​string

ID of SSH key.

name
​string

Name of SSH key.

public_key
​string

Public key of SSH key.

fingerprint
​string

Fingerprint of the SSH key.

created_at
​string | null · date-time

Creation date of SSH key. (RFC 3339 format)

updated_at
​string | null · date-time

Last update date of SSH key. (RFC 3339 format)

organization_id
​string

ID of Organization linked to the SSH key.

project_id
​string

ID of Project linked to the SSH key.

disabled
​boolean

SSH key status.

srn
​string

The SRN of the SSH key.


Delete an SSH key

DELETE
https://api.scaleway.com
/iam/v1alpha1/ssh-keys/{ssh_key_id}

Delete a given SSH key, specified by the ssh_key_id. Deleting an SSH is permanent, and cannot be undone. Note that you might need to update any configurations that used the SSH key.

Delete an SSH key › path Parameters

ssh_key_id
​string · required

Delete an SSH key › Responses

No data returned

Update an SSH key

PATCH
https://api.scaleway.com
/iam/v1alpha1/ssh-keys/{ssh_key_id}

Update the parameters of an SSH key, including name and disable.

Update an SSH key › path Parameters

ssh_key_id
​string · required

Update an SSH key › Request Body

name
​string | null

Name of the SSH key. Max length is 1000.

disabled
​boolean | null

Enable or disable the SSH key.

Update an SSH key › Responses

200
id
​string

ID of SSH key.

name
​string

Name of SSH key.

public_key
​string

Public key of SSH key.

fingerprint
​string

Fingerprint of the SSH key.

created_at
​string | null · date-time

Creation date of SSH key. (RFC 3339 format)

updated_at
​string | null · date-time

Last update date of SSH key. (RFC 3339 format)

organization_id
​string

ID of Organization linked to the SSH key.

project_id
​string

ID of Project linked to the SSH key.

disabled
​boolean

SSH key status.

srn
​string

The SRN of the SSH key.