APIs & Integrations

Frapsi
Participant

Email Event API fails

SOLVE

Hi,

 

I want to get all email events for a list of certain campaigns using the Email Event API. I am using KNIME Analytics Platform to perform the requests within a loop which requests for each campaign id in the given list get requests and uses the offset parameter to page through all events.

At some point the get request fails. When I reset the loop and execute it again it fails at a different point, so it doesn't seem to be a specific event/campaign id that causes the problem.

I already thought about rate limits and therefore increased the waiting time between requests up to 2 seconds. Didn't work.

 

Any idea what might be causing this?

Thanks in advance.

0 Upvotes
1 Accepted solution
Frapsi
Solution
Participant

Email Event API fails

SOLVE

Hi Wendy,

 

thanks for your reply.

I think I found the problem meanwhile. I get always a 502 status from my failed requests and I found some posts about 5xx error messages here in the community, e.g. https://community.hubspot.com/t5/APIs-Integrations/502-Bad-Gateway-errors/td-p/275949 .

So I built another loop in my workflow to re-try the failed request and until now everything works fine even though this is not best practice...

 

 

 

 

View solution in original post

2 Replies 2
WendyGoh
HubSpot Employee
HubSpot Employee

Email Event API fails

SOLVE

Hey @Frapsi,

 

In order for me to further troubleshooting this, could you share the following with me:

 

1. Portal ID

2. The exact request url

3. The full error message

0 Upvotes
Frapsi
Solution
Participant

Email Event API fails

SOLVE

Hi Wendy,

 

thanks for your reply.

I think I found the problem meanwhile. I get always a 502 status from my failed requests and I found some posts about 5xx error messages here in the community, e.g. https://community.hubspot.com/t5/APIs-Integrations/502-Bad-Gateway-errors/td-p/275949 .

So I built another loop in my workflow to re-try the failed request and until now everything works fine even though this is not best practice...