Register an SSH public key

Beta

Register an SSH public key (the contents of an OpenSSH .pub file) on the caller’s account. Returns 400 for a malformed or unsupported key, 409 when the key is already registered or the caller has reached the per-account limit.

Authentication

X-API-KEYstring
API Key authentication via header

Request

This endpoint expects an object.
public_keystringRequired1-16384 characters

The contents of an OpenSSH .pub file: <type> <base64> [comment]. Accepted types: ssh-ed25519, ecdsa-sha2-nistp256/384/521, ssh-rsa (2048 bits or more), and the FIDO sk- variants.

labelstring or nullOptional<=64 characters

Optional display label; defaults to the key’s comment, then its type.

Response

Successful Response
created_atdatetime
When the key was registered.
fingerprintstring

SHA256:… fingerprint, as printed by ssh-keygen -lf.

idstring

Key id (ussk_…); use it to delete the key.

key_typestring

Key algorithm, e.g. ssh-ed25519.

labelstring

Display label (defaults to the key comment).

public_keystring

The key in <type> <base64> form (no comment).

last_used_atdatetime or nullOptional
When the key last authorized an SSH connection, if ever.

Errors

400
Bad Request Error
409
Conflict Error
422
Unprocessable Entity Error