Skip to main content
POST
/
ssh_keys
Add a new public SSH key to a user
curl --request POST \
  --url {schemes}://api.upsun.com/ssh_keys \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "value": "<string>",
  "title": "<string>",
  "uuid": "<string>"
}
'
{
  "key_id": 123,
  "uid": 123,
  "fingerprint": "<string>",
  "title": "<string>",
  "value": "<string>",
  "changed": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
value
string
required

The value of the ssh key.

title
string

The title of the ssh key.

uuid
string

The uuid of the user.

Response

201 - application/json

The newly created ssh key.

The ssh key object.

key_id
integer

The ID of the public key.

uid
integer

The internal user ID.

fingerprint
string

The fingerprint of the public key.

title
string

The title of the public key.

value
string

The actual value of the public key.

changed
string

The time of the last key modification (ISO 8601)

Last modified on March 25, 2026