---
title: "Revoke an API key (set isActive to false)"
method: POST
path: "/admin/api-keys/{id}/revoke"
tags: ["Admin API Keys"]
---

# Revoke an API key (set isActive to false)

`POST /admin/api-keys/{id}/revoke`

## Path parameters

- `id` string, required

## Response `200`

- ApiKeyItemDto
  - `id` string, required — Unique identifier
  - `name` string, required — Name of the API key
  - `description` string — Description
  - `keyPrefix` string, required — Key prefix for identification (first 8 chars)
  - `isActive` boolean, required — Whether the key is active
  - `lastUsedAt` string — Last time the key was used
  - `expiresAt` string — Expiration date
  - `createdAt` string, required — Creation timestamp
  - `updatedAt` string, required — Update timestamp

---

[API](https://skmtc.dev/miaai/apis/backend-template-api.md) · [All operations](https://skmtc.dev/miaai/apis/backend-template-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/miaai/backend-template-api/revisions/2a8d88a5124f/schema)
