---
title: "Updates public ssh key"
method: PUT
path: "/ssh_key/{sshKeyId}"
tags: ["SshKey"]
---

# Updates public ssh key

`PUT /ssh_key/{sshKeyId}`

## Headers

- `X-Fields` string, mask

## Request body

- SshKeyUpdate
  - `name` string, required
  - `publicKey` string, required — Public key content (RSA, Ed25519, or ECDSA supported)

## Response `200`

Public ssh key successfully updated.

- SshKeyResponseDump
  - `isValid` boolean
  - `name` string
  - `publicKey` string
  - `sshKeyId` integer

## Other responses

- `400` — Unable to update public ssh key.
- `403` — You have not been granted permission to complete this action. Please contact your account manager to grant the proper permission.
- `404` — Public ssh key not found.

---

[API](https://skmtc.net/hivelocity/apis/hivelocity-api.md) · [All operations](https://skmtc.net/hivelocity/apis/hivelocity-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/hivelocity/hivelocity-api/versions/ee6b717b5015/schema)
