Fully Update Gates
curl --request POST \
--url https://statsigapi.net/console/v1/gates/{id} \
--header 'Content-Type: application/json' \
--header 'STATSIG-API-KEY: <api-key>' \
--data '
{
"isEnabled": false,
"description": "Updated Gate Description",
"rules": [
{
"name": "All Conditions",
"passPercentage": 10,
"conditions": [
{
"type": "user_id",
"targetValue": [
"111",
"222"
],
"operator": "any"
},
{
"type": "email",
"targetValue": [
"@outlook.com",
"@gmail.com"
],
"operator": "str_contains_any"
},
{
"type": "custom_field",
"targetValue": 31,
"operator": "gt",
"field": "age"
},
{
"type": "app_version",
"targetValue": "1.1.1",
"operator": "version_gt"
},
{
"type": "browser_name",
"targetValue": [
"Android",
"Chrome"
],
"operator": "any"
},
{
"type": "browser_version",
"targetValue": [
"94.0.4606.81",
"94.0.4606.92"
],
"operator": "any"
},
{
"type": "os_name",
"targetValue": [
"Android",
"Windows"
],
"operator": "none"
},
{
"type": "os_version",
"targetValue": "11.0.0",
"operator": "version_lte"
},
{
"type": "country",
"targetValue": [
"NZ",
"US"
],
"operator": "any"
},
{
"type": "environment_tier",
"targetValue": [
"production"
],
"operator": "any"
},
{
"type": "passes_segment",
"targetValue": "growth_org"
},
{
"type": "fails_segment",
"targetValue": "growth_org"
},
{
"type": "ip_address",
"targetValue": [
"1.1.1.1",
"8.8.8.8"
],
"operator": "any"
},
{
"type": "unit_id",
"operator": "any",
"targetValue": [
"31"
],
"customID": "userID"
}
]
}
],
"tags": [
"★ Core"
],
"type": "TEMPORARY",
"idType": "stableID",
"targetApps": []
}
'{
"data": {
"checksPerHour": 0,
"createdTime": 1705439406615,
"creatorEmail": null,
"creatorID": "4R5PV7mvYdW6NLCwK8ocoz",
"creatorName": "CONSOLE API",
"description": "Updated Gate Description",
"holdoutIDs": [],
"id": "a_gate",
"idType": "stableID",
"isEnabled": false,
"lastModifiedTime": 1705439409750,
"lastModifierEmail": null,
"lastModifierID": "4R5PV7mvYdW6NLCwK8ocoz",
"lastModifierName": "CONSOLE API",
"name": "A Gate",
"rules": [
{
"conditions": [
{
"operator": "any",
"targetValue": [
"111",
"222"
],
"type": "user_id"
},
{
"operator": "str_contains_any",
"targetValue": [
"@outlook.com",
"@gmail.com"
],
"type": "email"
},
{
"field": "age",
"operator": "gt",
"targetValue": 31,
"type": "custom_field"
},
{
"operator": "version_gt",
"targetValue": "1.1.1",
"type": "app_version"
},
{
"operator": "any",
"targetValue": [
"Android",
"Chrome"
],
"type": "browser_name"
},
{
"operator": "any",
"targetValue": [
"94.0.4606.81",
"94.0.4606.92"
],
"type": "browser_version"
},
{
"operator": "none",
"targetValue": [
"Android",
"Windows"
],
"type": "os_name"
},
{
"operator": "version_lte",
"targetValue": "11.0.0",
"type": "os_version"
},
{
"operator": "any",
"targetValue": [
"NZ",
"US"
],
"type": "country"
},
{
"operator": "any",
"targetValue": [
"production"
],
"type": "environment_tier"
},
{
"targetValue": "growth_org",
"type": "passes_segment"
},
{
"targetValue": "growth_org",
"type": "fails_segment"
},
{
"operator": "any",
"targetValue": [
"1.1.1.1",
"8.8.8.8"
],
"type": "ip_address"
},
{
"customID": "userID",
"operator": "any",
"targetValue": [
"31"
],
"type": "unit_id"
}
],
"environments": null,
"name": "All Conditions",
"passPercentage": 10
}
],
"status": "Disabled",
"tags": [
"★ Core"
],
"targetApps": [],
"type": "PERMANENT",
"typeReason": "NONE",
"team": null,
"reviewSettings": {
"requiredReview": false,
"allowedReviewers": []
},
"measureMetricLifts": true,
"store0100Exposures": false,
"owner": {
"ownerID": "user123",
"ownerName": "CONSOLE API",
"ownerType": "SDK_KEY",
"ownerEmail": ""
},
"monitoringMetrics": [],
"version": 2,
"permalink": "https://console.statsig.com/company_id/gates/a_gate"
},
"message": "Gate updated successfully."
}Gates
Fully Update Gates
POST
/
console
/
v1
/
gates
/
{id}
Fully Update Gates
curl --request POST \
--url https://statsigapi.net/console/v1/gates/{id} \
--header 'Content-Type: application/json' \
--header 'STATSIG-API-KEY: <api-key>' \
--data '
{
"isEnabled": false,
"description": "Updated Gate Description",
"rules": [
{
"name": "All Conditions",
"passPercentage": 10,
"conditions": [
{
"type": "user_id",
"targetValue": [
"111",
"222"
],
"operator": "any"
},
{
"type": "email",
"targetValue": [
"@outlook.com",
"@gmail.com"
],
"operator": "str_contains_any"
},
{
"type": "custom_field",
"targetValue": 31,
"operator": "gt",
"field": "age"
},
{
"type": "app_version",
"targetValue": "1.1.1",
"operator": "version_gt"
},
{
"type": "browser_name",
"targetValue": [
"Android",
"Chrome"
],
"operator": "any"
},
{
"type": "browser_version",
"targetValue": [
"94.0.4606.81",
"94.0.4606.92"
],
"operator": "any"
},
{
"type": "os_name",
"targetValue": [
"Android",
"Windows"
],
"operator": "none"
},
{
"type": "os_version",
"targetValue": "11.0.0",
"operator": "version_lte"
},
{
"type": "country",
"targetValue": [
"NZ",
"US"
],
"operator": "any"
},
{
"type": "environment_tier",
"targetValue": [
"production"
],
"operator": "any"
},
{
"type": "passes_segment",
"targetValue": "growth_org"
},
{
"type": "fails_segment",
"targetValue": "growth_org"
},
{
"type": "ip_address",
"targetValue": [
"1.1.1.1",
"8.8.8.8"
],
"operator": "any"
},
{
"type": "unit_id",
"operator": "any",
"targetValue": [
"31"
],
"customID": "userID"
}
]
}
],
"tags": [
"★ Core"
],
"type": "TEMPORARY",
"idType": "stableID",
"targetApps": []
}
'{
"data": {
"checksPerHour": 0,
"createdTime": 1705439406615,
"creatorEmail": null,
"creatorID": "4R5PV7mvYdW6NLCwK8ocoz",
"creatorName": "CONSOLE API",
"description": "Updated Gate Description",
"holdoutIDs": [],
"id": "a_gate",
"idType": "stableID",
"isEnabled": false,
"lastModifiedTime": 1705439409750,
"lastModifierEmail": null,
"lastModifierID": "4R5PV7mvYdW6NLCwK8ocoz",
"lastModifierName": "CONSOLE API",
"name": "A Gate",
"rules": [
{
"conditions": [
{
"operator": "any",
"targetValue": [
"111",
"222"
],
"type": "user_id"
},
{
"operator": "str_contains_any",
"targetValue": [
"@outlook.com",
"@gmail.com"
],
"type": "email"
},
{
"field": "age",
"operator": "gt",
"targetValue": 31,
"type": "custom_field"
},
{
"operator": "version_gt",
"targetValue": "1.1.1",
"type": "app_version"
},
{
"operator": "any",
"targetValue": [
"Android",
"Chrome"
],
"type": "browser_name"
},
{
"operator": "any",
"targetValue": [
"94.0.4606.81",
"94.0.4606.92"
],
"type": "browser_version"
},
{
"operator": "none",
"targetValue": [
"Android",
"Windows"
],
"type": "os_name"
},
{
"operator": "version_lte",
"targetValue": "11.0.0",
"type": "os_version"
},
{
"operator": "any",
"targetValue": [
"NZ",
"US"
],
"type": "country"
},
{
"operator": "any",
"targetValue": [
"production"
],
"type": "environment_tier"
},
{
"targetValue": "growth_org",
"type": "passes_segment"
},
{
"targetValue": "growth_org",
"type": "fails_segment"
},
{
"operator": "any",
"targetValue": [
"1.1.1.1",
"8.8.8.8"
],
"type": "ip_address"
},
{
"customID": "userID",
"operator": "any",
"targetValue": [
"31"
],
"type": "unit_id"
}
],
"environments": null,
"name": "All Conditions",
"passPercentage": 10
}
],
"status": "Disabled",
"tags": [
"★ Core"
],
"targetApps": [],
"type": "PERMANENT",
"typeReason": "NONE",
"team": null,
"reviewSettings": {
"requiredReview": false,
"allowedReviewers": []
},
"measureMetricLifts": true,
"store0100Exposures": false,
"owner": {
"ownerID": "user123",
"ownerName": "CONSOLE API",
"ownerType": "SDK_KEY",
"ownerEmail": ""
},
"monitoringMetrics": [],
"version": 2,
"permalink": "https://console.statsig.com/company_id/gates/a_gate"
},
"message": "Gate updated successfully."
}Documentation Index
Fetch the complete documentation index at: https://docs.statsig.com/llms.txt
Use this file to discover all available pages before exploring further.
Authorizations
Path Parameters
id
Body
application/json
Maximum string length:
1000Show child attributes
Show child attributes
The gate display name
Required string length:
3 - 100Pattern:
^[a-zA-Z0-9_\-. ]*$Available options:
PERMANENT, TEMPORARY Show child attributes
Show child attributes
Whether reviews are required for this gate. If a gate has reviews required due to a project-level or team-level setting, setting this will have no effect.
Show child attributes
Show child attributes
Optional safe-change strategy for risky gate rule increases. When required by policy, clients should retry with this field set after user confirmation.
Show child attributes
Show child attributes
Was this page helpful?
⌘I