{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Ads Transparency Scraper & Competitor Ad Monitor",
    "description": "Scrape Google Ads Transparency Center by brand name, domain or advertiser ID. Filter by country, platform (Search, YouTube, Shopping, Maps, Play), format and date. Find every advertiser linking to your domain and track new and stopped ads on a schedule.",
    "version": "0.1",
    "x-build-id": "tSf4hdxceh3MFniY5"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/egeusta~google-ads-transparency-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-egeusta-google-ads-transparency-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/egeusta~google-ads-transparency-scraper/runs": {
      "post": {
        "operationId": "runs-sync-egeusta-google-ads-transparency-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/egeusta~google-ads-transparency-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-egeusta-google-ads-transparency-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "queries": {
            "title": "Advertisers",
            "type": "array",
            "description": "Competitor domains (tesla.com), brand names (Nike), Transparency Center advertiser URLs or Advertiser IDs (AR...). Domains and names resolve to the matching advertiser with the most ads; use the ID for an exact match.",
            "default": [
              "AR17828074650563772417"
            ],
            "items": {
              "type": "string"
            }
          },
          "landingDomains": {
            "title": "Landing domains (every advertiser)",
            "type": "array",
            "description": "Find ads from ANY advertiser that link to these domains (for example nike.com) - the brand itself, its agencies, resellers and possible impostors. Each domain is capped by Max ads per advertiser.",
            "items": {
              "type": "string"
            }
          },
          "mode": {
            "title": "Mode",
            "enum": [
              "snapshot",
              "changes"
            ],
            "type": "string",
            "description": "Snapshot returns every ad currently found. Changes compares against your previous run for this state key and labels each ad new, stopped or continuing.",
            "default": "changes"
          },
          "regions": {
            "title": "Region",
            "type": "array",
            "description": "Country to search, as a two-letter ISO code (US, GB, DE, TR...), or 'anywhere' for all regions. Only the first entry is used. Each country keeps its own change history.",
            "default": [
              "anywhere"
            ],
            "items": {
              "type": "string"
            }
          },
          "platform": {
            "title": "Platform",
            "enum": [
              "any",
              "search",
              "youtube",
              "shopping",
              "maps",
              "play"
            ],
            "type": "string",
            "description": "Only ads shown on this Google platform.",
            "default": "any"
          },
          "adFormat": {
            "title": "Ad format",
            "enum": [
              "any",
              "text",
              "image",
              "video"
            ],
            "type": "string",
            "description": "Only ads of this format.",
            "default": "any"
          },
          "shownAfter": {
            "title": "Shown on or after",
            "type": "string",
            "description": "Only ads shown on or after this date (YYYY-MM-DD)."
          },
          "shownBefore": {
            "title": "Shown on or before",
            "type": "string",
            "description": "Only ads shown on or before this date (YYYY-MM-DD)."
          },
          "maxAdsPerAdvertiser": {
            "title": "Max ads per advertiser",
            "minimum": 1,
            "type": "integer",
            "description": "Cap on ads collected per advertiser. Advertisers that hit the cap are listed in truncatedAdvertisers in the run summary.",
            "default": 500
          },
          "activeWithinDays": {
            "title": "Active within (days)",
            "minimum": 1,
            "type": "integer",
            "description": "An ad whose last-shown date is older than this counts as stopped.",
            "default": 7
          },
          "stateKey": {
            "title": "State key",
            "type": "string",
            "description": "Namespace for change detection. Use one per tracked portfolio.",
            "default": "default"
          },
          "onlyChanges": {
            "title": "Only push changes",
            "type": "boolean",
            "description": "When Mode is Changes, push only new and stopped ads instead of every ad every run. Cuts daily monitoring output down to what actually moved. Ignored in Snapshot mode and on the first (baseline) run for each advertiser, since there is nothing yet to compare against.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Datacenter proxy is enough for this endpoint; residential is not required. If proxy setup fails the run continues without it.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}