Skip to content

Get subscriber's events

Returns a list of actions that this subscriber has performed.

HTTP method: GET

https://api.sender.net/v2/subscribers/{email}or{phone}or{ID}/events?actions=["got"]


ParameterTypeDescription
Email, phone number, or IDstring requiredSubscriber’s email address, phone number, or ID
actionsarray requiredThe value must be one of opened, bounced, clicked, unsubscribed or got.

const url = new URL("https://api.sender.net/v2/subscribers/{email}or{phone}or{ID}/events?actions=["got"]");
let headers = {
"Authorization": "Bearer [your-token]",
"Content-Type": "application/json",
"Accept": "application/json",
};
fetch(url, {
method: "GET",
headers,
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error('Error:', error));

Example Response
{
"email": {
"got": [
{
"campaign_id": "bojJ7k",
"subscriber_id": "o2lk68Y",
"title": "Example email subject",
"created_at": "2021-05-12 05:09:29"
},
{
"campaign_id": "bkrXzE",
"subscriber_id": "o2lk68Y",
"title": "Follow up campaign example subject",
"created_at": "2021-05-11 10:46:15"
},
{
"campaign_id": "aKL9PM",
"subscriber_id": "o2lk68Y",
"title": "Example campaign subject",
"created_at": "2021-05-11 09:02:38"
},
{
"campaign_id": "dwKrKJ",
"subscriber_id": "o2lk68Y",
"title": "test-campaign",
"created_at": "2021-04-20 04:41:51"
}
]
},
"sms": [],
"temail": {
"sent": []
},
"sms_campaign": {
"sent_count": 0,
"clicked_count": 0,
"delivered_count": 0,
"failed_count": 0,
"unsubscribed_at": null,
"unsubscribed": 0
},
"email_campaign": {
"sent_count": 4,
"opened_count": 0,
"clicked_count": 0,
"unsubscribed": 0,
"bounced": 0,
"spam_reported": 0
}
}