Hi,
  I believe I responded to this complaint off-list.  I think the issue is 
that your RelatedToUrlSearchParameter is being constructed by passing in 
the string URL rather than an array of strings (as the 
RelatedToKeywordSearchParameter is).

- Kevin Winter
AdWords API Team

On Monday, March 5, 2012 9:22:45 AM UTC-5, Michael T wrote:
>
> Hi, could someone help? I need to use the RelatedToUrlSearchParameter to 
> limit my results by URL.
>
> Thanks!
>
> On Monday, February 27, 2012 4:04:25 PM UTC-7, Michael T wrote:
>>
>> Hi, I am trying to get some data using tergetingIdeaService with 
>> keywords, url and country as the search parameters. The code works just 
>> fine if I exclude the url.
>>
>> error: [CollectionSizeError.TOO_MANY @ 
>> selector.selector.searchParameters[2].urls; errorDetails:actual: 1, max: 0]
>>
>> Any ideas?
>> Thanks!
>>
>> Code:
>>
>>   $keyword = new Keyword();
>>   $keyword->text = 'test';
>>   $keyword->matchType = 'BROAD';
>>   $keyword_array = array($keyword);
>>
>>   $relatedToKeywordSearchParameter = new 
>> RelatedToKeywordSearchParameter($keyword_array);
>>
>>   $countryTargetSearchParameter = new LocationSearchParameter();
>>
>>   $location1 = new location();
>>   $location1->id = '2840';
>>
>>   $countryTargetSearchParameter->locations = array($location1);
>>
>>  
>>   $relatedToUrlSearchParameter = new RelatedToUrlSearchParameter('
>> http://www.google.com/');
>>
>>   $targetingIdeaSelector = new TargetingIdeaSelector();
>>
>>   $targetingIdeaSelector->searchParameters = array(
>>         $relatedToUrlSearchParameter
>> ,$relatedToKeywordSearchParameter
>>         ,$countryTargetSearchParameter
>>     );
>>
>>   $targetingIdeaSelector->ideaType = 'KEYWORD';
>>   $targetingIdeaSelector->requestType = 'STATS';
>>   $targetingIdeaSelector->requestedAttributeTypes = 
>> array('CRITERION','TARGETED_MONTHLY_SEARCHES');
>>
>>   $targetingIdeaSelector->paging = new Paging(0,5);
>>
>>   $page = $targetingIdeaService->get($targetingIdeaSelector);
>>
>>
>>
>>

-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
http://adwordsapi.blogspot.com
http://groups.google.com/group/adwords-api
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en

Reply via email to