Create a new experiment
POST/experiments
Create a new experiment with the given parameters
Request
- application/json
Body
required
Array [
]
Array [
]
Array [
Array [
]
]
Array [
]
Deprecated. Use trafficAllocationMethod field instead
URL of the website to load in editor and preview mode
Indicates if data collection is enabled
CSS code specific to all variations
JavaScript code specific to all variations
deviations
object
Traffic allocation per variation. Key can be 'origin'(for original page) or variation id.Value is the percentage of traffic which will be directed to this variation.It has to be double numbers ranging from 0(0%) to 1(100%).
Traffic allocation per variation. Key can be 'origin'(for original page) or variation id.Value is the percentage of traffic which will be directed to this variation.It has to be double numbers ranging from 0(0%) to 1(100%).
JavaScript code that will be applied only to the selected experiment and executed in the end of the Global custom script
List of Ids of the goals being used by this experiment.For GET requests, this is an optional field that needs to be specified in request params
Indicates whether multiple testing correction is enabled
mvtAllocationSettings
object
combinationsAllocations
object[]
sectionsAllocations
object[]
mvtVariations
object[]
variations
object[]
Name of the experiment
respoolTime
object
The respoolTime map contains key-value pairs, where each key is a variation ID and the corresponding value is a timestamp representing the most recent change to the variation’s allocation (for example, using the Kameleoon app or the Automation API).
The respoolTime map contains key-value pairs, where each key is a variation ID and the corresponding value is a timestamp representing the most recent change to the variation’s allocation (for example, using the Kameleoon app or the Automation API).
Site Id of the project the experiment belongs to
List of tags being used by this experiment.For GET requests, this is an optional field that needs to be specified in request params.
Deprecated. Use the https://api.kameleoon.com/targeting-rules endpoint to update the targeting of your experiment
Possible values: [ALL_VISITORS, AUTOPROMO_AUTODEFINED, GRAPHICAL_PAGES, HEAT_SLICE, PAGE, SAVED_TEMPLATE, SITE, URL]
targetingRule
object
Targeting Rule defines the conditions for displaying content to specific user groups based on segments and triggers
Configuration defining how the segment should be applied
Possible values: [ALL_VISITORS, AUTOPROMO_AUTODEFINED, GRAPHICAL_PAGES, HEAT_SLICE, PAGE, SAVED_TEMPLATE, SITE, URL]
Id of the associated segment (user group) for targeting. If segment is deprecated, no trigger will be available for this rule.
Id of the project this targeting rule belongs to
Additional parameters for trigger configuration. For SAVED_TEMPLATE/HEAT_SLICE - contains segment Id. For PAGE - contains full URL. For URL - contains URL fragment.
Configuration defining how the trigger should be applied. ALL_VISITORS configuration is not allowed for this trigger type
Possible values: [ALL_VISITORS, AUTOPROMO_AUTODEFINED, GRAPHICAL_PAGES, HEAT_SLICE, PAGE, SAVED_TEMPLATE, SITE, URL]
Id of the associated trigger (activation condition)
Deprecated. Use the https://api.kameleoon.com/targeting-rules endpoint to update the targeting of your experiment
trackingTools
object[]
Possible values: [GOOGLE_ANALYTICS4, GOOGLE_ANALYTICS4_AUDIENCES, GOOGLE_UNIVERSAL_ANALYTICS, ECONDA, SMART_TAG, PIANO, ADOBE_OMNITURE, EULERIAN, WEBTRENDS, KISSMETRICS, PIWIK, CRAZY_EGG, COM_SCORE, TEALIUM, YSANCE, M_PATHY, SMARTFOCUS, EMARSYS, EXPERTSENDER, TAG_COMMANDER, CONTENT_SQUARE, WEBTREKK, CUSTOM_INTEGRATIONS, HEAP, HEAP_COHORTS, SEGMENT, MIXPANEL, CLARITY, IABTCF, DATABRICKS, REDSHIFT, SMARTLOOK, MOUSEFLOW, KLAVIYO, FULLSTORY, AMPLITUDE, SNOWPLOW, JUNE, MPARTICLE, BIGQUERY, RUDDERSTACK, SNOWFLAKE, GLASSBOX, HUBSPOT, AIR360, DATADOG, QUANTUM_METRIC, GLASSBOX_V2, BRAZE, KAMELEOON_TRACKING, CUSTOM_TRACKING, VERCEL, AKAMAI]
Possible values: [CONTEXTUAL_BANDIT, MANUAL, MULTI_ARMED_BANDIT]
Possible values: [AI, CLASSIC, DEVELOPER, FEATURE_FLAG, MVT, PROMPT, SDK_HYBRID]
Responses
- 201
- 400
- 401
- 403
- 404
- 422
- 423
- 500
Created
- */*
- Schema
- Example (from schema)
Schema
Array [
]
Array [
]
Array [
Array [
]
]
Array [
]
Deprecated. Use trafficAllocationMethod field instead
URL of the website to load in editor and preview mode
Indicates if data collection is enabled
CSS code specific to all variations
JavaScript code specific to all variations
Account Id of the creator of the experiment
Date the data collection stops
Date the experiment ceased
Date the experiment was modified
Date the experiment was launched
Date the experiment was last modified
deviations
object
Traffic allocation per variation. Key can be 'origin'(for original page) or variation id.Value is the percentage of traffic which will be directed to this variation.It has to be double numbers ranging from 0(0%) to 1(100%).
Traffic allocation per variation. Key can be 'origin'(for original page) or variation id.Value is the percentage of traffic which will be directed to this variation.It has to be double numbers ranging from 0(0%) to 1(100%).
JavaScript code that will be applied only to the selected experiment and executed in the end of the Global custom script
List of Ids of the goals being used by this experiment.For GET requests, this is an optional field that needs to be specified in request params
Unique Id of the experiment
Indicates if experiment is archived
Indicates whether multiple testing correction is enabled
mvtAllocationSettings
object
combinationsAllocations
object[]
sectionsAllocations
object[]
mvtVariations
object[]
variations
object[]
Name of the experiment
respoolTime
object
The respoolTime map contains key-value pairs, where each key is a variation ID and the corresponding value is a timestamp representing the most recent change to the variation’s allocation (for example, using the Kameleoon app or the Automation API).
The respoolTime map contains key-value pairs, where each key is a variation ID and the corresponding value is a timestamp representing the most recent change to the variation’s allocation (for example, using the Kameleoon app or the Automation API).
Site code of the experiment
Site Id of the project the experiment belongs to
Status of the experiment
List of tags being used by this experiment.For GET requests, this is an optional field that needs to be specified in request params.
Deprecated. Use the https://api.kameleoon.com/targeting-rules endpoint to update the targeting of your experiment
Possible values: [ALL_VISITORS, AUTOPROMO_AUTODEFINED, GRAPHICAL_PAGES, HEAT_SLICE, PAGE, SAVED_TEMPLATE, SITE, URL]
targetingRule
object
Targeting Rule defines the conditions for displaying content to specific user groups based on segments and triggers
Unique Id of the targeting rule
Configuration defining how the segment should be applied
Possible values: [ALL_VISITORS, AUTOPROMO_AUTODEFINED, GRAPHICAL_PAGES, HEAT_SLICE, PAGE, SAVED_TEMPLATE, SITE, URL]
Id of the associated segment (user group) for targeting. If segment is deprecated, no trigger will be available for this rule.
Id of the project this targeting rule belongs to
Additional parameters for trigger configuration. For SAVED_TEMPLATE/HEAT_SLICE - contains segment Id. For PAGE - contains full URL. For URL - contains URL fragment.
Configuration defining how the trigger should be applied. ALL_VISITORS configuration is not allowed for this trigger type
Possible values: [ALL_VISITORS, AUTOPROMO_AUTODEFINED, GRAPHICAL_PAGES, HEAT_SLICE, PAGE, SAVED_TEMPLATE, SITE, URL]
Id of the associated trigger (activation condition)
Deprecated. Use TargetingRule instead.
Deprecated. Use the https://api.kameleoon.com/targeting-rules endpoint to update the targeting of your experiment
trackingTools
object[]
Possible values: [GOOGLE_ANALYTICS4, GOOGLE_ANALYTICS4_AUDIENCES, GOOGLE_UNIVERSAL_ANALYTICS, ECONDA, SMART_TAG, PIANO, ADOBE_OMNITURE, EULERIAN, WEBTRENDS, KISSMETRICS, PIWIK, CRAZY_EGG, COM_SCORE, TEALIUM, YSANCE, M_PATHY, SMARTFOCUS, EMARSYS, EXPERTSENDER, TAG_COMMANDER, CONTENT_SQUARE, WEBTREKK, CUSTOM_INTEGRATIONS, HEAP, HEAP_COHORTS, SEGMENT, MIXPANEL, CLARITY, IABTCF, DATABRICKS, REDSHIFT, SMARTLOOK, MOUSEFLOW, KLAVIYO, FULLSTORY, AMPLITUDE, SNOWPLOW, JUNE, MPARTICLE, BIGQUERY, RUDDERSTACK, SNOWFLAKE, GLASSBOX, HUBSPOT, AIR360, DATADOG, QUANTUM_METRIC, GLASSBOX_V2, BRAZE, KAMELEOON_TRACKING, CUSTOM_TRACKING, VERCEL, AKAMAI]
Possible values: [CONTEXTUAL_BANDIT, MANUAL, MULTI_ARMED_BANDIT]
Possible values: [AI, CLASSIC, DEVELOPER, FEATURE_FLAG, MVT, PROMPT, SDK_HYBRID]
List of variation ids for this experiment
{
"baseURL": "string",
"collectingDataEnabled": true,
"commonCssCode": "string",
"commonJavaScriptCode": "string",
"createdBy": 0,
"dateCollectingDataStopped": "2024-07-29T15:51:28.071Z",
"dateCreated": "2024-07-29T15:51:28.071Z",
"dateEnded": "2024-07-29T15:51:28.071Z",
"dateModified": "2024-07-29T15:51:28.071Z",
"dateStarted": "2024-07-29T15:51:28.071Z",
"dateStatusModified": "2024-07-29T15:51:28.071Z",
"description": "string",
"deviations": {
"12345": 0.5,
"origin": 0.5
},
"executeCodeForReference": true,
"globalScript": "string",
"goals": [
0
],
"id": 0,
"isArchived": true,
"isLegacyEditor": true,
"isMultipleTestingCorrection": true,
"mainGoalId": 0,
"mvtAllocationSettings": {
"combinationsAllocations": [
{
"allocationPart": 0,
"checked": true,
"locked": true,
"sectionId": 0,
"variationId": "string"
}
],
"exposedPart": 0,
"sectionsAllocations": [
{
"allocationPart": 0,
"checked": true,
"locked": true,
"sectionId": 0,
"variationId": "string"
}
]
},
"mvtVariations": [
{
"sectionId": 0,
"sectionName": "string",
"variations": [
{
"id": 0,
"name": "string"
}
]
}
],
"name": "string",
"respoolTime": {
"12345": 833760000,
"origin": 1704067200
},
"siteCode": "string",
"siteId": 0,
"status": "string",
"tags": [
"string"
],
"targetingRule": {
"id": 0,
"segmentConfiguration": "ALL_VISITORS",
"segmentId": 0,
"siteId": 0,
"targetingConfigurationParam": "string",
"triggerConfiguration": "ALL_VISITORS",
"triggerId": 0
},
"trackingTools": [
{
"adobeOmnitureObject": "string",
"comScoreCustomerId": "string",
"comScoreDomain": "string",
"contentSquareUrl": "string",
"customIntegrations": [
"string"
],
"customVariable": 0,
"eulerianUserCentricParameter": "string",
"name": "GOOGLE_ANALYTICS4",
"reportingScript": "string",
"universalAnalyticsDimension": 0
}
],
"trafficAllocationMethod": "CONTEXTUAL_BANDIT",
"type": "AI",
"variations": [
0
]
}
Bad Request
- */*
- Schema
- Example (from schema)
Schema
Possible values: [SUCCESS, ERROR]
{
"code": "string",
"impersonator": "string",
"message": "string",
"name": "string",
"status": "SUCCESS",
"sub": "string",
"time": 0,
"timestamp": "2024-07-29T15:51:28.071Z"
}
Unauthorized
- */*
- Schema
- Example (from schema)
Schema
Possible values: [SUCCESS, ERROR]
{
"code": "string",
"impersonator": "string",
"message": "string",
"name": "string",
"status": "SUCCESS",
"sub": "string",
"time": 0,
"timestamp": "2024-07-29T15:51:28.071Z"
}
Forbidden
- */*
- Schema
- Example (from schema)
Schema
Possible values: [SUCCESS, ERROR]
{
"code": "string",
"impersonator": "string",
"message": "string",
"name": "string",
"status": "SUCCESS",
"sub": "string",
"time": 0,
"timestamp": "2024-07-29T15:51:28.071Z"
}
Not Found
- */*
- Schema
- Example (from schema)
Schema
Possible values: [SUCCESS, ERROR]
{
"code": "string",
"impersonator": "string",
"message": "string",
"name": "string",
"status": "SUCCESS",
"sub": "string",
"time": 0,
"timestamp": "2024-07-29T15:51:28.071Z"
}
Unprocessable Entity
- */*
- Schema
- Example (from schema)
Schema
Possible values: [SUCCESS, ERROR]
{
"code": "string",
"impersonator": "string",
"message": "string",
"name": "string",
"status": "SUCCESS",
"sub": "string",
"time": 0,
"timestamp": "2024-07-29T15:51:28.071Z"
}
Locked
- */*
- Schema
- Example (from schema)
Schema
Possible values: [SUCCESS, ERROR]
{
"code": "string",
"impersonator": "string",
"message": "string",
"name": "string",
"status": "SUCCESS",
"sub": "string",
"time": 0,
"timestamp": "2024-07-29T15:51:28.071Z"
}
Internal Server Error
- */*
- Schema
- Example (from schema)
Schema
Possible values: [SUCCESS, ERROR]
{
"code": "string",
"impersonator": "string",
"message": "string",
"name": "string",
"status": "SUCCESS",
"sub": "string",
"time": 0,
"timestamp": "2024-07-29T15:51:28.071Z"
}