Importar contatos em lote
Changed onCria ou atualiza até 5.000 contatos por chamada. O corpo é um array. O telefone é a chave:
- Telefone novo: cria (created).
- Telefone existente com dados diferentes: atualiza (updated).
- Telefone existente com dados iguais: skipped, sem erro.
- Linha inválida: skipped e entra em errors com o índice e o motivo.
No lote, email e attributes substituem o que está gravado: enviar um contato existente sem email apaga o email dele. Para mudar só um campo, use PATCH /v1/contacts/{phone}.
importId identifica a chamada nos logs; não há rota para consultá-lo.
Permissão: CONTACTS_WRITE.
Request
- Base URLhttps://api.ararahq.com
- AuthHTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Headers
Restringe o resultado a uma conta WhatsApp Business (WABA) da organização.
Request body
Example request
[
{
"phone": "+5511999999999"
}
]Response
Resultado da importação
Example response
{
"importId": "fa1b2c3d-4567-89ab-cdef-0123456789ab",
"created": 1,
"updated": 0,
"skipped": 1,
"errors": [
{
"index": 1,
"phone": "5511888888888",
"reason": "Telefone 5511888888888 fora do formato E.164."
}
]
}Changes
- info
api tag
Contatosadded - info
api tag
contactsremoved - info
added the non-success response with the status
- info
- breaking
the response property
/became nullable for the status - breaking
the response property
/became nullable for the status - breaking
the response property
became optional for the status - breaking
the
response's property type changed fromobjecttostringfor status - breaking
removed the required property
/from the response with the status - breaking
removed the required property
/from the response with the status - warning
removed the optional property
/from the response with the status - info
added the new optional
headerrequest parameterX-Waba-Id - info
the
/request property format was generalized fromemailto no format - info
added the non-success response with the status
- info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
the response property
became required for the status - info
the
response's property default valuewas removed for the status
- breaking