How to View and Validate Your Suppression Lists

Benjamin Dean
Apr. 8, 2015 by Benjamin Dean

suppressionlistsIn this post I’m going to show you some details on our new SparkPost Suppression List API and how to test it in conjunction with our Webhooks feature to validate that recipients are being automatically added to the account’s Suppression List for the appropriate events.

What causes SparkPost to add a Recipient to your account’s Suppression List?

  • Hard Bounces
  • SPAM Complaints
  • Link Unsubscribes
  • List-Unsubscribes

Step 1: View your account’s current Suppression List state

cURL Example to GET all the recipients on your SparkPost Suppression List

Step 2: Generate a Hard Bounce using Transmissions

The /transmission response should show the recipient was accepted by SparkPost’s API.

Step 3: Verify that the recipient is now on your SparkPost account’s Suppression List

The response should now contain the replacement value you used in the /transmission property. Here is what a GET response from the Suppression List service looks like (just for reference):


If you follow the steps above and you do not see the new email added to your Suppression List, here are some steps to troubleshoot.

Webhooks to the Rescue!

I have a running Webhook consumer configured so I hopped over and started watching what was happening in my SparkPost events.

If you do not have a SparkPost webhook created and SparkPost webhook event consumer running, read our User Guide: Creating Webhooks. Make sure to configure your webhook with the bounce, spam_complaint, injection, and rejected message_event types.

Observe the Webhook events

Example of a valid hard-bounce Webhook event that triggers SparkPost to add the specific recipient to your Suppression list

Note: that if you did not generate a hard bounce, spam complaint, link unsubscribe, or list unsubscribe event type…you are NOT testing properly. Notice the type (delay) property and the bounce_class property in these two webhook events. If you don’t use one of the appropriate events to trigger an addition to the Suppression List you may start looking at webhooks like you see below and asking…“Wait a minute, that domain is totally invalid as is the user…what gives???”.

Why don’t we add these types of soft-bounces to Suppression Lists?

  • Because lack of DNS returning a valid MX record for a domain may in fact be a temporary error – so SparkPost will automatically retry sending that message again.

Hopefully this gives you a good initial overview of the power of SparkPost’s suppression lists!

Happy coding!

~ Benjamin


Related Content

This is My Architecture

Our CTO discusses some of the unique challenges we face at SparkPost in designing a scalable system that reliably handles large volumes of outbound mail.

read more

Sending Email from Google Cloud Functions

Here's a quick and easy tutorial on serverless transactional email with SparkPost and Google’s Cloud Functions on Firebase.

read more

Minds (and Rates), They Are a Changin' !

We're updating the way we calculate certain metrics rates within our UI. Learn why we're making these changes and what you can expect when you log in.

read more

Get started and start sending

Try SparkPost and see how easy it is to deliver your app’s email on time and to the inbox.

Try Free

Send this to a friend