Get Activity Change History

Lets you retrieve the history of changes for multiple activities within a specified date range. The response returns activity details as well as new and old field values within the given date range.

  • The “FromDate” and “ToDate” parameters are mandatory.
  • The “ActivityEvents” parameter is optional. You can pass multiple activity event codes here. If you don’t pass this parameter, all activity events will be returned.
  • “Paging” parameters are optional. The default page size is 25. Maximum allowed is 1000.

 

API URL

POST
https://{host}/v2/ProspectActivity.svc/RetrieveActivityChange?accessKey=AccessKey&secretKey=SecretKey
Copy URL

Request

JSON Body/Payload

Content-Type: application/json

{
  "Parameter": {
    "FromDate": "2018-09-13 18:29:59",
    "ToDate": "2018-09-14 10:45:59",
    "ActivityEvents": [
      322,
      121
    ]
  },
  "Paging": {
    "PageIndex": 1,
    "PageSize": 100
  }
}

JSON Properties

Parameter Description
FromDate

The start date you want to retrieve activity changes from.

ToDate

The end date you want to retrieve activity changes till.

ActivityEvents

The code for activity events. Find it by navigating to My Account>Settings>Customizations>Activities and Scores>Cutom Activities & Scores

PageIndex

Refers to the page number (“1” represents the first page).

PageSize

Refers to the number of records to be displayed.

Response

200 OK

Content-Type: application/json

{
  "RecordCount": 1,
  "Activities": [
    {
      "Activity": {
        "ProspectActivityId": "54df288a-cd8f-456c-adb6-dc0c9de9f54f",
        "RelatedProspectId": "93553424-b53b-476b-ae25-77e1649b41bd",
        "ActivityType": "2",
        "ActivityEvent": "322",
        "Score": "2",
        "CreatedOn": "2018-09-14 10:45:00",
        "CreatedBy": "c7b539c1-3f7f-11e6-bec9-22000aa5088d",
        "ModifiedOn": "2018-09-14 10:48:12",
        "ModifiedBy": "c7b539c1-3f7f-11e6-bec9-22000aa5088d",
        "ActivityDate": "2018-09-14 10:45:19",
        "mx_Custom_5": "sdvdxv",
        "Status": "invalid",
        "CreatedWithInTimeRange": "Yes"
      },
      "Audit": [
        {
          "ModifiedBy": "c7b539c1-3f7f-11e6-bec9-22000aa5088d",
          "ModifiedOn": "2018-09-14 10:45:30",
          "New": {
            "mx_Custom_5": "sdvdxv"
          },
          "Old": {
            "mx_Custom_5": ""
          }
        },
        {
          "ModifiedBy": "c7b539c1-3f7f-11e6-bec9-22000aa5088d",
          "ModifiedOn": "2018-09-14 10:48:12",
          "New": {
            "Status": "invalid"
          },
          "Old": {
            "Status": "Inactive"
          }
        }
      ]
    }
  ]
}

HTTP Response Code

Code Description
200 OK

This is the status code for successful API call.

401 Unauthorized

The API call was made with invalid access credentials. Check your AccessKey and SecretKey.

400 Bad Request

The message body on the request is not as per API specification. Make sure that content type is set to “application/json” and the JSON body has correct attribute names and structure.

404 Not Found

The API could not be found. Please check the API signature.

429 Too Many Requests

API calls exceeded the limit of 25 in 5 second(s)

500 Internal Server Error

The API called failed. There could be many reasons for it. Check the exception message to get more details.