> ## Documentation Index
> Fetch the complete documentation index at: https://docs.markifact.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Ad Group

> Creates a new ad group under a campaign in the connected OpenAI Ads account

Creates a new ad group under a campaign in the connected OpenAI Ads account.

|                       |                              |
| --------------------- | ---------------------------- |
| **App**               | OpenAI Ads                   |
| **Operation ID**      | `openai_ads_create_ad_group` |
| **Type**              | Action                       |
| **Connection**        | `openai_ads` (required)      |
| **Credits per run**   | 1                            |
| **Agent / MCP tool**  | Yes                          |
| **Requires approval** | Yes (write operation)        |

## Inputs

| Field                | Type                                          | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                    |
| -------------------- | --------------------------------------------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `campaign_id`        | string or SelectableOption                    | Yes      | -       | Parent campaign ID to create the ad group under (from openai\_ads\_list\_campaigns).                                                                                                                                                                                                                                                                                           |
| `name`               | string                                        | Yes      | -       | Ad group name (3-1000 characters).                                                                                                                                                                                                                                                                                                                                             |
| `status`             | string or SelectableOption                    | Yes      | -       | Ad group status: 'active' or 'paused'.                                                                                                                                                                                                                                                                                                                                         |
| `billing_event_type` | string or SelectableOption                    | Yes      | -       | Bid / billing event type. Must match the parent campaign's objective: 'click' (CPC) for a clicks campaign, 'impression' (CPM) for an impressions campaign, 'conversion' for a conversions campaign.                                                                                                                                                                            |
| `bid_amount`         | number                                        | Yes      | -       | Maximum bid in account currency (e.g. US dollars), i.e. 1.50 for \$1.50. This value is converted to micros automatically before sending to the API.                                                                                                                                                                                                                            |
| `context_hints`      | string or array of string                     | No       | -       | Optional context hints — conversations, topics, or keywords where your products or services may be relevant. These guide matching but aren't exact-match targeting. Provide one hint per line, or as a list.                                                                                                                                                                   |
| `product_feed_id`    | string                                        | No       | -       | Product feed ID, shown in the Feeds area of OpenAI Ads Manager (there is no API to list feeds). Required when the parent campaign's mode is 'product\_feed'; the ad group then advertises items from this feed.                                                                                                                                                                |
| `product_filters`    | string or array of OpenAIAdsProductFilterItem | No       | -       | Optional filters narrowing which feed items this ad group advertises (e.g. only a brand, or price above a threshold). A JSON list of \{"field", "operator", "values"} objects, e.g. \[\{"field": "brand", "operator": "in", "values": \["Acme"]}, \{"field": "price", "operator": "gt", "values": \["25.00"]}]. Only valid together with product\_feed\_id; filters are ANDed. |
| `description`        | string                                        | No       | -       | Optional ad group description.                                                                                                                                                                                                                                                                                                                                                 |

### OpenAIAdsProductFilterItem

| Field      | Type                       | Required | Default | Description                                                                                                                |
| ---------- | -------------------------- | -------- | ------- | -------------------------------------------------------------------------------------------------------------------------- |
| `field`    | string or SelectableOption | Yes      | -       | Feed attribute to filter on.                                                                                               |
| `operator` | string or SelectableOption | Yes      | -       | 'in' matches any of the values; 'gt'/'gte'/'lt'/'lte' are numeric comparisons, allowed only on 'price' and 'star\_rating'. |
| `values`   | string or array of string  | No       | -       | Values to match — a list or a comma-separated string. Numbers are sent as strings (e.g. '25.00').                          |
| `value`    | string or array of string  | No       | -       |                                                                                                                            |

### SelectableOption

| Field   | Type   | Required | Default | Description |
| ------- | ------ | -------- | ------- | ----------- |
| `value` | string | Yes      | -       |             |
| `label` | string | Yes      | -       |             |

## Output

**Type**: `Dict`

Returns the created ad group object exactly as returned by the OpenAI Ads API (id, name, status, bidding\_config, context\_hints, description, product\_set, campaign\_id, created\_at, updated\_at).

**Fields**: dynamic (depend on the inputs)

**Example**:

```json theme={"dark"}
{
  "id": "adgrp_...",
  "campaign_id": "cmpn_...",
  "name": "US English",
  "status": "active",
  "bidding_config": {
    "billing_event_type": "click",
    "max_bid_micros": 3500000
  },
  "context_hints": [
    "productivity"
  ]
}
```
