Dev GuideAPI Reference
Dev GuideAPI ReferenceUser GuideGitHubNuGetDev CommunitySubmit a ticketLog In
GitHubNuGetDev CommunitySubmit a ticket

Describe experiments running on the page, indexed by experiment ID.

window.optimizelyEdge.get('state').getActiveExperiments()
> {'123': {id: '123', name: 'Landing Page Experiment', variation: {id: '456', name: 'New CTA Text'}}

Parameters

None

Returns

An object mapping experiment ID (key) to experiment object (see below)

ParameterTypeDescription
experimentobjectDescription of the experiment
experiment.idstringID of the experiment
experiment.namestring | nullDescriptive name of the experiment, set in Optimizely Performance Edge. If the "Mask Descriptive Names" feature is enabled, this is null.
experiment.variationobjectDescription of the selected variation
experiment.variation.idstringID of the selected variation
experiment.variation.namestring | nullDescriptive name of the variation, set in Optimizely Performance Edge. If the "Mask Descriptive Names" feature is enabled, this is null.