SCALIX help

← All tools

gads_enable_ad

Google Ads write medium risk

Part of the Google Ads Manager Agent.

What it does

Enable a paused ad by setting ad_group_ad.status = ENABLED via AdGroupAdService.MutateAdGroupAds update with update_mask=status. The ad resumes serving (if approved and its ad group/campaign are active) and can begin spending immediately. PREVIEW->APPROVE->COMMIT: validate_only=true dry run -> plain-English confirmation (ad, current status -> ENABLED, that it will start serving/spending) -> explicit approval -> execute -> confirm resource name + UTC timestamp + audit log. The preview shows the ad's current status and approval status next to ENABLED, warns that serving and spend start at once (also when the status can't be read), and flags a DISAPPROVED ad, which won't serve once enabled. An id already in the target status is flagged; when all of them are, the call returns changed: false and no preview_id, since there is nothing to approve. 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 to resume a paused ad the user explicitly wants live. Make clear it will start serving/spending right away (subject to approval and active parent group/campaign); preview with validate_only and apply only on explicit approval.

Inputs

NameTypeRequiredDescription
ad_idstringyesNumeric ad id.
ad_group_idstringyesParent ad group id.
customer_idstringyes10-digit CID, dashes stripped.
validate_onlybooleannoOptional. 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_idstringnoOmit 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

No content-policy risk, but enabling resumes spend — confirm explicitly. Do not enable an ad that was disapproved (re-serving disapproved content can compound enforcement); resolve the policy issue first.

Reminder

Enabling resumes real spend immediately — confirm and log; never re-enable disapproved content to evade review.

Errors

Error classMeansWhat to doRetry
CUSTOMER_NOT_FOUNDCustomer ID not found / unauthorized.Verify CID and authorization; re-auth if revoked.no
TOKEN_REVOKEDOAuth credential revoked/expired.Prompt reconnect (needs_reauth).no
INVALID_ARGUMENTStatus update rejected (e.g. ad removed) — surfacing Google's message.Surface exact error; verify the ad state.no
AD_DISAPPROVEDThe ad is disapproved and will not serve even if enabled.The preview shows approval_status and warns; read the policy topics with gads_get_disapproved_ads and fix the violation before enabling, do not just toggle status.no
PERMISSION_DENIEDScope/role does not permit writes here.Confirm adwords scope and editor role on this CID.no
MANAGER_ACCOUNT_WRITECannot mutate ads on an MCC.Target a client account.no
RESOURCE_EXHAUSTEDRate/quota exceeded (429).Backoff 5->10->20s cap 60s; honor retryDelay.yes
PLATFORM_UNAVAILABLEGoogle Ads API 5xx.Re-check state, then retry.yes

Edge cases

  • Ad already ENABLED -> success with changed: false and its current state, and no preview_id (nothing to approve).
  • Cannot enable a REMOVED ad -> INVALID_ARGUMENT.
  • Enabling a DISAPPROVED ad sets status but it still won't serve — the preview shows approval_status and warns, so the user isn't misled.
  • Won't serve if the parent ad group or campaign is paused — the spend warning says so, to avoid 'enabled but zero impressions' confusion.
  • One ad per call; the commit is atomic.
  • Preview TTL expiry -> re-preview; expired token -> refresh once, retry.