Using ctctWrapper.php searchByEmail and listContactEvents help.

BradD6
Regular Participant

Using ctctWrapper.php searchByEmail and listContactEvents help.

Hi Everybody,

 

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,

 

Brad

1 REPLY 1
bsoder
Employee

Hello Brad,

 

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.

 

Regards,

Benjamin Soder
NOC Analyst
Constant Contact
Developer Portal

View API documentation, code samples, get your API key.

Visit Page