contacts.bulk_lists
Pôr ou tirar vários contatos de listas. target é {ids} (contatos escolhidos) ou {filter, q?, excludeIds?} ("todos os que casam", mesmo filtro e busca de contacts.list). Só entram contatos que o membro vê e fora da lixeira; acima de 10 000 dá invalid_input (refine o filtro). add e remove são ids de lista (até 100 cada). Idempotente. count = contatos do alvo.
- Endpoint:
POST https://app.atomiks.com.br/api/v1/contacts.bulk_lists(corpo JSON) - Quem pode chamar: membro da conta
- Escopo da chave:
crm:write - Grava dados: sim
- Pela chave de API: sim
- Ferramenta MCP:
contacts_bulk_lists - Ficha em JSON:
https://app.atomiks.com.br/api/v1/openapi.json(operationIdcontacts.bulk_lists)
Entrada
| Campo | Tipo | Obrigatório | Nota |
|---|---|---|---|
target | object | sim | |
add | string (uuid)[] | não | |
remove | string (uuid)[] | não |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"target": {
"anyOf": [
{
"type": "object",
"properties": {
"ids": {
"minItems": 1,
"maxItems": 10000,
"type": "array",
"items": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
}
}
},
"required": [
"ids"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"filter": {
"maxItems": 200,
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"maxLength": 64
},
"order": {
"type": "integer",
"minimum": 0,
"maximum": 1000
},
"field": {
"type": "string",
"maxLength": 60
},
"operator": {
"type": "string",
"maxLength": 30
},
"negation": {
"default": false,
"type": "boolean"
},
"parentId": {
"anyOf": [
{
"type": "string",
"maxLength": 64
},
{
"type": "null"
}
]
},
"valueString": {
"anyOf": [
{
"type": "string",
"maxLength": 4000
},
{
"type": "null"
}
]
},
"valueNumber": {
"type": [
"number",
"null"
]
},
"valueDate": {
"anyOf": [
{
"type": "string",
"maxLength": 40
},
{
"type": "null"
}
]
},
"valueBool": {
"type": [
"boolean",
"null"
]
},
"valueUuid": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
{
"type": "null"
}
]
}
},
"required": [
"field",
"operator"
],
"additionalProperties": false
}
},
"q": {
"type": "string",
"maxLength": 100
},
"excludeIds": {
"maxItems": 10000,
"type": "array",
"items": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
}
}
},
"required": [
"filter"
],
"additionalProperties": false
}
]
},
"add": {
"maxItems": 100,
"type": "array",
"items": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
}
},
"remove": {
"maxItems": 100,
"type": "array",
"items": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
}
}
},
"required": [
"target"
]
}Exemplo
curl -X POST https://app.atomiks.com.br/api/v1/contacts.bulk_lists \
-H "Authorization: Bearer $ATOMIKS_API_KEY" \
-H "Content-Type: application/json" \
-d '{"target":{"filter":[],"q":"maria"},"add":["00000000-0000-0000-0000-000000000000"]}'CLI:
node cli/atomiks.mjs contacts.bulk_lists --json '{"target":{"filter":[],"q":"maria"},"add":["00000000-0000-0000-0000-000000000000"]}'MCP: ferramenta contacts_bulk_lists com a mesma entrada.
Saída
Sucesso: {"data": ...} com o formato abaixo.
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"count": {
"type": "number"
}
},
"required": [
"count"
],
"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).