Hi, I am having same problem with PHP api. I tried to create location and language criterions after adding a campaign. So in that page I have called CampaignService for adding a new campaign and after CampaignCriterionService for adding the criterions. Once I got campaigns get added but not criterions and getting a error saying "connection terminated". Even I can't see any request made to CampaignCriterionService.
I have same issue with AdgroupService and AdGroupCriterionService for adding adgroup and keywords. Adgroup get added and keywords are not. Let me know what I am doing wrong here. On Wednesday, May 21, 2014 2:26:31 PM UTC+5:30, Ray Tsang (AdWords API Team) wrote: > > Charles - that sounds about right. Criterions are added after campaign > creation. > > Cheers, > > Ray > > On Wednesday, May 21, 2014 1:58:28 PM UTC+8, charles wrote: >> >> After a bit of digging it appears the best way to do this might be in two >> steps: >> 1. Create the campaign >> 2. Then add criteria separately >> >> According to the location targeting guide >> <https://developers.google.com/adwords/api/docs/guides/location-targeting>, >> "you need to create Location objects for each region you want to target and >> add them using CampaignCriteronService.mutate." >> >> And looking back over the aforementioned >> add_campaign_targeting_criteria.rb example it appears an existing >> campaign ID is necessary to add criteria. >> >> So it appears OP might be answered, but in case I've missed something or >> if I'm going about this the wrong way feel free to add your feedback. >> >> On Tuesday, May 20, 2014 10:26:25 PM UTC-7, charles wrote: >>> >>> Are there examples specific to the Ruby client lib for adding (e.g.) >>> location criteria/criterion during campaign creation? >>> >>> I've read the add_campaigns.rb >>> <https://github.com/googleads/google-api-ads-ruby/blob/master/adwords_api/examples/v201402/basic_operations/add_campaigns.rb> >>> example >>> which uses CampaignService for campaign creation. >>> >>> And I've read the add_campaign_targeting_criteria.rb >>> <https://github.com/googleads/google-api-ads-ruby/blob/master/adwords_api/examples/v201402/targeting/add_campaign_targeting_criteria.rb> >>> >>> which uses CampaignCriterionService for adding location criteria. >>> >>> But I haven't seen any examples which use both services during campaign >>> creation, and (as a novice Rubyist) I'm wondering what are some recommended >>> patterns. >>> >>> If I've missed something in the github repo or other developer docs >>> please feel free to point me in the right direction. Otherwise I'm keen to >>> know how others add campaign-level criteria during campaign creation. >>> >>> Thanks! >>> >> -- -- =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ Also find us on our blog and Google+: https://googleadsdeveloper.blogspot.com/ https://plus.google.com/+GoogleAdsDevelopers/posts =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~ You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To post to this group, send email to adwords-api@googlegroups.com To unsubscribe from this group, send email to adwords-api+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/adwords-api?hl=en --- You received this message because you are subscribed to the Google Groups "AdWords API Forum" group. To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.