If you create radius targeting through the UI, you'll see that you get a Proximity object as I described. For example, I used the UI to create radius targeting around two areas in my campaign: postal code 11215, and Paris, France. This resulted in the CampaignCriterion list shown at the end of this message.
<rval>
<geoPoint>
<latitudeInMicroDegrees>48856614</latitudeInMicroDegrees>
<longitudeInMicroDegrees>2352221</longitudeInMicroDegrees>
</geoPoint>
<address>
<cityName>Paris</cityName>
<countryCode>FR</countryCode>
</address>
<encodedLocation>...</encodedLocation>
<GeoLocation.Type>GeoLocation</GeoLocation.Type>
</rval>
</getResponse>
You could then use that GeoPoint to construct your Proximity object.
<entries>
<campaignId>xxx</campaignId>
<isNegative>false</isNegative>
<id>95050702855</id>
<type>PROXIMITY</type>
<Criterion.Type>Proximity</Criterion.Type>
<geoPoint>
<latitudeInMicroDegrees>40683006</latitudeInMicroDegrees>
<longitudeInMicroDegrees>-73980064</longitudeInMicroDegrees>
</geoPoint>
<radiusDistanceUnits>KILOMETERS</radiusDistanceUnits>
<radiusInUnits>20.0</radiusInUnits>
<address>
<cityName>Brooklyn</cityName>
<provinceName>NY</provinceName>
<postalCode>11215</postalCode>
<countryCode>US</countryCode>
</address>
</criterion>
<CampaignCriterion.Type>CampaignCriterion</CampaignCriterion.Type>
</entries>
<entries>
<campaignId>xxx</campaignId>
<isNegative>false</isNegative>
<id>98646096895</id>
<type>PROXIMITY</type>
<Criterion.Type>Proximity</Criterion.Type>
<geoPoint>
<latitudeInMicroDegrees>48856614</latitudeInMicroDegrees>
<longitudeInMicroDegrees>2352221</longitudeInMicroDegrees>
</geoPoint>
<radiusDistanceUnits>MILES</radiusDistanceUnits>
<radiusInUnits>20.0</radiusInUnits>
<address>
<cityName>Paris</cityName>
<countryCode>FR</countryCode>
</address>
</criterion>
<CampaignCriterion.Type>CampaignCriterion</CampaignCriterion.Type>
</entries>
On Monday, August 4, 2014 3:55:50 PM UTC-4, Dzmitry Zahusta wrote:
Hi,
For example, even in US there are several cities with the same name - try "Paris" or "London". And if with criteria id I can uniquely choose the proper city, I have no idea how to choose the proper one (that correspond to the same city identified by criteria id) using
GeoLocationService.
Do you know any solution?
понедельник, 4 августа 2014 г., 21:18:48 UTC+3 пользователь Josh Radcliff (AdWords API Team) написал: