<!--
{
  "availability" : [
    "Apple Ads Platform API: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Apple-Ads-Platform-API",
  "identifier" : "/documentation/Apple-Ads-Platform-API/Rule/Value-data.dictionary",
  "metadataVersion" : "0.1.0",
  "role" : "Object",
  "symbol" : {
    "kind" : "Object",
    "modules" : [
      "Apple Ads Platform API"
    ],
    "preciseIdentifier" : "data:apple-ads-platform-api:Rule.Value"
  },
  "title" : "Rule.Value"
}
-->

# Rule.Value

The comparison value for a targeting rule, as either a single string or an array of strings.

```
object Rule.Value
```

## Discussion

The `Rule.value` field accepts either a single string or an array of strings, depending on the rule’s `operator`. Pass a string for `EQUALS` and `NOT_EQUALS`. Pass an array of strings for `IN` and `NOT_IN`.

The expected string format also depends on `field`: a plain name for `adminArea` and `postalCode`, a pipe-delimited `countryOrRegion|adminArea|locality` string for `locality`, and a location ID string for `locationId`. See [`Rule`](/documentation/Apple-Ads-Platform-API/Rule) for the full list of supported `field` values.

### Example

```json
{
  "field": "locality",
  "operator": "IN",
  "value": ["US|New York|Brooklyn", "US|California|San Francisco"]
}
```

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)