targetingGeobase
Target a campaign by geography.
Request format
https://adfox.yandex.com/api/v1
  ? object=campaign
  & action=target
  & actionObject=targetingGeobase
  & objectID=<integer>
  & geo=<integer>
  & [global=<integer>]
  & [regions=<string>]
        
    | 
 
  | 
 ID of the object that the action is performed on.  | 
| 
 
  | 
 Enable targeting by geography. Acceptable values: 
  | 
| 
 
  | 
 Setting up the Whole world option, which you can use to specify the targeting logic: 
 Acceptable values: 
  | 
| 
 
  | 
 Specify the targeting status for regions. Entry format:  Acceptable values: 
 For example,  You can also configure the Whole world option using the   | 
* Required
Response format
<response>
<status>
  <code>{integer}</code>
</status>
</response>
        
    Response parameters
| 
 
  | 
 Request processing status. For the key, see Error handling.  | 
Sample request and response
Request:
https://adfox.yandex.com/api/v1?object=campaign&action=target&actionObject=targetingGeobase&objectID=474205Response:
<response> <status> <code>0</code> </status> </response>
Other actions with the object
See more actions with the campaign object:
- Add a campaign.
 - Get a list of campaigns.
 - Delete a campaign.
 - Edit a campaign.
 - Get a list of campaign banners.
 - Place a campaign on a site, a site section, or a placement.
 
ID of the object that the action is performed on.
Enable targeting by geography.
Acceptable values:
- 
0: Disable. - 
1: Enable. 
Setting up the Whole world option, which you can use to specify the targeting logic:
- 
Allow everything except: If there are fewer objects to exclude, enable the Whole world option and exclude certain objects from the list.
 - 
Prohibit everything except: If you want to enable impressions only for certain objects, disable the Whole world option and include the necessary objects in the list.
 
Acceptable values:
- 
0: Reset. Inherited from the parent element. - 
1: Allowed. - 
2: Forbidden. 
Specify the targeting status for regions.
Entry format: {"Region ID":value,"Region ID":value}.
Acceptable values:
- 
0: Reset. Inherited from the parent element. - 
1: Allowed. - 
2: Forbidden. 
For example, regions={"225":1} allows impressions in Russia.
You can also configure the Whole world option using the regions parameter with ID=10000. This setting takes priority over the value that's passed in the global parameter.
Required