Saltar al contenido
Esc
↑↓navegar↵abrir⌘Jvista previa

Delete contacts in bulk

Deletes up to 1000 contacts by id or by email address in one request and lists the rows actually deleted; unknown ids or addresses are skipped. Emails stay in the log; erase: true also scrubs each address from email history, event payloads and API logs, like DELETE /contacts/{id}?erase=true.

POST/contacts/batch/remove
Autorización
AuthorizationToken Bearer · headerobligatorio

A BillionSend API key (bs_…).

Cuerpo de la solicitud
obligatorioapplication/json
idsstring<uuid>[]

Contact ids to delete, up to 1000

mín. 1 elementos · máx. 1000 elementos
emailsstring<email>[]

Contact email addresses to delete, up to 1000; matched case-insensitively

mín. 1 elementos · máx. 1000 elementos
eraseboolean

Also erase each address from email history, event payloads and API logs (GDPR/LGPD); by default the send log is kept

Respuestas
200

The contacts that were deleted

dataRemoveContactResponse[]obligatorio
Mostrar propiedades
Array de RemoveContactResponse
objectstringobligatorio
Valores permitidos:contact
contactstring<uuid>obligatorio
deletedbooleanobligatorio
Valores permitidos:true
401

Missing, malformed, unknown or revoked API key

statusCodenumberobligatorio
namestringobligatorio
messagestringobligatorio
422

Validation error

statusCodenumberobligatorio
namestringobligatorio
messagestringobligatorio
429

Over the rate limit (rate_limit_exceeded, with Retry-After)

statusCodenumberobligatorio
namestringobligatorio
messagestringobligatorio
Pruébalo
Servidor
Autorización
Cuerpoapplication/json
Solicitud
curl -X POST 'https://api.billionsend.com/contacts/batch/remove' \
  -H 'Authorization: Bearer YOUR_TOKEN' \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "ids": [
    "497f6eca-6276-4993-bfeb-53cbbbba6f08"
  ],
  "emails": [
    "user@example.com"
  ],
  "erase": true
}'
Respuesta
{
  "data": [
    {
      "object": "contact",
      "contact": "ad596931-5d7c-4d2b-907e-5b64c9432eb4",
      "deleted": true
    }
  ]
}

¿Te ha resultado útil esta página?