curl --request POST \
--url https://statsigapi.net/console/v1/segments/{id}/conditional \
--header 'Content-Type: application/json' \
--header 'STATSIG-API-KEY: <api-key>' \
--data '
[
{
"name": "<string>",
"passPercentage": 50,
"conditions": [
{
"type": "app_version",
"targetValue": [
"<string>"
],
"operator": "<string>",
"field": "<string>",
"customID": "<string>"
}
],
"environments": [
"<string>"
],
"id": "<string>",
"baseID": "<string>",
"returnValue": {}
}
]
'{
"message": "Rules successfully updated"
}curl --request POST \
--url https://statsigapi.net/console/v1/segments/{id}/conditional \
--header 'Content-Type: application/json' \
--header 'STATSIG-API-KEY: <api-key>' \
--data '
[
{
"name": "<string>",
"passPercentage": 50,
"conditions": [
{
"type": "app_version",
"targetValue": [
"<string>"
],
"operator": "<string>",
"field": "<string>",
"customID": "<string>"
}
],
"environments": [
"<string>"
],
"id": "<string>",
"baseID": "<string>",
"returnValue": {}
}
]
'{
"message": "Rules successfully updated"
}Optional header to respect review settings for mutation endpoints.
id
The name of this rule.
Of the users that meet the conditions of this rule, what percent should return true.
0 <= x <= 100Must be a multiple of 0.01Show child attributes
app_version, browser_name, browser_version, country, custom_field, email, environment_tier, fails_segment, ip_address, os_name, os_version, passes_segment, unit_id, user_id The environments this rule is enabled for.
The Statsig ID of this rule.
The base ID of this rule, i.e. without any added metadata. Will remain the exact same throughout
Rules Successfully Updated
A simple string explaining the result of the operation.
A single result.
Show child attributes
Is the segment enabled.
id_list, rule_based, analysis_list ID
Type of ID
Detailed description of the configuration’s purpose.
ID of the last modifier.
Time of the last modification.
Email of the last modifier.
Name of the last modifier.
ID of the user who created the entity.
Timestamp when the entity was created.
Name of the creator.
Email of the creator.
For id_list segments: the length of the ID list
Rule Object
Show child attributes
The name of this rule.
Of the users that meet the conditions of this rule, what percent should return true.
0 <= x <= 100Must be a multiple of 0.01An array of Condition objects.
Show child attributes
app_version, browser_name, browser_version, country, custom_field, email, environment_tier, fails_gate, fails_segment, ip_address, locale, os_name, os_version, passes_gate, passes_segment, public, time, unit_id, user_id, url, javascript, device_model, target_app The environments this rule is enabled for.
The Statsig ID of this rule.
The base ID of this rule, i.e. without any added metadata. Will remain the exact same throughout
Optional tags for categorization.
Optional name for the configuration.
List of target applications associated with this configuration.
Holdouts applied to this configuration.
Optional name for the responsible team.
Optional ID of the responsible team.
Version number