Retrieving the Email SPAM Complaints using the API requires specific syntax for the REST API.
|Click to view all Email REST Resources
|NOTE: API is case sensitive. Make all [PARAMS] and RETURN-TYPE entries lower case.
| GET/reports/bounces — Returns a list of all email bounces received for the specified account for the specified date range, optionally filtered by sender. Including a date range is highly recommended.Method returns a maximum number of 500 email addresses at a time, so when the total sent (as returned by /reports/sent/count) is more than 500, specify the optional “starting index” parameter repeatedly, incrementing by 500 each time, until all have been retrieved.
endtime for optimal performance. Data returned will be greater than or equal to (>=)
starttime and less than (<)
HTTP Action — GET
URIs — http://emailapi.dynect.net/rest/RETURN-TYPE/reports/bounces[PARAMS]
Click for RETURN-TYPE information
apikey — Required. API key of the account with the desired information.
starttime — Required. Start date/time range in full, ISO 8601 format
endtime — Required. End date/time range in full, ISO 8601 format
sender — Email address of sender for filtering.
emailaddress — Email address of recipient for filtering.
startindex — Number indicating where to begin reporting results.
noheaders — Determines whether or not headers are included in the response. Valid values: 1 = Exclude bounce header content from the response. 0 = Default. Include headers in response.
[X-HeaderName] — Name of searchable custom X-header. X-header names are in the format X-[name of header]. X-header values are the search parameter to find in the X-header field. Be sure to url-encode the search value.
NOTE: When setting X-Header values, it is important to avoid using the greater than (<) and lesser than (>) symbols in your X-Header values. A valid X-Header value looks like this: “some_xheader_value_string_here”
bouncetype — Type of bounce for filtering. Valid Values: hard, soft, previouslyhardbounced, previouslycomplained, or suppressed.
- hard – attempted delivery fatally failed.
- soft – attempted delivery failed with transient, temporary, or
otherwise non-fatal reason.
- previouslyhardbounced – recipient had previously hard-bouncedand has been added to your suppression list.
- previouslycomplained – recipient had previously registered a spam
complaint and has been added to your suppression list.
- suppressed – recipient was manually added to the suppression list.
bouncerule – Bounce rules are apart of the
bouncetype response. They types of bounce rules are defined below.
- badmailbox – non-existent recipient.
- blockedcontent – indicates email content has been classified as spam by the receiving email provider.
- contentrelated – indicates email content has been classified as spam by the receiving email provider.
- emaildoesntexist – non-existent recipient.
- inactive – recipient inactive / mailbox disabled / etc.
- localconfigerror – Dyn’s sending MTA has a experienced an issue.
- mailboxfull – recipient mailbox is full
- messagetoolarge – total message size, including headers, exceeds the receiving email provider’s allowed maximum message size.
- notacceptingmessages – receiving email provider is not accepting messages.
- overquota – recipient mailbox is full.
- policyrelated – indicates email has been classified as spam by the receiving email provider.
- previouslycomplained – recipient previously registered a spam complaint.
- previouslyhardbounced – recipient previously hard-bounced.
- relayerror – error in transmission between Dyn and the email provider.
- remoteconfigerror – a configuration problem at the receiving email provider caused delivery to fail.
- spamrelated – email has been classified as spam by the receiving email provider.
- unclassifiedcode – unknown or unclassified reason.
|Response — Click for More Info
- 200 – OK
- The action was successful.
- 202 – Duplicate query
- A duplicate request query for the same exact information (i.e. exact same parameters) has been made while the first request is still processing. Results will be returned only to the first request.
- 451 – Missing or Invalid API Key
- The API key is either missing or incorrect. Reconfirm the API key or, if necessary, you can generate (or regenerate) an API key from the Accounts page of the Control Panel.
- 452 – Missing or Invalid Required Fields
- Any field marked “Required” must have an entry in the arguments section of the API request. This error could also come up if any values supplied are invalid (i.e., letters instead of numbers, invalid postback URL format, etc.).
- 503 – Service Unavailable
- The server is currently unavailable. It could be overloaded or down for maintenance, but this is just temporary. Try the request again in a short while.
NOTE: If user-specified data was sent out with the email through custom x-headers, and those x-header field names are currently configured with the account, those values will be included within the bounce message header itself, but also as separate return value fields.
Example Results (JSON)