# Delete a custom voice

`DELETE http://127.0.0.1:19470/v1/custom-voices/{id}`

Permanently deletes one of your custom voices. A voice published to
Community with more than 100 likes can only be removed through support
(request it in the app).

Authenticate with `Authorization: Bearer <API key>` (key from Settings > Developer in Voices AI Live).

## Path parameters

- `id` (path · string, required)

## Responses

### 200: Custom voice deleted

- `ok` (boolean, required)
- `error` (string): Present only when `ok` is `false`

```json
{
  "ok": true
}
```

### 401: Invalid or missing API key

- `error` (string, required): Error message

```json
{
  "error": "Invalid or missing API key"
}
```

### 404: No custom voice with this ID

- `ok` (boolean, required)
- `error` (string): Present only when `ok` is `false`

### 409: A popular Community voice that only support can remove

- `ok` (boolean, required)
- `error` (string): Present only when `ok` is `false`

### 503: The desktop app is not signed in

- `ok` (boolean, required)
- `error` (string): Present only when `ok` is `false`

```json
{
  "ok": false,
  "error": "Open the desktop app and sign in before using the local API."
}
```

### 504: The desktop app did not finish the request in time

- `ok` (boolean, required)
- `error` (string): Present only when `ok` is `false`

```json
{
  "ok": false,
  "error": "The desktop app did not respond in time. Keep it open and signed in."
}
```

## Examples

```bash
curl -X DELETE http://127.0.0.1:19470/v1/custom-voices/3f6c2a9e-8d41-4c57-9b0e-2f1d7a4c8e10 \
  -H "Authorization: Bearer $VOICES_AI_API_KEY"
```

```javascript
const res = await fetch('http://127.0.0.1:19470/v1/custom-voices/3f6c2a9e-8d41-4c57-9b0e-2f1d7a4c8e10', {
  method: 'DELETE',
  headers: {
    Authorization: `Bearer ${process.env.VOICES_AI_API_KEY}`,
  },
});
const data = await res.json();
```

```python
import os
import requests

res = requests.delete(
    "http://127.0.0.1:19470/v1/custom-voices/3f6c2a9e-8d41-4c57-9b0e-2f1d7a4c8e10",
    headers={"Authorization": f"Bearer {os.environ['VOICES_AI_API_KEY']}"},
)
print(res.json())
```
