---
title: "Delete SSH key"
method: DELETE
path: "/v1/ssh-keys/{key-id}"
tags: ["SSH Keys"]
---

# Delete SSH key

`DELETE /v1/ssh-keys/{key-id}`

Delete an SSH key. If the key is in use by nodes, returns 409 with the list of node IDs.
Use force=true to delete the key even if it is in use.

## Path parameters

- `key-id` integer, required

## Query parameters

- `force` boolean

## Response `204`

SSH key deleted successfully

## Other responses

- `400` — Invalid key ID
- `401` — Unauthorized
- `403` — User does not have SSH key configuration access rights
- `404` — SSH key not found
- `409` — SSH key is in use

---

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