New to the Constant Contact API. I was wondering how get the opens and clicks of a contact (found by email) using searchByEmail and listContactEvents.
I assume I create a contact with the information returned from $ContactsCollection->searchByMail($email) but don't know how.
I then run the contact through $ContactsCollection->listContactEvents($contact,'clicks,opens etc') then use
$contact-getOpens(), getClicks() etc to obtain the information I need.
Thanks in advance,
The way you are doing it should work. What exactly is happening when you do it? Do you get an error? The reports should be placed in the contact object which you can then pull out to display.
View API documentation, code samples, get your API key.