Rest API
Create or update a personalization
POST /api/v1/personalizations
Create a new personalization (experience), or update an existing one by passing its variationId.
Notes
websiteIdis taken from the auth headers and overwrites whatever the body saysvariationNameis required; the request is rejected without it- Deleting a personalization, duplicating one and managing themes are not available with an API key, only from the dashboard
Parameters
Section titled “ Parameters ”Header Parameters
Section titled “Header Parameters ”Your API key from account settings.
The email address of your user.
The ID of your account. You can find this in the account settings.
The ID of the workspace you want to use.
Request Body required
Section titled “Request Body required ”object
The account ID that owns this personalization.
User assigned to this personalization.
Whether the personalization has been modified.
Account ID for component-based personalizations.
Package name for component-based personalizations.
JSON string containing component configuration.
Type of component used.
Version of the component.
Timestamp when personalization was created.
Creation date timestamp.
Delay trigger option (e.g., “seconds”, “pageviews”).
Delay value for trigger timing.
URL for viewing changes diff.
Whether the personalization is disabled.
Timestamp when personalization should stop running.
Rules for excluding visitors.
Whether this personalization is exclusive.
Option for hiding the personalization.
Value for hide timing.
Whether this is a component-based personalization.
Whether this is a hidden AI component.
JavaScript trigger code.
Parsed JavaScript trigger.
Extended URL information.
Maximum value for certain triggers.
Array of tags associated with this personalization.
Priority level (higher numbers = higher priority).
Personalization recipe/template.
URL for redirect-type personalizations.
Targeting rules in JSON format.
Timestamp when personalization should start running.
Current state (e.g., “running”, “paused”, “draft”).
Target domain for template.
Target path for template.
Test mode configuration.
Timestamp of last update.
Array of personalization variants.
object
ID of the variation.
Name of the variation.
Web page path where personalization applies.
Website ID this personalization belongs to.
ID of an existing personalization to update. Omit to create a new one.
Name of the variation being saved.
Example
{ "name": "Homepage hero test", "variationName": "Control", "state": "draft", "webPagePath": "/"}Responses
Section titled “ Responses ”The created or updated personalization.
Bad request - missing websiteId or variationName.
Unauthorized - invalid API key.