idempotency_key | string | No | - | Optional reusable key for this create request. Reuse the same key and payload after an uncertain response to avoid duplicates; use a new key for a new resource. |
ad_group_id | string or SelectableOption | Yes | - | Parent ad group ID to create the ad under (from openai_ads_list_ad_groups). |
name | string | Yes | - | Ad name (3-1000 characters). |
status | string or SelectableOption | Yes | - | Ad status: ‘active’ or ‘paused’. |
creative_type | string or SelectableOption | No | chat_card | Creative type. ‘chat_card’ (the default) is a standard ad with its own image and URL. ‘product_ad_template’ is for ad groups in a product-feed campaign: the image and URL come from the feed items, and title/body/price support tokens like {{product.title}} and {{product.price}}. |
title | string | Yes | - | Creative title / headline (3-50 characters). Product template ads can use tokens, e.g. {{product.title}}. |
body | string | Yes | - | Creative body text (up to 100 characters). Product template ads can use tokens, e.g. {{product.body}}. |
price | string | No | - | Optional price text shown on the creative, e.g. ‘$29.99’ — or the {{product.price}} token on product template ads. |
target_url | string | No | - | Destination URL the ad links to. Required for chat_card ads; unused for product template ads (the URL comes from each feed item). |
image_url | string | No | - | Image for the ad creative. Accepts a Markifact file URL, a Google Drive share link, or a public image URL — it is downloaded and uploaded to OpenAI Ads automatically. chat_card ads need this or file_id; product template ads take images from the feed. |
file_id | string | No | - | An already-uploaded OpenAI Ads file_id to use for the creative instead of image_url (get one with openai_ads_upload_media). Only for chat_card ads. |
image_urls | array of string | No | - | 4 to 6 square (1:1) images for a multi-image chat_card ad, in display order, instead of image_url. The title, body and target_url apply to every image. Accepts direct URLs, Google Drive share links with sharing set to ‘Anyone with the link’, or files uploaded through Markifact. Requires an account enabled for ads with multiple images; cannot be combined with image_crop or price. |
file_ids | array of string | No | - | Already-uploaded OpenAI Ads file_ids for a multi-image ad instead of image_urls (from openai_ads_upload_media). When both are given, file_ids come first, then image_urls, 4 to 6 in total. |
image_crop | object or string | No | - | Optional crop region for the creative image, as JSON with “x”, “y”, “width”, and “height” given as fractions of the image dimensions (0-1), e.g. {“x”: 0, “y”: 0.1, “width”: 1, “height”: 0.8}. |
query_string_template | string | No | - | Optional landing-page query string template appended to the destination URL for tracking, e.g. ‘utm_source=chatgpt’. |