---
title: "Delete an API key"
method: DELETE
path: "/v2/directories/{directoryId}/groups/{groupId}/api-keys/{apiKeyId}"
tags: ["PrincipalGroup"]
---

# Delete an API key

`DELETE /v2/directories/{directoryId}/groups/{groupId}/api-keys/{apiKeyId}`

## Request

- Base URL: `https://global.api.konghq.com`
- URL: `https://global.api.konghq.com/v2/directories/{directoryId}/groups/{groupId}/api-keys/{apiKeyId}`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer
  - HTTP bearer
  - HTTP bearer

Permanently deletes an API key, immediately revoking its access.
This operation cannot be undone.

## Path parameters

- `directoryId` string, uuid, required
- `groupId` string, uuid, required
- `apiKeyId` string, uuid, required

## Response `204`

Success

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found

## Changes

- **2026-11-03** `72599e2b1b09`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/kong/apis/konnect-api-go-sdk/changes/v2/directories/:directoryId/groups/:groupId/api-keys/:apiKeyId/delete.md)

---

[API](https://skmtc.dev/kong/apis/konnect-api-go-sdk.md) - [All operations](https://skmtc.dev/kong/apis/konnect-api-go-sdk/llms.txt) - [OpenAPI document](https://skmtc.dev/kong/apis/konnect-api-go-sdk/revisions/3b071797f6e4?raw)
