Skip to main content

    Get data into Klaviyo with APIs

    Course overview
    Lesson
    2 min read

    Push data into Klaviyo using client-side APIs

    Learn which types of data can be pushed to Klaviyo from the browser, and walk through a real life example of how to execute this.

    Identify your use case

    Before you can start pushing data into Klaviyo, you’ll need a clear understanding of what your use case is, and what the end objective is. What kind of data will you need in order to achieve your final goal? If you need data that is collected within the browser as someone is visiting a publicly-browseable website, then you want to use a client-side API. There are a few types of data that can be pushed into Klaviyo from the client-side:

    • Event: tracks onsite activity associated with a profile.
    • Create or update a profile: creates new profiles or updates profile properties associated with a profile, such as name, email, address, etc.
    • Subscriptions: creates a subscription to a specific email or SMS contact list.

    In addition, back in stock subscriptions, push tokens, and reviews can be managed client-side for accounts with these features enabled.

    Walk through a client-side example

    For client-side data, you can either use a client-side API or use the Klaviyo object. This video will walk you through examples of the Subscription, Event, and Profile APIs. It will also explain how to use the Klaviyo object to identify users.

    Helpful resources for client-side APIs

    As you start using these APIs, use the API reference documentation available through the Developer Portal. These documents will give you all of the necessary code, and provide a testing tool that allows you to test examples in different languages.

    Push data into Klaviyo using client-side APIs