---
title: "Delete an Agent"
method: DELETE
path: "/agents/{agent}"
tags: ["agents"]
---

# Delete an Agent

`DELETE /agents/{agent}`

This endpoint deletes an agent by ID. Only `offline` or `errored` agents can be removed
from the pool.

Offline or errored agents will be removed automatically after 4 hours of inactivity.

## Path parameters

- `agent` string, required

## Response `204`

Deleted.

## Other responses

- `409` — The agent is busy and can't be deleted.
- `4XX` — Client error.
- `5XX` — Server error.

---

[API](https://skmtc.net/scalr/apis/scalr-iacp-api.md) · [All operations](https://skmtc.net/scalr/apis/scalr-iacp-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/scalr/scalr-iacp-api/revisions/fc927526ad12/schema)
