Blog Add custom events to contact timeline via API

Add custom events to contact timeline via API

You can add custom events to your contact’s timeline and activity log using the addNewActivity API call. This is beneficial if you would like to log data from your own platform to your account, such as support tickets and more.nnTo add a custom event, use the function below using CURL or PHP and replace the data with your own API KEY  as well as the contact’s id:n

 '{YOUR_API_KEY}');n	n    $app = new EmailMarketingWS($user_key);n    $parms = array(n        'id' => 'xxxxx',                              // Replace with the Contact IDn        'description' => 'this is my first activity', // Replace the Description with your Activity's description.n        'datetime' => '2018-08-23 18:00',             // Replace with the Date and Time the Activity is recordedn    );nn    $results = $app->addNewActivity($parms);nn    print_r($results);n?>n

nThe end result will look like this:nnnn nnNote that you can use the activity filter to preview the custom events within the contact’s timeline.n

[lore_button label=”Get Started” link=”app.aoaassociates.com/Login” size=”regular” style=”default”]

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post