Skip to main content
Solved

data discrepancy between api and klaviyo dashboard

  • August 8, 2023
  • 1 reply
  • 96 views

Forum|alt.badge.img+3

hi, i’m using metric aggregates endpoint to get subscribed and unsubscribed numbers like this

const start_date = '2023-07-01';
const end_date = '2023-08-01';

const total_subbed_to_list = await axios.request({
  method: 'POST',
  baseURL: 'https://a.klaviyo.com/api/metric-aggregates',
  headers: {
    accept: 'application/json',
    revision: '2023-06-15',
    Authorization: `Klaviyo-API-Key ${api_key}`,
  },
  data: {
    data: {
      type: 'metric-aggregate',
      attributes: {
        metric_id: metricId['Subscribed to List'],
        interval: 'month',
        measurements: ['count'],
        filter: [`greater-or-equal(datetime,${start_date})`, `less-than(datetime,${end_date})`],
        page_size: 10000,
        timezone: 'UTC',
      },
    },
  },
});

similarly i’m getting it for ‘Unsubscribed’ and ‘Unsubscribed from List’

here are the results i’m getting from the api for july

"total_subbed_to_list": 104,

"total_unsubbed": 164,

"total_unsubbed_from_list": 0

 

but on the dashboard it shows different numbers. for unsubscribed, the number is way off, 164 from api compared to 18 in the dashboard

 

does anyone know what’s going on? is this a known issue or am i doing something wrong?

 

Best answer by Brian Turcotte

Hi @airboxr!

I have discussed this issue in other threads like here:

 

In short, this is because there can be variation/customized differences between the attribution models of the UI and API - however, our API team is aware of this and determining the best way to address it, so I’ll update the thread if anything changes. In the meantime, it may be more effective to create a ticket directly with Support for your specific issue.

 

Best,

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
  • Klaviyo Alum
  • 1393 replies
  • Answer
  • August 8, 2023

Hi @airboxr!

I have discussed this issue in other threads like here:

 

In short, this is because there can be variation/customized differences between the attribution models of the UI and API - however, our API team is aware of this and determining the best way to address it, so I’ll update the thread if anything changes. In the meantime, it may be more effective to create a ticket directly with Support for your specific issue.

 

Best,

Brian