Skip to main content
Contributor IV
August 8, 2023
Solved

data discrepancy between api and klaviyo dashboard

  • August 8, 2023
  • 1 reply
  • 150 views

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?

 

    This topic has been closed for replies.
    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

    1 reply

    Brian Turcotte
    Klaviyo Alum
    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