Skip to main content
Solved

PYTHON API TO GET COUNT OF Bounced AND unsubscribed in recipient activity

  • June 1, 2023
  • 1 reply
  • 64 views

Forum|alt.badge.img

PYTHON API TO GET COUNT OF Bounced AND unsubscribed  in recipient activity . please tell me how to fetch it using Python API because I am able to get the clicked , open and total but not the rest

Best answer by Brian Turcotte

Hi @cyberclickgn!

Do you mind if I ask how you are currently receiving these metrics? Is it through the v3 Query Metric Aggregates endpoint?

 

If so, you are able to aggregate data by metric ID, and since bounced email and unsubscribed from list are both klaviyo metrics, you can use this endpoint and group by campaign name to achieve the desired result. You just need the metric ID for each of those metrics in your account - here’s a Community thread explaining how to get that:

 

Then, you would just make an API call to the Query Metric Aggregates endpoint, and use the filter by: Campaign Name to group the data:
 

 

I hope this helps, and thanks for using the Community!

- Brian

View original
Did this topic or the replies in the thread help you find an answer to your question?

1 reply

Brian Turcotte
Forum|alt.badge.img+37

Hi @cyberclickgn!

Do you mind if I ask how you are currently receiving these metrics? Is it through the v3 Query Metric Aggregates endpoint?

 

If so, you are able to aggregate data by metric ID, and since bounced email and unsubscribed from list are both klaviyo metrics, you can use this endpoint and group by campaign name to achieve the desired result. You just need the metric ID for each of those metrics in your account - here’s a Community thread explaining how to get that:

 

Then, you would just make an API call to the Query Metric Aggregates endpoint, and use the filter by: Campaign Name to group the data:
 

 

I hope this helps, and thanks for using the Community!

- Brian