Solved

identify request return "Unable to parse exchange token"

  • 20 February 2024
  • 4 replies
  • 33 views

Badge

what I do
connect js from Klaviyo
<script async type="text/javascript" src="//static.klaviyo.com/onsite/js/klaviyo.js?company_id=PUBLIC_API_KEY"></script>
than
<script>klaviyo.identify({"email":"some_email@gmail.com"});</script>
in response I see
{
    "errors": [
        {
            "id": "03a6717c-f05d-4e85-8cc3-b58f5baef53d",
            "status": 400,
            "code": "invalid",
            "title": "Invalid input.",
            "detail": "Unable to parse exchange token.",
            "source": {
                "pointer": "/data/attributes/_kx"
            },
            "meta": {}
        }
    ]
}
What I do wrong?

icon

Best answer by dbpdev 22 March 2024, 14:06

View original

4 replies

Hi!

Try replacing `PUBLIC_API_KEY` in your script snippet with your public key, found under Settings > Account > API Keys

Thanks,

Jason

Badge

I used right API key, what it can be?


______
ticket is not solved!

Badge

pls close these one as resolved issue was in 1 letter (capitalize) of api key… omg..

Userlevel 7
Badge +36

Hi @dbpdev!

Thanks for coming back to the Community to share your solution!

Best,

Brian

Reply