curl --request PUT \
--url https://api.kameleoon.com/targeting-rules/{targetingRuleId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"siteId": 123,
"segmentConfiguration": "ALL_VISITORS",
"segmentId": 123,
"targetingConfigurationParam": "<string>",
"triggerConfiguration": "ALL_VISITORS",
"triggerId": 123
}
'{
"siteId": 123,
"id": 123,
"segmentConfiguration": "ALL_VISITORS",
"segmentId": 123,
"targetingConfigurationParam": "<string>",
"triggerConfiguration": "ALL_VISITORS",
"triggerId": 123
}Update the targeting rule belonging to this Id
curl --request PUT \
--url https://api.kameleoon.com/targeting-rules/{targetingRuleId} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"siteId": 123,
"segmentConfiguration": "ALL_VISITORS",
"segmentId": 123,
"targetingConfigurationParam": "<string>",
"triggerConfiguration": "ALL_VISITORS",
"triggerId": 123
}
'{
"siteId": 123,
"id": 123,
"segmentConfiguration": "ALL_VISITORS",
"segmentId": 123,
"targetingConfigurationParam": "<string>",
"triggerConfiguration": "ALL_VISITORS",
"triggerId": 123
}Documentation Index
Fetch the complete documentation index at: https://docs.kameleoon.com/llms.txt
Use this file to discover all available pages before exploring further.
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Id of the targeting rule object
Id of the experiment
Targeting Rule defines the conditions for displaying content to specific user groups based on segments and triggers
Id of the project this targeting rule belongs to
Configuration defining how the segment should be applied
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.
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
ALL_VISITORS, AUTOPROMO_AUTODEFINED, GRAPHICAL_PAGES, HEAT_SLICE, PAGE, SAVED_TEMPLATE, SITE, URL Id of the associated trigger (activation condition)
OK
Targeting Rule defines the conditions for displaying content to specific user groups based on segments and triggers
Id of the project this targeting rule belongs to
Unique Id of the targeting rule
Configuration defining how the segment should be applied
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.
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
ALL_VISITORS, AUTOPROMO_AUTODEFINED, GRAPHICAL_PAGES, HEAT_SLICE, PAGE, SAVED_TEMPLATE, SITE, URL Id of the associated trigger (activation condition)
Was this page helpful?