> ## Documentation Index
> Fetch the complete documentation index at: https://docs.vaanivoice.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Delete Agent

> Permanently delete an agent from your account

## Delete Agent

Permanently delete an agent by UUID or name. This action stops any active agent instances, cleans up configurations, and unassigns related resources.

<Warning>
  Deletion is permanent. Once an agent is deleted, its configuration and assigned prompts cannot be recovered.
</Warning>

***

## Path Parameters

<ParamField path="agent_id" type="string" required>
  The unique identifier (UUID) or system name of the agent to delete.
</ParamField>

***

## Request Example

<RequestExample>
  ```bash cURL theme={null}
  curl -X DELETE "https://api.vaanivoice.ai/api/agents/7ec4155e-0e62-440a-b983-5974f7697854" \
    -H "X-API-Key: vaani_<your_key>"
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch("https://api.vaanivoice.ai/api/agents/7ec4155e-0e62-440a-b983-5974f7697854", {
    method: "DELETE",
    headers: {
      "X-API-Key": "vaani_<your_key>",
    },
  });

  const data = await response.json();
  console.log(data);
  ```

  ```python Python (Requests) theme={null}
  import requests

  response = requests.delete(
      "https://api.vaanivoice.ai/api/agents/7ec4155e-0e62-440a-b983-5974f7697854",
      headers={
          "X-API-Key": "vaani_<your_key>",
      },
  )
  print(response.json())
  ```

  ```python Python SDK theme={null}
  from vaani_sdk import VaaniClient

  with VaaniClient(api_key="vaani_<your_key>") as client:
      # Delete by UUID or name
      result = client.agents.delete("7ec4155e-0e62-440a-b983-5974f7697854")
      print(result["message"])  # "Agent deleted successfully"
  ```
</RequestExample>

***

## Response

<ResponseExample>
  ```json Success (200 OK) theme={null}
  {
    "message": "Agent deleted successfully"
  }
  ```

  ```json Error (404 Not Found) theme={null}
  {
    "detail": "Agent not found"
  }
  ```

  ```json Error (403 Forbidden) theme={null}
  {
    "detail": "Access denied"
  }
  ```
</ResponseExample>

<ResponseField name="message" type="string">
  Confirmation message indicating the agent was successfully deleted.
</ResponseField>
