---
title: "Revoke an API key"
method: DELETE
path: "/auth/keys/{key_id}"
tags: ["authentication"]
---

# Revoke an API key

`DELETE /auth/keys/{key_id}`

## Request

- Base URL: `https://api.whoisgeni.us` (the document declares no server; this is the origin it was published from)
- URL: `https://api.whoisgeni.us/auth/keys/{key_id}`
- Auth: HTTP bearer

Revoke an API key by ID.

Only the key owner can revoke their own keys. Sets is_active=False
and records the revocation timestamp.

## Path parameters

- `key_id` string, required

## Response `200`

Revocation confirmation

- ApiResponseDictStrAny
  - `data` object, nullable
  - `error` ErrorDetail: Structured error information for API error responses. Attributes: code: Machine-readable error code (e.g. "JOB_NOT_FOUND"). message: Human-readable error description. details: Optional additional context for debugging.
    - `code` string, required
    - `message` string, required
    - `details` object, nullable
  - `meta` object, nullable

## Other responses

- `401`: Unauthorized — missing or invalid API key/JWT.
- `404`: API key not found
- `422`: Validation Error

---

[API](https://skmtc.dev/whoisgeni/apis/whoisgenius.md) · [All operations](https://skmtc.dev/whoisgeni/apis/whoisgenius/llms.txt) · [OpenAPI document](https://skmtc.dev/whoisgeni/apis/whoisgenius/revisions/707f1c34f6b3?raw)
