---
title: "Revoke an SSH key"
description: "Removes one SSH public key from the account shell. A matching revocation fence ends the terminal, port-proxy and command sessions that the key's account shells opened and refuses those shells' later…"
canonical: "https://www.cool.computer/docs/api-reference/authentication/revoke-an-ssh-key"
---
# Revoke an SSH key

> Removes one SSH public key from the account shell. A matching revocation fence ends the terminal, port-proxy and command sessions that the key's account shells opened and refuses those shells' later…

```http
DELETE https://api.cool.computer/api/ssh-keys/{id}
```

Removes one SSH public key from the account shell. A matching revocation fence ends the terminal, port-proxy and command sessions that the key's account shells opened and refuses those shells' later requests; the SSH connection itself stays open until the client exits. A process that misses the fence still refuses later requests within the five-second authentication cache, but closes the sessions already open in it only when the fence reaches it. Callers: an account bearer (API key or access token).

## Authorization

- A Cool Computers API key, user access token, or claimed agent access token in the Authorization header. Follow https://www.cool.computer/auth.md for agent registration and https://www.cool.computer/authentication.md for direct user credentials.

## Parameters

- `id` (path, integer, at least 1, required): SSH key identifier from GET /api/ssh-keys.

## Responses

- `204`: The SSH key was revoked.
- `401`: Unauthorized.
- `404`: Not Found.
- `429`: Too Many Requests. If the problem code is api_request_rate_exceeded, wait for Retry-After seconds; other problem codes describe a separate limit.
- `500`: Internal Server Error.
- `default`: A machine-readable API error with a stable code and recovery instruction.

An error is an `application/problem+json` document with a stable `code`; [API errors](/docs/api-reference/errors) says how to handle one.

## Example

```sh
curl -X DELETE "https://api.cool.computer/api/ssh-keys/$PARAM_ID" \
  -H "authorization: Bearer $TOKEN"
```
