Curious about what bounce webhooks are and how you can start using them to track bounces? Read on for more information on how bounce webhooks work, how you can set your bounce webhook URL in your Postmark settings, and what some of the potential uses are.
What does a bounce webhook do?
Postmark’s bounce webhooks allow you to receive real-time notifications every time a message you send through Postmark generates a bounce. These bounce notifications are sent as an HTTP POST to a URL you set in your Postmark Server settings. Bounce webhook notifications include information like the sender, recipient, subject, and reason for the bounce.
The HTTP POSTs containing the bounce information are sent as JSON with this format:
"Name": "Hard bounce",
"Description": "The server was unable to deliver your message (ex: unknown user, mailbox not found).",
"Details": "Test bounce details",
"Subject": "Test subject",
"Content": "<Full dump of bounce>",
What can I use bounce notifications for?
Bounce webhook events can be used in many ways, such as:
- Notifying senders of a bounced email
- Spotting bounce trends
- Preventing further sending to bad addresses from your application
- Keeping track of which addresses bounced so the recipients can be contacted through another channel
How you end up using the bounce notifications is up to you. You can develop any additional functionality you need in your bounce webhook URL application code for acting on bounce notifications you receive.
What do I need to receive the bounce notifications?
Before setting your bounce webhook URL in your Postmark Server settings, use our
for help with developing the code for receiving the bounce webhook events with. If you are not familiar with receiving HTTP POSTs, you may need the assistance of a developer for developing and hosting the application that receives and processes the bounce notifications. Save some time and get going faster by utilizing our Postmark labs
open source webhooks project
, that lets you quickly start using all of Postmark’s webhooks.
How do I set my bounce webhook URL in Postmark?
When your URL is hosted and able to receive and process bounce webhook notifications, you are ready to set that URL in your Postmark Server settings.
- Open up your Server in Postmark you want to receive bounce webhook notifications for
- Click Webhooks
- Enter in your bounce webhook URL in the Webhook URL field
Once your URL is entered, click the
bounce checkbox and then test your webhook URL to confirm everything is working. Save your changes once you are done testing the URL.
Now you are ready to take advantage of this powerful feature and begin using bounce webhooks to receive bounce notifications today.