How can we get the Campain ID and Ad Group ID

897 views
Skip to first unread message

sho...@multipliersolutions.in

unread,
Jan 2, 2015, 2:26:48 AM1/2/15
to adwor...@googlegroups.com
Hi..

I am integrating google adwords api in my website. For user flexibility, I want to show their campaigns that they are running and also to show their ad groups for their account.
I just wanted to know the Code  to generate the Campaign ID with name and Ad group ID with name 

Thanks

Josh Radcliff (AdWords API Team)

unread,
Jan 2, 2015, 9:59:54 AM1/2/15
to adwor...@googlegroups.com
Hi,

There are a few ways to get this information.

1. AdWords SOAP services
You can use the AdGroupService to get all ad groups. If you include the Id and CampaignId fields in your Selector, then you'll get back the ad group ID and campaign ID combination for each ad group. If you are using one of our client libraries, check out the GetAdGroups example in the client library's basicoperations folder (e.g., the Java example is here).

2. Reports
You can run the AD_GROUP_PERFORMANCE_REPORT and include the AdGroupId and CampaignId fields in your report request. If you want to include ad groups without impressions, see the Zero Impression Reports guide. If you are using one of our client libraries, check out the DownloadCriteriaReport example in the client library's reporting folder.

Cheers,
Josh, AdWords API Team
Reply all
Reply to author
Forward
0 new messages