AI-generated Key Takeaways
-
This page provides code samples for various Google Ads API functionalities, categorized by operation type.
-
You can browse examples for account management, advanced operations, assets, authentication, basic operations, billing, campaign management, error handling, miscellaneous tasks, planning, recommendations, remarketing, reporting, shopping ads, targeting, and travel.
-
To explore a sample, select an example and then choose your desired programming language.
-
Each sample includes a link to its source code on GitHub for easy access and reference.
Select an example and then the language tab of your choice. A link to its GitHub source can be found at the end of each sample.
Account Management
- Create customer
- Get account hierarchy
- Get change details
- Get change summary
- Invite user with access role
- Link manager to client
- List accessible customers
- Update user access
- Verify advertiser identity
Advanced Operations
- Add ad customizer
- Add ad group bid modifier
- Add app campaign
- Add bidding data exclusion
- Add bidding seasonality adjustment
- Add call ad
- Add display upload ad
- Add dynamic page feed asset
- Add dynamic search ads
- Add Performance Max campaign
- Add smart campaign
- Create and attach shared keyword set
- Find and remove criteria from shared set
- Get ad group bid modifiers
- Use cross account bidding strategy
- Use portfolio bidding strategy
Assets
Authentication
Basic Operations
- Add ad groups
- Add campaigns
- Get campaigns
- Get responsive search ads
- Pause ad
- Remove campaign
- Search for Google Ads fields
- Update ad group
- Update campaign
- Update responsive search ad
Billing
Campaign Management
- Add campaign labels
- Add complete campaigns using batch job
- Create experiment
- Get all disapproved ads
- Set ad parameters
- Update campaign criterion bid modifier
- Validate ad
Error Handling
Misc
Planning
- Forecast reach
- Generate forecast metrics
- Generate historical metrics
- Generate keyword ideas
- Get ad group criterion CPC bid simulations
Recommendations
Remarketing
- Add conversion action
- Add conversion based user list
- Add custom audience
- Add customer match user list
- Add dynamic remarketing asset
- Add flexible rule user list
- Add logical user list
- Add merchant center dynamic remarketing campaign
- Set up advanced remarketing
- Set up remarketing
- Update audience target restriction
- Upload call conversion
- Upload conversion adjustment
- Upload enhanced conversions for leads
- Upload enhanced conversions for web
- Upload offline conversion
- Upload store sales transactions
Reporting
Shopping Ads
- Add listing scope
- Add Performance Max product listing group tree
- Add Performance Max retail campaign
- Add Shopping product ad
- Add Shopping product listing group tree
- Get product category constants
Targeting
- Add campaign targeting criteria
- Add customer negative criteria
- Add demographic targeting criteria
- Get geo target constants by names

