Set how zone targeting rules of one type combine
Sets how the zone's Include or Exclude list of one targeting type combines, for the types a visitor can hold several values of: COOKIE_VALUE, CUSTOM, DMP and API_JSON_FIELD.
https://YOUR-NETWORK-DOMAIN/rest-api/zone/{zoneId}/targeting/match-mode.do Sets how the zone's Include or Exclude list of one targeting type combines, for the types a visitor can hold several values of: COOKIE_VALUE, CUSTOM, DMP and API_JSON_FIELD. A list splits into groups: the rules on one key a visitor holds once (one cookie name, one custom parameter) are alternatives, and every other rule (a DMP segment, an API JSON field, a custom parameter registered as a list, an expression) is a group of its own. ANY (the default) — an Include list passes when any group matches, an Exclude list keeps out a visitor matching any group. ALL — an Include list passes only when every group matches, an Exclude list keeps out only a visitor matching every group: tier=gold, tier=silver and region=eu under ALL read (tier = gold or silver) and (region = eu). Every rule of the list takes the mode, and a rule created later joins its list's mode. The response carries a warning when the switch leaves a value both included and excluded, at this level or against a level above. Requires UPDATE permission on the zone's site, MANAGE_SUPPLY_PRE_TARGETING and the type's own targeting permission (e.g. PRETARGETING_COOKIE_VALUE).
Path Params
zoneId integer required
Unique numeric ID of the zone
200 Form Params
type string required
Targeting type whose list to set — COOKIE_VALUE, CUSTOM, DMP or API_JSON_FIELD
COOKIE_VALUE rule string required
Which list to set — INCLUDE or EXCLUDE
INCLUDE matchMode string required
ANY — one group is enough; ALL — every group must match
ALL Responses
200
Success — the response carries the type, the rule, the saved matchMode, how many rules changed (updated) and, when a value is now both included and excluded, a warning
400
Missing or unknown type, rule or matchMode, a type without a match mode, or no rules of that type in that list
401
Unauthorized
403
Forbidden
404
Zone not found
500
Internal server error