PLATFORM_VERSION targeting


#1

Hi,

When we POST to the accounts/:account_id/targeting_criteria endpoint and target PLATFORM_VERSION = iOS 8.0, does that target only iOS 8.0 or all versions greater than or equal to iOS 8.0?

Thanks.


#2

Hi, @kai.

PLATFORM_VERSION targets versions greater than or equal to the specified value.

Below is an example of how to do this using twurl.

$ twurl -H ads-api.twitter.com "/1/targeting_criteria/platform_versions?q=8.0" | jq .

{
  "data_type": "targeting_criterion",
  "data": [
    {
      "number": "8.0",
      "name": "8.0",
      "platform": "iOS",
      "targeting_value": "j",
      "targeting_type": "PLATFORM_VERSION"
    }
  ],
  "request": {
    "params": {
      "q": "8.0"
    }
  }
}

Then, we can use the j targeting value, like so:

$ twurl -X POST -H ads-api.twitter.com "/1/accounts/xxxxx/targeting_criteria?line_item_id=aaaa&targeting_type=PLATFORM_VERSION&targeting_value=j" | jq .

{
  "data_type": "targeting_criterion",
  "data": {
    "line_item_id": "aaaa",
    "name": "8.0",
    "id": "...",
    "account_id": "xxxxx",
    "created_at": "2016-08-16T00:00:00Z",
    "targeting_value": "j",
    "updated_at": "2016-08-16T00:00:00Z",
    "deleted": false,
    "targeting_type": "PLATFORM_VERSION"
  },
  "request": {
    "params": {
      "line_item_id": "aaaa",
      "targeting_type": "PLATFORM_VERSION",
      "targeting_value": "j",
      "account_id": "xxxxx"
    }
  }
}

Hope this helps. Thanks!