Object representing the human-readable description of a set of targeting specs
The values returned in a targeting description are
| Name | Description | Permissions | Returns |
|---|---|---|---|
targetingsentencelines |
The human-readable description of the targeting | ads_management |
array of string |
id |
The ID of the targetingsentencelines. Returned only querying an existing adgroup |
ads_management |
string |
params |
The targeting spec used to generate the description. This is returned only when querying an arbitrary targeting spec. This will represent the targeting parameters described in the targetingsentencelines response. |
ads_management |
targeting-spec |
params value may differ from what you provided when making your request if the provided values were autocorrected. For example, if you specify {'age_min':10} in your request, params will show {'age_min':13} which is the minimum supported.The adgroup object has a targetingsentencelines connection of this type which returns the description of the targeting for that adgroup.
When requesting the targetingsentencelines connection of an existing adgroup the request format is:
/1234567890/targetingsentencelines
And a sample response is:
{
"id": "1234567890/targetingsentencelines",
"targetingsentencelines": [
"who live in Ireland",
"exactly between the ages of 20 and 35 inclusive",
"who are female",
"who are not already connected to [PAGE NAME]"
]
}
The adaccount object has a targetingsentencelines connection of this type which returns the description of the targeting for an arbitrary targeting spec on that account, which must be supplied in the targeting_spec parameter, and formatted following the instructions in the targeting specs documentation.
Checking the targeting description for users in the US who are in a relationship, engaged, or married
curl "https://graph.facebook.com/act_368811234/targetingsentencelines?targeting_spec=%7B'countries'%3A%5B'US'%5D%2C'relationship_statuses'%3A%5B2%2C3%2C4%5D%7D&access_token=____"
The response format is:
{
"params": {
"countries": [
"US"
],
"relationship_statuses": [
2,
3,
4
]
},
"targetingsentencelines": [
"who live in the United States",
"who are in a relationship, married or engaged"
]
}