Retrieve a list of activities

get

/api/REST/1.0/data/activities/contact/{id}

Retrieves all activities that match the criteria specified by the request parameters. Note that the query parameters endDate, startDate, and type are required. See activity detail values for more information about the different activity detail values for each asset type.

Request

Supported Media Types
Path Parameters
Query Parameters
  • Maximum number of entities to return. Must be less than or equal to 1000 and greater than or equal to 1.
  • The end date and time (10 digit integer Unix time).
  • The start date and time (10 digit integer Unix time).
  • The type of activity you wish to retrieve from the specified contact: emailOpen, emailSend, emailClickThrough, emailSubscribe, emailUnsubscribe, formSubmit, webVisit, or campaignMembership.
Back to Top

Response

Supported Media Types

200 Response

OK
Body ()
Root Schema : Activity
Type: object
Title: Activity
Show Source
Nested Schema : details
Type: array
An array of detail values, specific to individual activity types.
Show Source
Nested Schema : items
Type: object
Additional Properties Allowed
Show Source

204 Response

No matching activities were found in the search.

400 Response

Bad request. See Status Codes for information about other possible HTTP status codes.

401 Response

Unauthorized. See Status Codes for information about other possible HTTP status codes.

403 Response

Forbidden. See Status Codes for information about other possible HTTP status codes.

404 Response

The requested resource was not found. See Status Codes for information about other possible HTTP status codes.

500 Response

The service has encountered an error. See Status Codes for information about other possible HTTP status codes.
Back to Top

Examples

Retrieve the first 2 "emailOpen" activities associated with the contact id #1 in the given time frame:


GET /api/REST/1.0/data/activities/contact/1?type=emailOpen&startDate=1262304000&endDate=1433808000&count=2
			

Response:


[
  {
    "type": "Activity",
    "activityDate": "1424813164",
    "activityType": "emailOpen",
    "asset": "12",
    "assetType": "email",
    "contact": "2",
    "details": [
      {
        "Key": "EmailWebLink",
        "Value": ""
      },
      {
        "Key": "IPAddress",
        "Value": "10.156.127.40"
      },
      {
        "Key": "EmailName",
        "Value": "test"
      },
      {
        "Key": "EmailRecipientID",
        "Value": "88886ee8-fee9-4cee-85e8-2e16af3a5b53"
      },
      {
        "Key": "DeploymentId",
        "Value": "12345"
      },
      {
        "Key": "EmailContent",
        "Value": null
      },
      {
        "Key": "SubjectLine",
        "Value": "test"
      }
    ],
    "id": "15"
  },
  {
    "type": "Activity",
    "activityDate": "1424811308",
    "activityType": "emailOpen",
    "asset": "12",
    "assetType": "email",
    "contact": "2",
    "details": [
      {
        "Key": "EmailWebLink",
        "Value": ""
      },
      {
        "Key": "IPAddress",
        "Value": "10.156.127.40"
      },
      {
        "Key": "EmailName",
        "Value": "test"
      },
      {
        "Key": "EmailRecipientID",
        "Value": "88886ee8-fee9-4cee-85e8-2e16af3a5b53"
      },
      {
        "Key": "DeploymentId",
        "Value": "58921"
      },
      {
        "Key": "EmailContent",
        "Value": null
      },
      {
        "Key": "SubjectLine",
        "Value": "test"
      }
    ],
    "id": "14"
  }
]
			
Back to Top