I am trying to trigger a simple deal update via a custom event that we want to fire from our app’s server. I am getting {“success”:1,“message”:“Event spawned”} as a response but nothing seems to happen on the dashboard.
This is the python script I am using to test this at the moment :
params = [
(‘actid’, ‘MY_ACT_ID’),
(‘key’, ‘MY_EVENT_KEY’),
(‘event’, ‘__survey_done’),
(‘eventdata’, ‘’),
(‘visit’, json.dumps([(‘email’, user_email)])) ← I am not too sure about this part at all …
]
r = requests.post(url=‘https://trackcmp.net/event’, params=params, headers={‘Content-Type’: ‘application/x-www-form-urlencoded’})
I always recommend users test things out with a tool like POSTman or vanilla curl before digging into language specific debugging.
One thing I notice though, is I don’t see the email anywhere, so you might be successfully sending events into AC, but they are not attaching to any user.
You are absolutely right, I don’t think active campaign is receiving the contact, but I am not sure exactly how I am supposed to provide it.
In the code snippet I sent, the email is dynamically fed into the visit parameter under ‘email’. This is one of many different combinations I tried to send the contact email with no luck.
My issue was that I thought I could just send the contact email via my event’s parameters and then the automation would get the contact email from the event.
I made a post request to add the contact to the automation contact list (via automation_contact_add action) and then it worked.