SES

Reading Amazon SES event JSON: a field guide

A field-by-field guide to Amazon SES event notifications: the eventType and mail envelope, then bounceType, diagnosticCode and complaintFeedbackType annotated.

By Camila Restrepo ·

Every event a configuration set publishes is one JSON object with two parts: a common envelope and a body specific to what happened. Once you know the envelope’s shape, reading any event, a delivery, a bounce, a complaint, an open, comes down to knowing where the few fields that matter actually live. This is a guide to those fields, not the wiring: SES configuration sets and event destinations covers how the JSON gets to you in the first place.

The envelope every event shares

Every notification carries eventType and mail, and then one more object named for the event itself. eventType is a string: Bounce, Complaint, Delivery, Send, Reject, Open, Click, Rendering Failure, DeliveryDelay, or Subscription. Whichever value it holds, a matching object appears alongside it: eventType: "Bounce" means a bounce object is present, eventType: "Complaint" means a complaint object is present, and so on. Nothing else in the payload tells you which fields to expect; eventType is the switch.

mail is present on every event and describes the original send, not the outcome, with the field list laid out in AWS’s documented event contents:

{
  "eventType": "Bounce",
  "mail": {
    "timestamp": "2026-11-15T09:12:03.000Z",
    "messageId": "010001abcdef01-00000000-0000-0000-0000-000000000000-000000",
    "source": "campaigns@example.com",
    "sourceArn": "arn:aws:ses:us-east-1:000000000000:identity/example.com",
    "sendingAccountId": "000000000000",
    "destination": ["subscriber@example.com"],
    "headersTruncated": false,
    "headers": [
      { "name": "Subject", "value": "Your November update" }
    ],
    "commonHeaders": {
      "from": ["campaigns@example.com"],
      "to": ["subscriber@example.com"],
      "subject": "Your November update"
    },
    "tags": {
      "ses:configuration-set": ["marketing-example"]
    }
  },
  "bounce": { }
}

Two fields are easy to mix up. mail.timestamp is when the message was sent. The event body carries its own timestamp for the event itself. mail.messageId is the ID SES assigned to the message, the one that ties an event back to a specific send. Any message ID inside headers is the one on the original mail you passed to SES, which is a different value.

mail.destination lists every recipient on the original send, not just the one this event is about. The bouncedRecipients list on a bounce names the recipients that bounced.

Delivery

Most events are deliveries, and the delivery object is short:

{
  "eventType": "Delivery",
  "delivery": {
    "timestamp": "2026-11-15T09:12:04.500Z",
    "processingTimeMillis": 1500,
    "recipients": ["subscriber@example.com"],
    "smtpResponse": "250 2.0.0 OK",
    "reportingMTA": "a8-70.smtp-out.example.com",
    "remoteMtaIp": "198.51.100.12"
  }
}

smtpResponse is the receiving server’s own reply. The wording varies by receiving server and ISP, so keep it when you need to trace a delivery.

Bounce: bounceType and bounceSubType decide what happens next

A bounce event carries bounceType, bounceSubType, bouncedRecipients, timestamp, feedbackId, and reportingMTA when a delivery status notification was attached. bounceType is one of Permanent, Transient, or Undetermined, and bounceSubType narrows it, matching the full bounce subtype list AWS documents:

bounceType bounceSubType What it means
Undetermined Undetermined SES could not determine a specific reason.
Permanent General A general hard bounce. Remove the address.
Permanent NoEmail The target address does not exist. Remove the address.
Permanent Suppressed SES suppressed the send: recent history of bouncing as invalid.
Permanent OnAccountSuppressionList The address is on your account-level suppression list. Doesn’t count toward your bounce rate.
Permanent EmailValidationSuppressed The address failed your email validation settings. Doesn’t count toward your bounce rate.
Permanent OnTenantSuppressionList The address is on a tenant-level suppression list. Doesn’t count toward your bounce rate.
Transient General A general bounce. May succeed later.
Transient MailboxFull The recipient’s mailbox is full.
Transient MessageTooLarge The message exceeded a size limit.
Transient CustomTimeoutExceeded SES could not deliver within your specified time-to-live.
Transient ContentRejected The receiving server rejected the content.
Transient AttachmentRejected The receiving server rejected an attachment.

Only hard bounces count toward your bounce rate, and the three suppression subtypes above are excluded. A Transient bounce doesn’t count, however many times the same address racks one up. Bounces, complaints and suppression in SES covers what that rate threshold does to your account.

Here’s a hard bounce, annotated:

{
  "eventType": "Bounce",
  "bounce": {
    "bounceType": "Permanent",
    "bounceSubType": "General",
    "timestamp": "2026-11-15T09:14:21.000Z",
    "feedbackId": "0100000000000000-00000000-0000-0000-0000-000000000000-000000",
    "reportingMTA": "dns; mta.example.com",
    "bouncedRecipients": [
      {
        "emailAddress": "subscriber@example.com",
        "action": "failed",
        "status": "5.1.1",
        "diagnosticCode": "smtp; 550 5.1.1 user unknown"
      }
    ]
  }
}

status and diagnosticCode are the two fields that carry the actual reason, and they only appear when a delivery status notification was attached to the bounce, which is common but not guaranteed. status is a transport-independent code in X.Y.Z form; diagnosticCode is the receiving server’s own text, prefixed with the protocol that produced it (smtp; here). bounceType and bounceSubType tell you SES’s classification. diagnosticCode tells you why the receiving server actually said no, and it’s the field to read in full whenever the subtype alone doesn’t answer the question. Reading a bounce goes further into what the SMTP status codes inside diagnosticCode mean.

Now a soft bounce on the same shape:

{
  "eventType": "Bounce",
  "bounce": {
    "bounceType": "Transient",
    "bounceSubType": "MailboxFull",
    "timestamp": "2026-11-16T02:03:47.000Z",
    "feedbackId": "0100000000000000-00000000-0000-0000-0000-000000000000-000001",
    "reportingMTA": "dns; mta.example.com",
    "bouncedRecipients": [
      {
        "emailAddress": "subscriber@example.com",
        "action": "failed",
        "status": "4.2.2",
        "diagnosticCode": "smtp; 452 4.2.2 mailbox full"
      }
    ]
  }
}

bounceType: "Transient" is the signal to leave the address alone rather than suppress it. This event also doesn’t fire the moment the mailbox first refuses the mail. SES only publishes a transient Bounce once the message has soft bounced several times and SES has stopped retrying.

Complaint: complaintFeedbackType, not bounceType

A complaint event carries complainedRecipients, timestamp, feedbackId, and complaintSubType. The timestamp is when the ISP sent the complaint notification. When the reporting mailbox provider attaches a feedback report, userAgent, complaintFeedbackType, and arrivalDate are present too. complaintFeedbackType follows IANA’s registered feedback-type vocabulary, and AWS’s documented event contents lists six values: abuse, auth-failure, fraud, not-spam, other, and virus. not-spam is the one to handle separately: the reporting party doesn’t consider the message spam, which providers can use to correct an earlier miscategorization. Treat it differently from the other five.

{
  "eventType": "Complaint",
  "complaint": {
    "timestamp": "2026-11-16T14:02:11.000Z",
    "feedbackId": "0100000000000000-00000000-0000-0000-0000-000000000000-000002",
    "complaintSubType": null,
    "userAgent": "Yahoo!-Mail-Feedback-Loop-Client",
    "complaintFeedbackType": "abuse",
    "arrivalDate": "2026-11-16T14:01:05.000Z",
    "complainedRecipients": [
      { "emailAddress": "subscriber@example.com" }
    ]
  }
}

complaintSubType can be null, OnAccountSuppressionList, or OnTenantSuppressionList. The two non-null values mean SES accepted the message but didn’t attempt to send it, because the address was already on a suppression list. arrivalDate comes from the feedback report and is absent when the provider’s report didn’t include it.

complainedRecipients carries a caveat AWS states directly: most ISPs redact the address of the person who complained. The list you get is everyone who was sent the email and whose address is on the domain that issued the notification, not a confirmed identification of who clicked “report spam.”

Reject, Open, Click, DeliveryDelay and Rendering Failure

The remaining event bodies, laid out in full in AWS’s documented event contents, are smaller. reject has one field, reason, and the only documented value is Bad content, meaning SES found a virus and never attempted delivery. open and click share ipAddress, timestamp, userAgent, and isBotEvent (Likely or Unlikely), with click adding link and linkTags. deliveryDelay carries a delayType (values include InternalFailure, General, MailboxFull, SpamDetected, RecipientServerError, IPFailure, TransientCommunicationFailure, Undetermined, and SendingDeferral; the full list is in the AWS reference), a delayedRecipients list whose entries carry status and diagnosticCode the same way a bounce does, and an expirationTime for when SES will stop retrying. failure, the Rendering Failure body, carries templateName and errorMessage, and only appears on a templated send whose data didn’t match its template’s parameters.

Which fields to read first

Start with eventType. It names the object to read next and rules out every other field on the page. For a Bounce or DeliveryDelay, go straight to status and diagnosticCode on the affected recipient: the classification field tells you the category, the diagnostic text tells you the actual reason. For a Complaint, complaintFeedbackType is the whole story unless it’s not-spam, in which case treat it as a correction rather than a spam report. For everything else, timestamp tells you when it happened and mail.messageId tells you which send it happened to, which is usually enough to look up the rest.

Frequently asked questions

Does every SES event include a mail object?

Yes. Amazon SES attaches the mail object to every event type it publishes, describing the original send: its timestamp, message ID, source address, recipients, and headers. The event-specific object next to it, bounce, complaint, delivery, and so on, is what actually changes based on eventType.

Why is diagnosticCode sometimes missing from a bounce?

Amazon SES only includes diagnosticCode, status, and action on a bounced recipient when a delivery status notification (DSN) was attached to the bounce, and the DSN itself can leave diagnosticCode out. Not every mail server sends a DSN. When it’s absent, bounceType and bounceSubType are the only classification you have for that bounce.

What’s the difference between bounceType and the SMTP status code?

bounceType and bounceSubType are Amazon SES’s own classification of the bounce, one of a documented, limited set of values. The SMTP status code lives inside diagnosticCode, written by the receiving mail server in whatever format it chooses. SES’s classification tells you the category; the diagnostic code tells you the receiving server’s actual reason.

Can complaintFeedbackType be missing from a complaint event?

Yes. Amazon SES only includes complaintFeedbackType, userAgent, and arrivalDate when the reporting mailbox provider attaches a feedback report to the complaint. Some providers report a complaint without one, in which case those three fields are absent.

Do Open and Click events fire for every send?

No. Amazon SES only generates Open and Click events when open and click tracking is turned on for the send, a setting separate from adding an event destination. SES configuration sets and event destinations covers where that setting lives.

Keep reading

All posts →