Add multiple email addresses to a suppression group in bulk using the AutoSend API.
curl --request POST \
--url 'https://api.autosend.com/v1/suppression-groups/emails/suppress' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"emails": ["[email protected]", "[email protected]"],
"groupId": "AB12C3",
"reason": "unsubscribed",
"isGlobal": false
}'
{
"success": true,
"data": {
"suppressed": 2
}
}
curl --request POST \
--url 'https://api.autosend.com/v1/suppression-groups/emails/suppress' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"emails": ["[email protected]", "[email protected]"],
"groupId": "AB12C3",
"reason": "unsubscribed",
"isGlobal": false
}'
{
"success": true,
"data": {
"suppressed": 2
}
}
<token>, where <token> is your auth token.unsubscribed, bounced, spam_complaint). Stored on each entry for reporting.true, adds the entries to the global suppression list rather than a project-specific group.Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
"AB12C3"
"unsubscribed"
false
curl --request POST \
--url 'https://api.autosend.com/v1/suppression-groups/emails/suppress' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"emails": ["[email protected]", "[email protected]"],
"groupId": "AB12C3",
"reason": "unsubscribed",
"isGlobal": false
}'
{
"success": true,
"data": {
"suppressed": 2
}
}