# Revoke an agent's access

> Revoke an agent's access: reference page for this CustomDomain™ API operation in the agents group. Covers parameters, request body, responses and error codes.

Source: https://docs.customdomain.ai/docs/api-reference/agents/revokeAgentGrant

## `DELETE https://api.customdomain.ai/v1/agent/grants/{id}`

Ends the grant and kills its refresh tokens; the agent's access token stops working within its 15 minute life. A grant of another workspace answers `404`. The workspace's owners and admins are told once (a repeat is quiet), and the audit log records `agent.revoked`. Needs `agent:manage`.

### Authentication

`apiKey`

### Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `id` | path | string | yes |  |

### Responses

| Status | Description |
| --- | --- |
| `204` | Revoked |
| `401` | Error envelope: {code, title, details}. |
| `403` | Error envelope: {code, title, details}. |
| `404` | Error envelope: {code, title, details}. |
| `503` | Error envelope: {code, title, details}. |

The full specification is served at `GET https://api.customdomain.ai/v1/openapi.json`.
