Overview

Integration

User guide

API reference

Webhooks

SMTP API Error

What is an SMTP API Error #

SMTP API Error is an internal rejection error that Postmark will respond with when you attempt to send via SMTP to a recipient who was previously suppressed due to a Bounce, Spam Complaint, Unsubscribe or a Manual Suppression.

This is applicable only to messages sent via SMTP, and is enabled on Server level in Postmark. If you're sending via our API the response would be returned in the API response.

Set SMTP API Errors for a Server #

You will need to enable the SMTP API Errors for each Server you want to receive them for. This can be done only via API, and not in the UI.

You will need to authenticate the request with Account API, and connect to https://api.postmarkapp.com/servers/ endpoint, while appending the SERVERID to that URL.

curl "https://api.postmarkapp.com/servers/SERVERID" \
  -X PUT \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -H "X-Postmark-Account-Token: ACCOUNTAPITOKEN" \
  -d '{
  "EnableSmtpApiErrorHooks":true,
}'

SMTP API Error Data #

At any instance of trying to send to a suppressed recipient, you'll receive an error in the Postmark UI:


SMTP API Error

Testing the SMTP API Error #

To test an SMTP API Error, first:

1. Suppress a recipient
2. Send a message to the suppressed recipient using the SMTP service you connected to Postmark

How can you use SMTP API Error #

SMTP API Error will notify you when you try contacting an inactive recipient. This can help you keep your external lists in sync with Postmark Suppression lists.

If you have reason to believe that the recipient is no longer inactive, and is ready to receive your messages, you can reactivate the recipient and continue to send to them.