{
  "openapi": "3.0.1",
  "info": {
    "title": "Google Ads Transparency Scraper: Competitor Ads Library",
    "description": "See every ad a competitor runs on Google Search, YouTube and Display from the Google Ads Transparency Center: ad format, first and last shown dates, days running, image and preview links. Search by website domain, advertiser name or ID, filter by country.",
    "version": "0.2",
    "x-build-id": "DPYm6gKpqNmTsUd0U"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/redfoxscout~google-ads-transparency-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-redfoxscout-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/redfoxscout~google-ads-transparency-scraper/runs": {
      "post": {
        "operationId": "runs-sync-redfoxscout-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/redfoxscout~google-ads-transparency-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-redfoxscout-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": {
          "advertisers": {
            "title": "Advertisers",
            "type": "array",
            "description": "Website domains (nike.com), advertiser names (Shopify Inc.) or advertiser IDs (AR...), one per line.",
            "items": {
              "type": "string"
            }
          },
          "advertiserIds": {
            "title": "Advertiser IDs (optional)",
            "type": "array",
            "description": "Google advertiser IDs starting with AR, one per line. Same as putting them in Advertisers. Find one in an advertiser's Transparency Center page address.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Transparency Center links (optional)",
            "type": "array",
            "description": "Links copied from adstransparency.google.com: an advertiser page, an ad page (searches its advertiser) or a domain search. Other filters still come from the fields below.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "region": {
            "title": "Country",
            "enum": [
              "anywhere",
              "US",
              "GB",
              "CA",
              "AU",
              "DE",
              "FR",
              "ES",
              "IT",
              "NL",
              "AE",
              "SA",
              "IN",
              "BR",
              "MX",
              "JP"
            ],
            "type": "string",
            "description": "Only ads shown in this country. Default: anywhere.",
            "default": "anywhere"
          },
          "formats": {
            "title": "Ad formats",
            "type": "array",
            "description": "Leave empty for all formats.",
            "items": {
              "type": "string",
              "enum": [
                "text",
                "image",
                "video"
              ],
              "enumTitles": [
                "Text",
                "Image",
                "Video"
              ]
            }
          },
          "platforms": {
            "title": "Google surfaces",
            "type": "array",
            "description": "Only ads shown on these surfaces. Leave empty for all. Several surfaces run one after another.",
            "items": {
              "type": "string",
              "enum": [
                "search",
                "youtube",
                "shopping",
                "maps",
                "play"
              ],
              "enumTitles": [
                "Google Search",
                "YouTube",
                "Google Shopping",
                "Google Maps",
                "Google Play"
              ]
            }
          },
          "dateFrom": {
            "title": "Shown on or after",
            "type": "string",
            "description": "Keep ads that were shown on or after this date (YYYY-MM-DD). Empty: no start limit."
          },
          "dateTo": {
            "title": "Shown on or before",
            "type": "string",
            "description": "Keep ads that were first shown on or before this date (YYYY-MM-DD). Empty: no end limit."
          },
          "resultType": {
            "title": "Output",
            "enum": [
              "ads",
              "advertisers"
            ],
            "type": "string",
            "description": "Ads: one row per ad creative. Advertisers: one summary row per advertiser with its verification status, country and approximate ad count.",
            "default": "ads"
          },
          "allMatchingAdvertisers": {
            "title": "All advertisers with that name",
            "type": "boolean",
            "description": "For a name search, include every advertiser account with that exact name (e.g. one per country), not only the largest.",
            "default": false
          },
          "maxItems": {
            "title": "Max results per search",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Ads checked per search (the newest by last shown date come first). For advertiser rows: rows per search.",
            "default": 100
          },
          "includeDetails": {
            "title": "Add variations and countries",
            "type": "boolean",
            "description": "Also fetch each ad's A/B variations and the countries it ran in. One extra request per ad, so runs are slower.",
            "default": false
          },
          "onlyNewAds": {
            "title": "Only new ads since the last run",
            "type": "boolean",
            "description": "Competitor ad watch: output only ads not seen in earlier runs with the same monitor name. Needs a monitor name. Schedule the run to get new ads each day or week.",
            "default": false
          },
          "monitorName": {
            "title": "Monitor name",
            "type": "string",
            "description": "Name of this watch, e.g. \"Nike weekly\". Ads are remembered per name, so keep the name and filters the same across runs. Empty: nothing is remembered.",
            "default": ""
          },
          "maxConcurrency": {
            "title": "Searches in parallel",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "How many searches run at once.",
            "default": 3
          },
          "proxyConfiguration": {
            "title": "Proxy (optional)",
            "type": "object",
            "description": "Off by default. Turn on if Google starts blocking requests (HTTP 429).",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}