Skip to main content

Hi - There doesn’t seem to be a dedicated create metric endpoint. From what I can decipher from the documentation is that the “event” endpoint (https://a.klaviyo.com/api/events) is what is used to create a metric by passing the name at `data.attributes.metric.data.attributes.name`

From second hand info I believe this worked on our company’s main account, however my personal/test account doesn’t seem to be showing this new metric (or even event on the profile for that matter despite getting a 202 response)

Is this because it’s a free account or am I missing a something to get a custom metric recognized?

According to Klaviyo's documentation, you're correct that you can use the "event" endpoint to create a custom metric by passing the name in the data.attributes.metric.data.attributes.name parameter.

However, it seems that there might be some limitations when it comes to using custom metrics on a free account. According to Klaviyo's pricing page, custom metrics are only available on their paid plans.


Free plans don’t have any limitations on custom metrics, except for the limitation that applies to all accounts, you can have up to 200 metrics (not events, but up to 200 differently named metrics).

Are you sure you’re using the correct private key for the test account?

Do you see the API call in the logs? https://developers.klaviyo.com/en/docs/monitor_api_usage


Are you sure you’re using the correct private key for the test account?


I’m using the correct keys and have no auth related errors and see the endpoints in the logs as you suggested.
 

Free plans don’t have any limitations on custom metrics


So without any limitations on custom metrics in my free account and with 202/Success api response is there another issue preventing metrics and events from appearing in my account? Maybe a bug on klaviyo’s end?


Also - is there a better avenue to ask these questions? Something I can initiate through our company’s account?


EDIT: @saulblum has dm’d me earlier


Yes, go through support at help.klaviyo.com


For anyone else that lands on this, my issue here was that I was using a “@example.com” email which is apparently quietly ignored in klaviyo (even for creating metrics) despite getting a 202/Success response