For the complete documentation index, see llms.txt. Markdown versions of documentation pages are available by appending .md to the page URL.
Primary navigation
Overview Agent Access Ads ChatGPT + Codex user docs Use cases

API Reference

Update Ad Group

POST
/ad_groups/{ad_group_id}

Update an ad group.

All fields are optional on update. description can be set to null to clear it. To switch strategies, send the billing event and the fields required for the new strategy. To update a fixed bid amount, send the current billing_event_type and max_bid_micros in bidding_config and omit strategy. To update a target bid amount, send the current billing_event_type, explicitly set strategy to the existing target_cpa or target_cpc, and send target_micros; omit max_bid_micros. status accepts active, paused, or archived. For a product-feed campaign, include the full product_set object to change the feed or its filters. Retrieve the ad group after the update if you need the resulting product_set; the immediate update response can omit it.

Update Ad Group

curl https://api.ads.openai.com/v1/ad_groups/$AD_GROUP_ID \
    -X POST \
    -H "Authorization: Bearer $OPENAI_ADS_API_KEY"
200 — Example
{
  "id": "id",
  "bidding_config": {
    "billing_event_type": "billing_event_type",
    "custom_audience_bid_multipliers": [
      {
        "bid_multiplier_micros": 0,
        "custom_audience_id": "custom_audience_id"
      }
    ],
    "max_bid_micros": 0,
    "strategy": "fixed_bid",
    "target_micros": 0,
    "target_strategy": "target_cpc"
  },
  "context_hints": [
    "string"
  ],
  "created_at": 0,
  "description": "description",
  "name": "name",
  "status": "status",
  "updated_at": 0,
  "advertiser_phone_verification_required": true,
  "enable_dynamic_creative": true,
  "geographic_targeting_blocked": true,
  "landing_page_configuration": {
    "query_string_template": "query_string_template"
  },
  "product_set": {
    "filters": [
      {
        "field": "field",
        "operator": "operator",
        "values": [
          "string"
        ]
      }
    ],
    "product_feed_id": "product_feed_id"
  },
  "serving_issues": [
    {
      "code": "ad_account_suspended"
    }
  ]
}
Path Parameters
ad_group_id: string
Body Parameters
JSON
bidding_config: optional object { billing_event_type, custom_audience_bid_multipliers, max_bid_micros, 2 more }
billing_event_type: "impression" or "click"

Match the campaign billing event: impression for impression campaigns and click for click campaigns. Conversion campaigns support click billing or, for accounts enabled for oCPM, impression billing. Qualified-lead and Conversations campaigns require impression billing and eligibility for those campaign modes.

One of the following:
"impression"
"click"
custom_audience_bid_multipliers: optional array of object { bid_multiplier_micros, custom_audience_id }
bid_multiplier_micros: integer

Bid multiplier in millionths: 100000 is 0.1x and 10000000 is 10x.

minimum100000
maximum10000000
custom_audience_id: string

Audience returned by GET /custom_audiences?intended_use=bid_multiplier. Exclusion eligibility alone does not imply bid-adjustment eligibility.

max_bid_micros: optional integer

Bid amount in account-currency micros per event. For example, USD 60 CPM is 60000 micros per impression. When a legacy bid selects target bidding, this amount sets the target average cost per outcome; strategy selection can depend on account eligibility. When strategy is explicitly target_cpa or target_cpc, omit max_bid_micros and provide target_micros instead.

minimum1
maximum30400000000000
strategy: optional "fixed_bid" or "maximize_clicks" or "maximize_conversions" or 2 more

To use the default AutoBid strategy for clicks or conversions, omit both strategy and max_bid_micros. When creating an ad group or changing its strategy, you can send max_bid_micros and either omit strategy or set it to fixed_bid. On enrolled accounts, this selects target_cpa for eligible conversion ad groups and target_cpc for eligible click ad groups in any supported account currency. Otherwise, including for Reach campaigns, it selects fixed_bid. To update a fixed bid amount, send max_bid_micros with the existing billing_event_type and omit strategy. To update a target bid amount, send the existing billing_event_type, explicitly set strategy to the existing target_cpa or target_cpc, and send target_micros; omit max_bid_micros.

One of the following:
"fixed_bid"
"maximize_clicks"
"maximize_conversions"
"target_cpc"
"target_cpa"
target_micros: optional integer

Target average cost per outcome in account-currency micros. Requires strategy to be set to target_cpa or target_cpc.

minimum1
context_hints: optional array of string

Replacement list of context descriptions or keywords. Omit to preserve the current hints.

maxItems2000
description: optional string or null
enable_dynamic_creative: optional boolean
landing_page_configuration: optional object { query_string_template } or null
query_string_template: optional string
maxLength2048
name: optional string
pattern^.*\S.*$
minLength3
maxLength1000
product_set: optional object { product_feed_id, filters } or null

Send the full product-set object when changing filters. Retrieve the ad group afterward if the immediate update response omits product_set.

product_feed_id: string
filters: optional array of object { field, operator, values }
field: string

Feed attribute to filter. Filters are combined with AND. You can repeat a field to express a bounded range, for example price gte a lower bound and price lte an upper bound.

operator: "in" or "not_in" or "gt" or 6 more

Use in for membership; gt, gte, lt and lte only with price or star_rating.

One of the following:
"in"
"not_in"
"gt"
"gte"
"lt"
"lte"
"contains"
"not_contains"
"starts_with"
values: array of string

Match values. Numeric comparisons still use strings, for example ["4.5"].

status: optional "active" or "paused" or "archived"
One of the following:
"active"
"paused"
"archived"
Returns
id: string
bidding_config: object { billing_event_type, custom_audience_bid_multipliers, max_bid_micros, 3 more }
billing_event_type: string
custom_audience_bid_multipliers: optional array of object { bid_multiplier_micros, custom_audience_id }
bid_multiplier_micros: integer
custom_audience_id: string
max_bid_micros: optional integer
strategy: optional "fixed_bid" or "automated_bid" or "maximize_clicks" or "maximize_conversions"
One of the following:
"fixed_bid"
"automated_bid"
"maximize_clicks"
"maximize_conversions"
target_micros: optional integer
target_strategy: optional "target_cpc" or "target_cpa"

For target bidding, this field identifies the strategy and target_micros gives the amount. Use strategy in requests.

One of the following:
"target_cpc"
"target_cpa"
context_hints: array of string
created_at: integer
formatunixtime
description: string or null
name: string
status: string
updated_at: integer
formatunixtime
advertiser_phone_verification_required: optional boolean
enable_dynamic_creative: optional boolean
geographic_targeting_blocked: optional boolean
landing_page_configuration: optional object { query_string_template } or null
query_string_template: string or null
product_set: optional object { filters, product_feed_id } or null
filters: array of object { field, operator, values }
field: string
operator: string
values: array of string
product_feed_id: string
serving_issues: optional array of object { code }
code: "ad_account_suspended" or "ad_account_brand_review_missing_favicon" or "ad_account_brand_review_escalated_review" or 20 more
One of the following:
"ad_account_suspended"
"ad_account_brand_review_missing_favicon"
"ad_account_brand_review_escalated_review"
"ad_account_brand_review_rejected"
"ad_account_brand_review_in_progress"
"ad_account_payment_method_missing_or_unauthorized"
"ad_account_threshold_payment_failed"
"ad_account_persona_verification_not_approved"
"ad_account_persona_verification_step_up_required"
"campaign_not_active"
"campaign_not_started"
"campaign_ended"
"ad_group_not_active"
"ad_group_has_no_ads"
"ad_group_has_no_serving_ready_ads"
"campaign_budget_exhausted"
"ad_account_budget_exhausted"
"review_not_approved"
"landing_page_crawl_issue"
"ad_in_review"
"partial_serving_review_not_approved"
"partial_serving_landing_page_crawl_issue"
"partial_serving_ad_in_review"
Returns Examples
200 — Example
{
  "id": "id",
  "bidding_config": {
    "billing_event_type": "billing_event_type",
    "custom_audience_bid_multipliers": [
      {
        "bid_multiplier_micros": 0,
        "custom_audience_id": "custom_audience_id"
      }
    ],
    "max_bid_micros": 0,
    "strategy": "fixed_bid",
    "target_micros": 0,
    "target_strategy": "target_cpc"
  },
  "context_hints": [
    "string"
  ],
  "created_at": 0,
  "description": "description",
  "name": "name",
  "status": "status",
  "updated_at": 0,
  "advertiser_phone_verification_required": true,
  "enable_dynamic_creative": true,
  "geographic_targeting_blocked": true,
  "landing_page_configuration": {
    "query_string_template": "query_string_template"
  },
  "product_set": {
    "filters": [
      {
        "field": "field",
        "operator": "operator",
        "values": [
          "string"
        ]
      }
    ],
    "product_feed_id": "product_feed_id"
  },
  "serving_issues": [
    {
      "code": "ad_account_suspended"
    }
  ]
}