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

Submit Partner Eligibility Job

POST
/sandbox/ad_eligibility_jobs

Submit independent synthetic prompts for current campaign eligibility observations.

Submit Partner Eligibility Job

curl https://api.ads.openai.com/v1/sandbox/ad_eligibility_jobs \
    -H 'Content-Type: application/json' \
    -H "Authorization: Bearer $OPENAI_ADS_ACCESS_TOKEN" \
    -d '{
          "ad_account_id": "ad_account_id",
          "association_id": "x",
          "campaign_id": "campaign_id",
          "consent_revision": 1,
          "enrollment_generation": 1,
          "evaluation_context": {
            "country_code": "x",
            "locale": "x",
            "region_code": "x"
          },
          "queries": [
            {
              "prompt": "x",
              "query_id": "x"
            }
          ],
          "schema_version": "1.0"
        }'
202 — Example
{
  "ad_account_id": "ad_account_id",
  "association_id": "association_id",
  "batch_id": "batch_id",
  "campaign_id": "campaign_id",
  "cancelled_count": 0,
  "completed_count": 0,
  "execution_deadline": "execution_deadline",
  "expired_count": 0,
  "failed_count": 0,
  "result_expires_at": "result_expires_at",
  "results_available": true,
  "retry_after_seconds": 0,
  "schema_version": "1.0",
  "status": "preparing",
  "total_count": 0
}
Header Parameters
"Idempotency-Key": string
pattern.*\S.*
minLength1
maxLength128
Body Parameters
JSON
ad_account_id: string
association_id: string
minLength1
maxLength256
campaign_id: string
enrollment_generation: integer
minimum1
evaluation_context: object { country_code, locale, region_code }
country_code: string
minLength1
maxLength8
locale: string
minLength1
maxLength32
region_code: string
minLength1
maxLength64
queries: array of object { prompt, query_id }
minItems1
maxItems1000
prompt: string
minLength1
maxLength65536
query_id: string
minLength1
maxLength128
schema_version: "1.0" (default: "1.0")
Returns
ad_account_id: string
association_id: string
batch_id: string
campaign_id: string
cancelled_count: integer
completed_count: integer
execution_deadline: string
expired_count: integer
failed_count: integer
result_expires_at: string
results_available: boolean
retry_after_seconds: integer
schema_version: "1.0" (default: "1.0")
status: "preparing" or "pending" or "running" or 6 more
One of the following:
"preparing"
"pending"
"running"
"cancelling"
"completed"
"partially_failed"
"failed"
"cancelled"
"expired"
total_count: integer
Returns Examples
202 — Example
{
  "ad_account_id": "ad_account_id",
  "association_id": "association_id",
  "batch_id": "batch_id",
  "campaign_id": "campaign_id",
  "cancelled_count": 0,
  "completed_count": 0,
  "execution_deadline": "execution_deadline",
  "expired_count": 0,
  "failed_count": 0,
  "result_expires_at": "result_expires_at",
  "results_available": true,
  "retry_after_seconds": 0,
  "schema_version": "1.0",
  "status": "preparing",
  "total_count": 0
}