# segmentation.lists_overview

Listas com contagem, compradores e receita. Lista de "Listas" (Contatos & Comercial > Segmentação > Listas): cada lista com emoji, total de contatos, última atualização e, quando há venda, compradores (`buyersCount`) e receita (`totalRevenue`, centavos). Das atualizadas há pouco para as mais antigas; `q` filtra pelo nome. 20 por página. As vendas somam até 1 000 membros por lista.

- Endpoint: `POST https://app.atomiks.com.br/api/v1/segmentation.lists_overview` (corpo JSON)
- Quem pode chamar: membro da conta
- Escopo da chave: `crm:read`
- Grava dados: não
- Pela chave de API: sim
- Ferramenta MCP: `segmentation_lists_overview`
- Ficha em JSON: `https://app.atomiks.com.br/api/v1/openapi.json` (operationId `segmentation.lists_overview`)

## Entrada

| Campo | Tipo | Obrigatório | Nota |
|---|---|---|---|
| `q` | string | não |  |
| `page` | integer | não |  |
| `perPage` | integer | não |  |

<details><summary>JSON Schema</summary>

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "q": {
      "type": "string",
      "maxLength": 80
    },
    "page": {
      "type": "integer",
      "minimum": 1,
      "maximum": 10000
    },
    "perPage": {
      "type": "integer",
      "minimum": 1,
      "maximum": 100
    }
  }
}
```

</details>

## Exemplo

```bash
curl -X POST https://app.atomiks.com.br/api/v1/segmentation.lists_overview \
  -H "Authorization: Bearer $ATOMIKS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"page":1,"perPage":20}'
```

CLI:

```bash
node cli/atomiks.mjs segmentation.lists_overview --json '{"page":1,"perPage":20}'
```

MCP: ferramenta `segmentation_lists_overview` com a mesma entrada.

## Saída

Sucesso: `{"data": ...}` com o formato abaixo.

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "type": "object",
  "properties": {
    "items": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "emoji": {
            "type": [
              "string",
              "null"
            ]
          },
          "leadCount": {
            "type": "number"
          },
          "updatedAt": {
            "type": "string"
          },
          "createdAt": {
            "type": "string"
          },
          "source": {
            "type": [
              "string",
              "null"
            ]
          },
          "buyersCount": {
            "type": "number"
          },
          "totalRevenue": {
            "type": "number"
          }
        },
        "required": [
          "id",
          "name",
          "emoji",
          "leadCount",
          "updatedAt",
          "createdAt",
          "source",
          "buyersCount",
          "totalRevenue"
        ],
        "additionalProperties": false
      }
    },
    "total": {
      "type": "number"
    },
    "countPages": {
      "type": "number"
    }
  },
  "required": [
    "items",
    "total",
    "countPages"
  ],
  "additionalProperties": false
}
```

## Erros

`{"error": {"code", "message", "requestId"}}`. Códigos: `invalid_input` (400), `unauthorized` (401), `forbidden` / `account_pending` / `scope_missing` (403), `not_found` (404), `limit_reached` (409), `internal` (500).
