# List voices

`GET` `https://goblins-call-api.onrender.com/v1/providers/voices`

Returns a page of the voice library, which you can search and narrow by language and gender. Use a voice’s `id` as `voice.speaker` on an agent.

Needs a [workspace API key](https://www.cracklehq.com/docs/authentication).

## Query parameters

- `q` (string, optional): Searches voice names and descriptions.
- `language` (string, optional): A language from the catalog (`hinglish`) or an ISO code (`hi`).
- `gender` (enum, optional, feminine · masculine · gender_neutral): Only voices of this gender.
- `limit` (integer, optional, 1–100; default 100): How many voices to return.
- `after` (string, optional): The `nextPage` of the page before.
- `id` (string, optional): Looks up this one voice instead of listing.

## Response

- `voices[].preview` (boolean): Whether the voice has a sample clip to play.
- `nextPage` (string): Pass as `after` for the next page; `null` on the last one.

## Errors

- `503`: The voice library is not available right now.

Every request can also answer `401`, `429` and `500`: see [Errors](https://www.cracklehq.com/docs/errors).

Request:

cURL:

```bash
curl "https://goblins-call-api.onrender.com/v1/providers/voices?language=hi&gender=feminine&limit=10" \
  -H "Authorization: Bearer $CRACKLE_API_KEY"
```

Node.js:

```js
const response = await fetch('https://goblins-call-api.onrender.com/v1/providers/voices?language=hi&gender=feminine&limit=10', {
  headers: {
    Authorization: `Bearer ${process.env.CRACKLE_API_KEY}`,
  },
});
if (!response.ok) throw new Error(await response.text());
const data = await response.json();
```

Python:

```python
import os
import requests

response = requests.get(
    "https://goblins-call-api.onrender.com/v1/providers/voices?language=hi&gender=feminine&limit=10",
    headers={"Authorization": f"Bearer {os.environ['CRACKLE_API_KEY']}"},
    timeout=30,
)
response.raise_for_status()
data = response.json()
```

Response · 200 OK:

```json
{
  "voices": [
    {
      "id": "…",
      "name": "…",
      "tagline": "…",
      "description": "…",
      "gender": "feminine",
      "language": "hi",
      "preview": true
    }
  ],
  "hasMore": true,
  "nextPage": "…"
}
```

Source: https://www.cracklehq.com/docs/reference/voices/list
