Return to Homepage

Add SSH Key

http
POST /crates/{handle}/logins/{login}/keys

Adds a public key to the login. ssh-ed25519, ecdsa-sha2-nistp256/384/521, security keys (sk-ssh-ed25519@openssh.com, sk-ecdsa-sha2-nistp256@openssh.com) and ssh-rsa of 2048 bits or more are accepted. 422 when the key can’t be read or the login already has it; a login can have up to 20 keys.

Parameters

Field Type Required Default Description
public_key string Yes One line from a .pub file
label string No the key’s comment A name for the key (max 100)

Response (201)

json
{ "fingerprint": "SHA256:evMii4DCaw+hEMB69TCBxgJ7IHWp5YzNTFV9ALfjTUg", "message": "Key added." }

Snagged on something?

Our sysadmins answer tickets around the clock.