Browse the help center

Replace a stale location

Swaps one stale location rule for a rule naming a place the geo database knows, with the same include or exclude and the same entity, and removes the stale rule; both changes are written to the action log.

Reference
POST https://YOUR-NETWORK-DOMAIN/rest-api/targeting/stale-locations/replace.do

Swaps one stale location rule for a rule naming a place the geo database knows, with the same include or exclude and the same entity, and removes the stale rule; both changes are written to the action log. Region and city are optional and checked like location targeting create. When the entity already has that rule, only the stale one is removed and 'alreadyPresent' is true. Country rules cannot be replaced; remove them instead.

Form Params

targetId integer required

Id of the stale location rule

8012

countryCode string required

ISO 3166-1 alpha-2 country code of the new place

US

regionName string

Region of the new place, as GET /rest-api/targeting/country/region/values.do lists it

Nevada

cityName string

City of the new place, as GET /rest-api/targeting/country/region/city/values.do lists it

Las Vegas

Responses

200

{success, removedId, targetId, value, alreadyPresent}

400

Unknown country code, region or city, or the rule is a country rule

401

Authentication error

403

The role may not change this rule

404

Not a stale rule the user may manage

503

The geo service did not answer

Please disable Adblock
Are you using adblock? Disable it and reload the page to proceed to the destination page.

A registration has already been submitted from this page. Please try again in 10 minutes.