Returns a page of unsubscriptions.
1 |
GET https://api.maileon.com/1.0/reports/unsubscriptions |
Attributes
Parameter | Default | Description |
from_date | If provided, only the unsubscriptions after or equal (including) the given date will be returned. The value of from_date must be a numeric value representing a point in time milliseconds after January 1, 1970 00:00:00 | |
to_date | If provided, only the unsubscriptions before (excluding) the given date will be returned. The value of to_date must be a numeric value representing a point in time milliseconds afterJanuary 1, 1970 00:00:00 | |
mailing_id | Multivalued parameter to filter the unsubscriptions by mailings. Each value must correspond to a mailing id. | |
ids | Multivalued parameter to filter the results by contacts. Each value must correspond to a contact id. | |
emails | Multivalued parameter to filter the results by email addresses. | |
eids | Multivalued parameter to filter the results by external ids. Each value must correspond to a contacts external id | |
source | Filters the unsubscriptions by their source. The source can be an unsubscription link (link), a reply mail (reply) or other. | |
page_index | 1 | The index of the result page. The index must be greater or equal to 1. |
page_size | 100 | The maximum count of items in the result page. If provided, the value of page_size must be in the range 1 to 1000. |
Reply
Parameter | Optional | Description |
contact | false | The available contact details, only the Maileon ID, the external ID and the Email-Address are available |
timestamp | false | The timestamp of the unsubscription as yyyy-mm-dd hh:mm:ss |
mailing_id | true | The ID of the mailing the unsubscription came from. |
source | false | The source of the unsubscription. The following values are valid:
|
Example
1 2 3 |
GET https://api.maileon.com/1.0/reports/unsubscriptions?page_index=3&page_size=5 Authorization: Basic XXXXXXXXXXXXXXX Accept: application/vnd.maileon.api+xml; charset=utf-8 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 |
Status: 200 OK Content-Type: application/vnd.maileon.api+xml Link: ... X-Pages: ... X-Items: ... <!--?xml version="1.0" encoding="UTF-8"?--> <unsubscriptions> <unsubscription> <contact anonymous="true"> <id>5647</id> <external_id nil="true"></external_id> <email>...</email> </contact> <timestamp>2013-01-17 13:18:25</timestamp> <mailing_id>14</mailing_id> <source />link </unsubscription> ... </unsubscriptions> |