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

# Audiencias

> Lista los segmentos de audiencia de una cuenta publicitaria de Snapchat, con su tipo, tamaño y si un impulso ya puede dirigirse a ellos.

Lista los segmentos de audiencia de una cuenta publicitaria de Snapchat: tus listas de clientes, los visitantes del sitio web que vio tu Snap Pixel y las audiencias similares (lookalikes). Usa los IDs en `targeting.audiences` o `targeting.excludedAudiences` cuando [impulses un Snap](https://www.ayrshare.com/docs/apis/ads/snapchat/boost-post.md#audiences).

<ul>
  <li>También se listan los segmentos creados en Snapchat Ads Manager, no solo los creados a través de Ayrshare.</li>
  <li>`status.ready` es `true` cuando Snapchat indica que un impulso puede dirigirse al segmento. Un segmento con muy pocas personas encontradas no está listo (`TOO_FEW_USERS`).</li>
  <li>`size` es el recuento propio de Snapchat de personas encontradas, enviado como `lower` y `upper`.</li>
  <li>Los resultados no se almacenan en caché: el tamaño y la disponibilidad de un segmento cambian mientras se llena.</li>
  <li>Snapchat define su propio tamaño de página, por lo que `limit` no tiene efecto aquí.</li>
</ul>

## Parámetros del encabezado

**Authorization** `string` *required*

[API Key](https://www.ayrshare.com/docs/apis/overview.md#authorization) of the Primary Profile.

Format: `Authorization: Bearer API_KEY`
**Profile-Key** `string`

[Profile Key](https://www.ayrshare.com/docs/apis/overview.md#profile-key-format) of a User Profile.

Format: `Profile-Key: PROFILE_KEY`

## Parámetros de consulta

**accountId** `string` *required*

El ID de tu cuenta publicitaria de Snapchat cuyos segmentos quieres listar, por ejemplo `5a0d0000-0000-4000-8000-000000000003`.

**next** `string`

Cuando la respuesta tiene `meta.pagination.hasMore: true`, envía aquí su valor `meta.pagination.next` para obtener la página siguiente. Envía los demás parámetros sin cambios: un valor `next` de otra solicitud devuelve `code: 101`.

## Respuesta

Cada audiencia tiene:

<ul>
  <li>`id`: el ID del segmento que se usa para impulsar, agregar personas o eliminar.</li>
  <li>`name`: el nombre que se muestra en Ads Manager.</li>
  <li>`type`: `customerList`, `website`, `lookalike` u `other` para un tipo de segmento que Ayrshare no crea.</li>
  <li>`size`: `{ lower, upper }`, ambos con el recuento de Snapchat, o `null` cuando Snapchat no informa ninguno.</li>
  <li>`status`: `{ ready, code, description }`. `ready` es `true` cuando un impulso ya puede dirigirse al segmento. `code` siempre es `null`. `description` es el estado de Snapchat: `READY`, `NOT_READY` o `TOO_FEW_USERS`.</li>
  <li>`created`: cuándo se creó el segmento, en ISO 8601, o `null`.</li>
</ul>

```bash cURL theme={"system"}
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/ads/snapchat/audiences?accountId=5a0d1b2c-0000-4000-8000-000000000003"
```

```javascript JavaScript theme={"system"}
const API_KEY = "API_KEY";

fetch("https://api.ayrshare.com/api/ads/snapchat/audiences?accountId=5a0d1b2c-0000-4000-8000-000000000003", {
      method: "GET",
      headers: {
        "Authorization": `Bearer ${API_KEY}`
      }
    })
      .then((res) => res.json())
      .then((json) => console.log(json))
      .catch(console.error);
```

```python Python theme={"system"}
import requests

headers = {'Authorization': 'Bearer API_KEY'}

r = requests.get('https://api.ayrshare.com/api/ads/snapchat/audiences?accountId=5a0d1b2c-0000-4000-8000-000000000003', headers=headers)

print(r.json())
```

```json 200: Success theme={"system"}
{
  "status": "success",
  "audiences": [
    {
      "id": "8c1e2f3a-0000-4000-8000-000000000101",
      "name": "Newsletter subscribers",
      "type": "customerList",
      "size": { "lower": 12000, "upper": 12000 },
      "status": { "ready": true, "code": null, "description": "READY" },
      "created": "2026-11-20T09:12:00.000Z"
    },
    {
      "id": "8c1e2f3a-0000-4000-8000-000000000102",
      "name": "Like my subscribers",
      "type": "lookalike",
      "size": { "lower": 0, "upper": 0 },
      "status": { "ready": false, "code": null, "description": "NOT_READY" },
      "created": "2026-12-01T16:40:00.000Z"
    }
  ],
  "meta": { "pagination": { "hasMore": false } }
}
```

```json 400: Missing account theme={"system"}
{
  "action": "request",
  "status": "error",
  "code": 101,
  "message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
  "details": "accountId is required."
}
```

```json 400: Snapchat refused the request theme={"system"}
{
  "action": "ads",
  "status": "error",
  "code": 370,
  "message": "Error getting audiences. Please try again.",
  "details": "Snapchat's reason"
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.