v1

latestOpenAPI 3.0.32026-07-22177397578.0 KB
Variation

Update variation

Update the variation belonging to the given Id.

Supports:

  • application/json for updates without attachments
  • multipart/form-data for updates with prompt attachments

For multipart/form-data, send:

  • variation: JSON representation of the variation
  • attachments: optional attachment files matched by index with variation.prompt.attachments

Currently only one attachment is supported.

put/variations/{variationId}

Path parameters

variationIdinteger required

Request body

colorinteger

Variation color displayed in the editor

creationMode'AI' | 'CODE_BASE' | 'GRAPHICAL' | 'UNDEFINED' | 'WIDGET'

Creation mode of the variation: CODE_BASE, GRAPHICAL, AI or UNDEFINED

cssCodestring

Code editor css code for variation

customJsonstring

Custom JSON for this variation

experimentIdinteger

Id of the experiment this variation belongs to

expositionFrequencyDelaySecondsBetweenTwoExpositionsinteger

Delay in seconds between two exposures

expositionFrequencySameVisitinteger

Frequency of exposure during the same visit

expositionFrequencySameVisitorinteger

Frequency of the exposure for the same visitor

expositionFrequencySameVisitorDelaySecondsinteger

Delay in seconds between exposure for the same visitor

forceNoFlickerboolean
idinteger

Unique Id of the variation

isJsCodeAfterDomReadyboolean

Set to true (which is also the default value) if the code is applied once the DOM is ready.

jsCodestring

Code editor javascript code for variation

namestring required

Name of the variation

personalizationIdinteger

Id of the personalization this variation belongs to

redirectionStringsstring

Redirect URL used for redirecting variation. Deprecated property: use property 'redirection' instead

shadowDomboolean

ShadowDOM option

siteIdinteger required

Site Id of the project the variation belongs to

widgetTemplateInputstring

Widget template input data in JSON format.

Example request

{
  "prompt": {
    "attachments": [
      {
        "name": "US-39613---Image-attachement"
      }
    ]
  },
  "redirection": {
    "parameters": "param1=foo&param2=bar",
    "url": "www.kameleoon.com"
  }
}

Response

OK