Kameleoon.API, that your page code uses to call Kameleoon methods and read Kameleoon data in the visitor’s browser. It comes with the Kameleoon application file, engine.js (previously named kameleoon.js), which you install on your website to use Web Experimentation, or Feature Experimentation in hybrid mode.
What the Activation API does
The Activation API does four things:- Runs variations without flicker: The Core module provides methods that implement frontend A/B testing variations without flicker.
- Sends tracking data: The Goals, Data, and Products modules send conversions, custom data, and product events to Kameleoon. These calls work like the tracking calls you make to analytics tools, such as Google Analytics.
- Reads real-time visit data: The Visit object holds data that Kameleoon collects during the visit. For example, you can read a visitor’s page views across all previous visits, or how long they stayed on your website during their first visit.
- Overrides experiment assignment: When Kameleoon assigns a visitor to an experiment, it chooses the variation at random by default. The Experiments module lets you override that assignment and register the visitor in a specific variation.
Why the Activation API is useful
The API is entirely JavaScript-based and runs in the visitor’s browser, which gives you these advantages:- Results return immediately: Nearly all methods execute synchronously and return right away. The exceptions are methods that need a server call, such as the product catalog methods in the Products module.
- No authentication: The API requires no authentication, so your page code doesn’t need credentials to call it.
- Visitor data stays private to each visitor: Standard browser security rules let a visitor’s page access only that visitor’s data, which Kameleoon stores in Local Storage, and not data from other visitors.