# How to Destroy Agents Using the Control Panel on DigitalOcean Gradient™ AI Platform DigitalOcean Gradient™ AI Platform lets you build fully-managed AI agents with knowledge bases for retrieval-augmented generation, multi-agent routing, guardrails, and more, or use serverless inference to make direct requests to popular foundation models. ## Destroy an Agent Using Automation Destroying an agent using the DigitalOcean API requires the unique identifier of the agent you want to destroy. You can get a list of agents with their unique identifiers with the [`/v2/gen-ai/agents` endpoint](https://docs.digitalocean.com/reference/api/reference/gradientai-platform/index.html.md#genai_list_agents). ## How to Destroy an Agent Using the DigitalOcean API 1. [Create a personal access token](https://docs.digitalocean.com/reference/api/create-personal-access-token/index.html.md) and save it for use with the API. 2. Send a DELETE request to [`https://api.digitalocean.com/v2/gen-ai/agents/{uuid}`](https://docs.digitalocean.com/reference/api/reference/gradientai-platform/index.html.md#genai_delete_agent). ### cURL Using cURL: ```shell curl -X DELETE \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" \ "https://api.digitalocean.com/v2/gen-ai/agent/5581a586-a745-11ef-bf8f-4e013e2ddde4" ``` ## Destroy an Agent Using the Control Panel To destroy an agent from the [DigitalOcean Control Panel](https://cloud.digitalocean.com), click **Agent Platform** in the left menu, then in the **Agent Workspaces** tab, select the workspace that contains the agent you want to destroy. From the workspace’s **Agents** tab, find the agent you want to destroy, and then in the agent’s **More** menu, select **Destroy**. In the **Destroy Agent** window, type the agent’s name to confirm that you want to destroy the agent and then click **Destroy**. Destroying an agent removes all endpoints for the agent, but does not delete attached knowledge bases, custom models, or agents that the deleted agent routed to. If you are routing to the deleted agent from other agents, you need to update the existing agent’s routing instructions. ## Destroy an Agent Built Using Agent Development Kit To learn how to destroy agent deployments, see [Destroy an Agent Deployment](https://docs.digitalocean.com/products/gradient-ai-platform/how-to/build-agents-using-adk/index.html.md#destroy-an-agent-deployment).