---
title: "Read a server's SSH host key, without logging in, so the operator can confirm it before adding the server."
method: POST
path: "/nodes/ssh/host-key"
tags: ["Nodes"]
---

# Read a server's SSH host key, without logging in, so the operator can confirm it before adding the server.

`POST /nodes/ssh/host-key`

## Request

- Base URL: `/api` (relative, and the document was published on a file host, not at the API’s origin)
- URL: `/api/nodes/ssh/host-key`
- Auth: HTTP bearer

## Request body

- NodeSshHostKeyRequest: A server to read the SSH host key of.
  - `host` string, required: Hostname or IP address.
  - `port` integer, nullable: SSH port (default 22).

## Response `200`

The server's host key

- NodeSshHostKeyResponse: The server's SSH host key. Compare the fingerprint with the server's (`ssh-keygen -lf /etc/ssh/ssh_host_ed25519_key.pub` on it) before enrolling it.
  - `address` string, required: `ip:port` the control plane connected to.
  - `algorithm` string, required: e.g. `ssh-ed25519`.
  - `fingerprint` string, required: `SHA256:…`, as `ssh-keygen -l` prints it.

## Other responses

- `400`: Invalid or unusable host
- `401`: Unauthorized
- `403`: Insufficient permissions
- `428`: Re-authentication required
- `502`: The server could not be reached over SSH

## Changes

- **2026-10-05** `4b228ebed583`: 1 info
  - endpoint added
- **2026-10-05** `63a80791dc58`: 1 breaking
  - api path removed without deprecation
- **2026-10-04** `0af240880dca`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/gotempsh/apis/temps/changes/nodes/ssh/host-key/post.md)

---

[API](https://skmtc.dev/gotempsh/apis/temps.md) - [All operations](https://skmtc.dev/gotempsh/apis/temps/llms.txt) - [OpenAPI document](https://skmtc.dev/gotempsh/apis/temps/revisions/3b040526eb43?raw)
