gads_create_display_campaign
Google Ads write high risk
Part of the Display Campaign Agent.
What it does
Creates a Display campaign (advertising_channel_type=DISPLAY): builds the CampaignBudget, the Campaign (network_settings.target_content_network=true), bidding strategy, and optional frequency capping (campaign.frequency_caps, applied at create). Geo/language/audience criteria are NOT set at create — apply them after with gads_add_location_targeting / gads_add_language_targeting / gads_attach_audience_to_ad_group (passing them here returns a warning). Image/responsive display assets and ad groups are added separately. Inputs: customer_id, name, daily budget (micros), bidding goal (MAXIMIZE_CONVERSIONS [+tCPA], TARGET_CPA, TARGET_ROAS, or MAXIMIZE_CLICKS), optional frequency capping, start/end (geo/languages/audiences are post-create steps). Money is micros (÷1e6). PREVIEW->APPROVE->COMMIT: validate_only=true preview (no creation) -> plain-English diff (budget/day, audience reach, bidding goal, geo, status) -> approval -> execute (atomic: budget and campaign together or neither) -> resource_name + timestamp + audit log. Defaults PAUSED. Returns standard envelope. PREVIEW SEMANTICS: the first call (no preview_id) is sent to the Google Ads API in validation mode — field, enum, policy and permission errors surface AT PREVIEW, nothing is changed, and the response returns a preview_id. To apply, show the preview to the user, get their approval, and re-call with that preview_id and IDENTICAL arguments within 30 minutes; changed arguments or an expired token fail closed to a fresh preview. validate_only=true forces another preview; validate_only=false alone never commits.
When to use it
Use for image/responsive-display awareness or remarketing campaigns across the Google Display Network. Confirm budget, audience scope, and frequency cap, and require explicit go-live approval before ENABLING. If audiences include any personal/customer-match data, confirm consent and terms first. First call gads_plan_display_campaign for the campaign blueprint, operation ordering, and policy pre-checks.
Inputs
| Name | Type | Required | Description |
|---|---|---|---|
customer_id | string | yes | 10-digit CID, dashes stripped; operating account. |
name | string | yes | Unique campaign name. |
budget_amount_micros | integer | yes | Daily budget in micros (currency ×1e6). |
bidding_strategy | object | yes | {type:MAXIMIZE_CONVERSIONS|TARGET_CPA|TARGET_ROAS|MAXIMIZE_CLICKS, target_cpa_micros?, target_roas?}; enum-normalize. |
geo_targets | array | no | Accepted but NOT applied at create (a warning says so) — apply with gads_add_location_targeting after create. |
languages | array | no | Accepted but NOT applied at create (a warning says so) — apply with gads_add_language_targeting after create. |
audiences | array | no | Accepted but NOT applied at create (a warning says so) — attach with gads_attach_audience_to_ad_group after create. No personal/customer-match data without consent under Google customer-match terms. |
frequency_cap | object | no | {impressions, time_unit:DAY|WEEK|MONTH, level?:CAMPAIGN|AD_GROUP|AD_GROUP_AD (default CAMPAIGN), time_length? (default 1)} — applied at create as campaign.frequency_caps. |
status | enum | no | ENABLED|PAUSED; defaults PAUSED. |
start_date | string | no | YYYY-MM-DD; default today. |
end_date | string | no | YYYY-MM-DD; optional. |
declare_eu_political | boolean | no | Set true ONLY if the campaign contains EU political advertising (Google requires the contains_eu_political_advertising declaration on every new campaign; omitted -> declares does-not-contain, which is a FALSE declaration for EU political ads). The preview names the declaration it sends, for the user to confirm. |
validate_only | boolean | no | Optional. true forces another preview even with a preview_id; false is DEPRECATED and no longer commits — only a valid preview_id applies the write. |
preview_id | string | no | Omit it to preview: nothing is applied, and the call returns a preview_id bound to this exact request. Pass it only after the user approves that preview in a later message, with the same arguments (leave out validate_only, and add any confirmation flag the preview names). Single-use, expires in 30 minutes; changed arguments need a fresh preview. |
Safeguards
A change in two steps. The first call previews and changes nothing; Claude shows you the preview and applies it only after you approve, within 30 minutes and with the same arguments. Every applied change goes to the audit log. How changes are approved.
Policy
Display creatives are subject to editorial + Misrepresentation review and Display-specific destination and personalized-ads policies. Audience targeting must respect privacy — no sensitive-interest categories, and no personal/customer-match data without consent under Google customer-match terms. Restricted verticals need certification. Never recreate disapproved creative to circumvent enforcement.
Reminder
Preview with validate_only, approve the diff, default PAUSED; use audience/personal data only with consent under customer-match terms and respect member privacy.
Errors
| Error class | Means | What to do | Retry |
|---|---|---|---|
CUSTOMER_NOT_FOUND | Customer ID not found / not accessible. | Verify CID and access; prompt re-auth if needed. | no |
TOKEN_REVOKED | OAuth token invalid/revoked (401). | Refresh; if still failing set needs_reauth. | no |
OPERATION_ON_MANAGER_ACCOUNT | Cannot create a campaign on an MCC. | Use a non-manager operating account. | no |
INVALID_ARGUMENT | Preview validation failed (bad bidding/audience/network config). | Surface platform message verbatim; correct and re-preview. | no |
PERMISSION_DENIED | Missing write scope / out-of-bearer-scope (403). | Confirm scope + role; re-consent. | no |
RESOURCE_EXHAUSTED | Rate/quota exceeded (429). | Backoff 5->10->20s cap 60s, honor retryDelay, retry once. | yes |
PLATFORM_UNAVAILABLE | Google Ads API 5xx/INTERNAL. | Retry once with backoff; do not assume creation succeeded. | yes |
Edge cases
- Audiences are not applied at create (a warning says so); attaching a remarketing/customer-match audience later needs consent + customer-match terms.
- Frequency cap is optional; without it impressions per user are uncapped — note this.
- validate_only preview never executes; commit is separate and idempotent on retry.
- Shared budget affects other campaigns — warn.
- Empty/no audience -> broad reach; the campaign still serves but may waste spend — flag.
- Preview TTL expiry -> re-preview.
- Default PAUSED; ENABLE only on go-live.
- Expired token mid-call -> refresh once and retry.