Blacklisted Subscriber

It may happen that, occasionally, your customers are unhappy receiving your SMS, Email, WhatsApp or RCS messages. And in times of data protection regulations and e-privacy changes, no one wants to mess with an unhappy customer, even malicious users or users with inappropriate behavior may also appear that can cause problems for your campaigns.

One way to ensure particular recipients won’t be included in any upcoming campaigns (single or bulk messages) is to exclude them using the Blacklisted Subscriber API. Simply add selected phone numbers or emails to the blacklist.

Therefore, Blacklist is a list of numbers and emails that is tied to a specific sender. All messages sent using any API credentials from this account, are passed through this list. If the number is in the list, the message is not sent. It applies both to API calls and messages sent from the platform.

You can blacklist subscribers based on the delivery channel on which users do not want to receive messages:

  • SMS
  • Email
  • WhatsApp
  • RCS

Adding Subscriber to Blacklist

This endpoint allows you to add a subscriber to the blacklist in the same request.

According to the type of delivery channel, the subscriber can be added to the blacklist with its corresponding Sender.

For example, there are 3 delivery channels configured with their corresponding Senders:

ChannelSenders
SMS- 52811
- 141555549
Email- [email protected]
WhatsApp- CompanyEliPackage

As shown in the table above, let's unsubscribe (add to the blacklist) an end user from the “528811” sender number that corresponds to the SMS delivery channel. Once added to the blacklist, this end user won't receive anymore messages via SMS from the “52881” sender, but He/She can still receive messages from the “141555549”. That is, if the subscriber is added in different senders, regardless of the delivery channel, the end user will be able to receive messages. Therefore, each sender has its own blacklist.

HTTP Request: POST /subscribers

In the following API call example, we are going to add 1 subscriber, whose phone number is “+525500000000”, to the blacklist from the “141555549” sender number that corresponds to the SMS delivery channel.

{
  "to": "+525500000000",
  "reason": "UNSUBSCRIBED",
  "type": "SMS",
  "from": "141555549",
  "listType": "BLACK"
}

The parameters presented in the request body example when adding the subscriber to the blacklist are the following:

Parameter Required Description
to Yes

Enter the subscriber data you want to add to the blacklist according to the sending entity and delivery channel.

To add a subscriber to the blacklist via SMS, WhatsApp or RCS, you need to provide the phone number of the subscriber.

To add a subscriber to the blacklist via Email, you need to provide the email address of the subscriber.

reason Yes

Enter the reason why the subscriber is added to the blacklist.

type Yes

Type of delivery channel, in which the subscriber will no longer receive messages.

  • "SMS"
  • "EMAIL"
  • "WHATSAPP"
  • "RCS"

from Yes

Enter the sending identity (Sender) according to the delivery channel.

Each sender has its own blacklist.

listType No

Type of list to which the subscriber is added.

  • "BLACK"

When you added the subscriber to the blacklist, the response body contains the following data:

{
  "meta": {
    "timestamp": 1691605563383,
    "transactionId": "7933b9dc-6b1f-46b7-9c77"
  },
  "data": {
    "id": "64d3da3b27e58a0e93eefff7",
    "to": "+525500000000",
    "reason": "UNSUBSCRIBED",
    "date": "2023-08-09T18:26:03.384279468Z"
  }
}

Parameters presented in the response body example when adding the subscriber the blacklist are the following:

Parameter Description
data Data contained once the subscriber was added to the blacklist.
data.id Unique identifier of the blacklisted subscriber.
data.to

Subscriber data you want to add to the blacklist according to the sending entity and delivery channel.

To add a subscriber to the blacklist via SMS, WhatsApp or RCS, you need to provide the phone number of the subscriber.

To add a subscriber to the blacklist via Email, you need to provide the email address of the subscriber.

data.reason

The reason why the subscriber was added to the blacklist.

data.date

Date when the subscriber was added to the blacklist.

Getting Subscriber from Blacklist

When the subscriber has been added to a specific list, we proceed to get the information of the subscriber that the blacklist contains. That is, this endpoint allows you to get a subscriber from a blacklist that belongs to a specific sender.

HTTP Request: GET /subscribers

To get subscriber information from a blacklist, you need to provide the following required parameters:

Required ParameterDescription
typeType of delivery channel, in which the subscriber no longer receives messages.

- "SMS"

- "EMAIL"

- "WHATSAPP"

- "RCS"
fromSending identity (Sender) according to the delivery channel.

Each sender has its own blacklist.
listTypeType of list to which the subscriber is added.

- "BLACK": Blacklist.
toSubscriber data added to the blacklist according to the sending entity and delivery channel.

Enter the Phone number of the subscriber in case the subscriber was added to the blacklist via SMS, WhatsApp or RCS.

Enter the email address of the subscriber in case the subscriber was added to the blacklist via Email.

Once executed the API call, from the response body you can get the unique identifier ("data.id") of the blacklisted subscriber.