Skip to main content

Hi, 

We are trying to support our clients with loading existing customer profiles to Klaviyo via csv file during onboarding. After onboarding, we send customer create and update via real-time profiles API to Klaviyo. 

When sending customer data via API, we send ‘external_id’ field under the attributes section per Klaviyo documentation. 

 

This external_id field then gets populated correctly under ‘Profile details’ section. 

 

However, when I upload customer profile via csv file and input the ID under ‘external_id’ column, Klaviyo asks to map the external_id field to a new field and when it gets uploaded, it is created under ‘Custom properties’.

 

How can I get the external_id field to be populated under ‘Profile detail’ section when loading data via csv file? 

Hi ​@suminchoi2015 - Thanks for you questions. 

This happens because Klaviyo’s CSV importer treats all non-standard fields as custom properties by default.

The external_id field is a reserved API field that can only be populated via the Profiles API, not via CSV upload.

When you upload a CSV file, Klaviyo doesn’t interpret external_id as a special field, it just sees it as a custom attribute and stores it under “Custom properties.”

 

Solution

To have the external_id appear under Profile Details, you must set it using the Profiles API.

Here’s the proper way to do it:

POST https://a.klaviyo.com/api/profiles/
Authorization: Klaviyo-API-Key <PRIVATE_API_KEY>
Content-Type: application/json

{
  "data": {
    "type": "profile",
    "attributes": {
      "email": "test@test.com",
      "external_id": "1234567891",
      "first_name": "Test",
      "last_name": "User"
    }
  }
}