put https://hq1.appsflyer.com/api/vr2api/rule/
Update the specifications of a rule which was previously created. Note: When you enter the API token and click Try it, the rule is updated.
Prerequisites
- The API V2.0 token from your AppsFlyer admin to access AppsFlyer data.
- We recommend you use the JSON of a rule already created in the AppsFlyer platform as a template.
Validation rule JSON
We recommend you copy/paste the JSON of a pre-existing rule into the API to create a new rule.
To get the JSON:
- In AppsFlyer, go to Configuration > Validation Rules.
- In the browser window, add #dev to the URL or go to https://hq1.appsflyer.com/vr2/validation-rules#dev.
A code icon displays near the top right of every Validation rule.


- Select a Validation rule.
- Click the code icon.
A JSON with the API Validation rule code request displays.
Click copy.
{
"action": "block-candidate",
"app-ids": [
"some.app"
],
"description": "some NEW description",
"event-type": "install",
"name": "some name",
"population": {
"cond-oper": "and”,
"conds": [
{
"attr": "engagement.media_source",
"oper": "s.in",
"values": [
"some_media_source_1",
"some_media_source_2"
]
}
]
},
"rule-conditions": {
"cond-group-oper": "or",
"cond-groups": [
{
"cond-oper": "and",
"conds": [
{
"attr": "geo",
"oper": "s.in",
"values": [
"us/*/*",
"my/*/*",
"ca/*/*"
]
}
]
}
]
},
"rule-type": "allow-only",
"status": "enabled"
}