Add, update, remove, or reorder one targeting rule
manage_targeting_ruleAdd, update, remove, or reorder a single Featureflip targeting rule by id, changing only specified fields instead of replacing all rules.
Instructions
Edit a single targeting rule instead of replacing them all with update_targeting. action=add needs rule (appended last); action=update needs ruleId + rule and changes only the fields you pass (conditionGroups replaces the rule's groups; to clear rolloutPercentage or userSegmentId use update_targeting); action=remove needs ruleId; action=reorder needs ruleIds, every existing rule id exactly once, in the new order. Rule ids come from get_targeting.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| flag | Yes | Flag key or id | |
| rule | No | Rule fields; required for add and update | |
| action | Yes | add needs rule; update needs ruleId + rule; remove needs ruleId; reorder needs ruleIds | |
| ruleId | No | Rule id from get_targeting; required for update and remove | |
| project | Yes | Project key | |
| ruleIds | No | Every rule id exactly once, in evaluation order; required for reorder | |
| environment | Yes | Environment key, e.g. production |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||