Skip to content
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
Cannot retrieve contributors at this time

REST API: GET destinations (MS mailing)

You can retrieve the destinations for an emailing by sending an HTTP GET call to the following URL:$id/destinations?access_token=xxxx

Where the $id should be replaced with the ID of the emailing. This method also support the use of the fields parameter for the timestampsent field.

Optional parameters

  • Unsubscribed: Set to 'true' for retrieving the unsubscribed destinations.

Returned fields

The method returns a JSON object with several destinations under the 'data' property. For each destination the following information is available:

  • ID: Unique ID of the destination.
  • mailing: ID of the mailing sent to this destination.
  • timestampsent: Timestamp of sending to the destination.
  • profile: Profile ID of the destination.
  • subprofile: Subprofile ID of the destination.

JSON example

The destination might look something like this:

   "timestampsent":"2015-06-08 13:53:45",

PHP example

This script demonstrates how to use this API method:

// dependencies

// change this into your access token
$api = new CopernicaRestAPI("your-access-token", 3);

// execute the call

This example requires the REST API class.

More information