Get email stats for emails sent via Marketing Email API in range
I'm trying to programatically grab all email stats for emails that are sent in specific range(lets say last month) via Marketing Email API. Ideally I'd want to get same info I get via Marketing Email > Analyze > Overview, where if i filter emails by month I get all the emails that are sent during that month.
When using Marketing Email API I can't seem to filter the emails in such a way to only get those that are sent during that month, using create/publish range gets me those that are created in that month and total emails sent since then which is completely off from what I'd like to get.
I'm able to see that I'm only getting back emails sent after 2019/08/31 which means I'm only getting back emails sent this month (September). Additionally, I use the https://currentmillis.com/ site to convert local time to milliseconds.
Get email stats for emails sent via Marketing Email API in range
Hi Wendy,
That's a similar query to what I've been using(I was using a range filter), I'm still getting wrong info even with your query. If I set the unix timestamp to yesterday, I'll get back 0 results but the dashboard reports 30~ emails with 300+ instances sent since yesterday. If I switch back to `publish_date__range` and use last month as a filter I'll get only 2 results(those that were initially published last mont) and it will show me total number of emails sent since then(everything up to today, not just those sent last month). Its acting as if I'm using the `created` filter instead.
Do you mind sharing with me the exact endpoint url with the parameters for the endpoint that you're getting the email statistics? As well as your portal ID?
If it's more comfortable for you, you can send me these information via DM.
if i use something like /emails/with-statistics?created__gt={1656417017652*-1}, or /emails/with-statistics?created__lt={1656417017652*+1} - i recieve correct array.
*1656417017652 - one of my email was send with this date