PHP API - TargetingIdeaService - RelatedToUrlSearchParameter - [TargetingIdeaError.INVALID_SEARCH_PARAMETERS @ selector.selector.searchParameters[2].includeSubUrls]

673 views
Skip to first unread message

Josh

unread,
Jun 22, 2012, 8:02:25 AM6/22/12
to adwor...@googlegroups.com
Hi,

it looks as if the includeSubUrls parameter is not correctly supported as I keep getting this error :

[TargetingIdeaError.INVALID_SEARCH_PARAMETERS @ selector.selector.searchParameters[2].includeSubUrls]

My code is really straightforward :

  $targetingIdeaService = $user->GetTargetingIdeaService('v201109');
  // Create selector.
  $selector = new TargetingIdeaSelector();
  $selector->requestType = 'IDEAS';
  $selector->ideaType = 'KEYWORD';
  $selector->requestedAttributeTypes =
              array('CRITERION', 'AVERAGE_TARGETED_MONTHLY_SEARCHES', 'COMPETITION', 'NGRAM_GROUP');

  // Set selector paging (required for targeting idea service).
  $paging = new Paging();
  $paging->startIndex = 0;

$paging->numberResults = 50;

$search = new RelatedToUrlSearchParameter();
$search->urls = 'www.foo.com';
$search->includeSubUrls = true;

Kevin Winter

unread,
Jul 23, 2012, 10:59:02 AM7/23/12
to adwor...@googlegroups.com
Hi,
  The documentation indicates that for KEYWORD requests (ideaType), this field isn't supported: https://developers.google.com/adwords/api/docs/reference/latest/TargetingIdeaService.RelatedToUrlSearchParameter#includeSubUrls

- Kevin Winter
AdWords API Team

Josh

unread,
Jul 23, 2012, 1:57:30 PM7/23/12
to adwor...@googlegroups.com
Hi,

thanks for the answer.

Sorry I must be blind but the I don't see such mention in provided link, the documentation states :

- "This element is supported by following RequestTypes: IDEAS, STATS. "
- "This search parameter can be used in bulk keyword requests through the TargetingIdeaService.getBulkKeywordIdeas(TargetingIdeaSelector) method"

I'm not using the Bulk Method but this parameter was also used to be supported by versions prior to v201109

Alexander Nitschke

unread,
Jul 24, 2012, 4:41:54 AM7/24/12
to adwor...@googlegroups.com
Hi Josh,

please look further down to the documentation for "includeSubUrls". This one is ignored for "KEYWORD" queries, generally the KEYWORD idea query supports only one Url. But I think Kevin's link was misleading as he linked to the v201206 doc and your code is using v201109. Still, the documentation for this specific field hasn't changed.

Alexander

Josh

unread,
Jul 24, 2012, 2:26:17 PM7/24/12
to adwor...@googlegroups.com
Hi Alexander,

so can I assume or not the bulk method will allow for using includeSubUrls ?

Josh

Kevin Winter

unread,
Jul 24, 2012, 5:51:26 PM7/24/12
to adwor...@googlegroups.com
Hi Josh,
  The getBulkKeywordIdeas only returns keywords - since includeSubUrls doesn't work for keywords, you can't use it in bulk either.

- Kevin Winter
AdWords API Team
Reply all
Reply to author
Forward
0 new messages