{
  "description": "Scrape YouTube ads from Google's Ads Transparency Center. Search by advertiser, keyword, or country, and export the results.",
  "properties": {
    "advertisers": {
      "description": "Advertiser names or AR-IDs to scrape YouTube ads for (e.g. 'Nike, Inc.', 'AR16735076323512287233'). Leave empty to use searchTerms.",
      "editor": "stringList",
      "example": [
        "Nike, Inc.",
        "Samsung Electronics America"
      ],
      "items": {
        "type": "string"
      },
      "title": "Advertisers",
      "type": "array"
    },
    "countries": {
      "description": "Country codes to filter ads by (ISO 3166-1 alpha-2).",
      "editor": "select",
      "items": {
        "enum": [
          "AD",
          "AE",
          "AG",
          "AI",
          "AL",
          "AM",
          "AO",
          "AQ",
          "AR",
          "AS",
          "AT",
          "AU",
          "AW",
          "AZ",
          "BA",
          "BB",
          "BD",
          "BE",
          "BF",
          "BG",
          "BH",
          "BI",
          "BJ",
          "BM",
          "BN",
          "BO",
          "BQ",
          "BR",
          "BS",
          "BT",
          "BV",
          "BW",
          "BY",
          "BZ",
          "CA",
          "CC",
          "CD",
          "CF",
          "CG",
          "CH",
          "CI",
          "CK",
          "CL",
          "CM",
          "CN",
          "CO",
          "CR",
          "CV",
          "CW",
          "CX",
          "CY",
          "CZ",
          "DE",
          "DJ",
          "DK",
          "DM",
          "DO",
          "DZ",
          "EC",
          "EE",
          "EG",
          "EH",
          "ER",
          "ES",
          "ET",
          "FI",
          "FJ",
          "FK",
          "FM",
          "FO",
          "FR",
          "GA",
          "GB",
          "GD",
          "GE",
          "GF",
          "GG",
          "GH",
          "GI",
          "GL",
          "GM",
          "GN",
          "GP",
          "GQ",
          "GR",
          "GS",
          "GT",
          "GU",
          "GW",
          "GY",
          "HK",
          "HM",
          "HN",
          "HR",
          "HT",
          "HU",
          "ID",
          "IE",
          "IL",
          "IM",
          "IN",
          "IO",
          "IQ",
          "IS",
          "IT",
          "JE",
          "JM",
          "JO",
          "JP",
          "KE",
          "KG",
          "KH",
          "KI",
          "KM",
          "KN",
          "KR",
          "KW",
          "KY",
          "KZ",
          "LA",
          "LB",
          "LC",
          "LI",
          "LK",
          "LR",
          "LS",
          "LT",
          "LU",
          "LV",
          "LY",
          "MA",
          "MC",
          "MD",
          "ME",
          "MG",
          "MH",
          "MK",
          "ML",
          "MM",
          "MN",
          "MO",
          "MP",
          "MQ",
          "MR",
          "MS",
          "MT",
          "MU",
          "MV",
          "MW",
          "MX",
          "MY",
          "MZ",
          "NA",
          "NC",
          "NE",
          "NF",
          "NG",
          "NI",
          "NL",
          "NO",
          "NP",
          "NR",
          "NU",
          "NZ",
          "OM",
          "PA",
          "PE",
          "PF",
          "PG",
          "PH",
          "PK",
          "PL",
          "PM",
          "PN",
          "PR",
          "PS",
          "PT",
          "PW",
          "PY",
          "QA",
          "RE",
          "RO",
          "RW",
          "SA",
          "SB",
          "SC",
          "SE",
          "SG",
          "SH",
          "SI",
          "SJ",
          "SK",
          "SL",
          "SM",
          "SN",
          "SO",
          "SR",
          "ST",
          "SV",
          "SX",
          "SZ",
          "TC",
          "TD",
          "TF",
          "TG",
          "TH",
          "TJ",
          "TK",
          "TL",
          "TM",
          "TN",
          "TO",
          "TR",
          "TT",
          "TV",
          "TW",
          "TZ",
          "UA",
          "UG",
          "UM",
          "US",
          "UY",
          "UZ",
          "VA",
          "VC",
          "VE",
          "VG",
          "VI",
          "VN",
          "VU",
          "WF",
          "WS",
          "YE",
          "YT",
          "ZA",
          "ZM",
          "ZW"
        ],
        "enumTitles": [
          "Andorra",
          "United Arab Emirates",
          "Antigua and Barbuda",
          "Anguilla",
          "Albania",
          "Armenia",
          "Angola",
          "Antarctica",
          "Argentina",
          "American Samoa",
          "Austria",
          "Australia",
          "Aruba",
          "Azerbaijan",
          "Bosnia and Herzegovina",
          "Barbados",
          "Bangladesh",
          "Belgium",
          "Burkina Faso",
          "Bulgaria",
          "Bahrain",
          "Burundi",
          "Benin",
          "Bermuda",
          "Brunei Darussalam",
          "Bolivia, Plurinational State of",
          "Bonaire, Sint Eustatius and Saba",
          "Brazil",
          "Bahamas",
          "Bhutan",
          "Bouvet Island",
          "Botswana",
          "Belarus",
          "Belize",
          "Canada",
          "Cocos (Keeling) Islands",
          "Congo, The Democratic Republic of the",
          "Central African Republic",
          "Congo",
          "Switzerland",
          "Côte d'Ivoire",
          "Cook Islands",
          "Chile",
          "Cameroon",
          "China",
          "Colombia",
          "Costa Rica",
          "Cabo Verde",
          "Curaçao",
          "Christmas Island",
          "Cyprus",
          "Czechia",
          "Germany",
          "Djibouti",
          "Denmark",
          "Dominica",
          "Dominican Republic",
          "Algeria",
          "Ecuador",
          "Estonia",
          "Egypt",
          "Western Sahara",
          "Eritrea",
          "Spain",
          "Ethiopia",
          "Finland",
          "Fiji",
          "Falkland Islands (Malvinas)",
          "Micronesia, Federated States of",
          "Faroe Islands",
          "France",
          "Gabon",
          "United Kingdom",
          "Grenada",
          "Georgia",
          "French Guiana",
          "Guernsey",
          "Ghana",
          "Gibraltar",
          "Greenland",
          "Gambia",
          "Guinea",
          "Guadeloupe",
          "Equatorial Guinea",
          "Greece",
          "South Georgia and the South Sandwich Islands",
          "Guatemala",
          "Guam",
          "Guinea-Bissau",
          "Guyana",
          "Hong Kong",
          "Heard Island and McDonald Islands",
          "Honduras",
          "Croatia",
          "Haiti",
          "Hungary",
          "Indonesia",
          "Ireland",
          "Israel",
          "Isle of Man",
          "India",
          "British Indian Ocean Territory",
          "Iraq",
          "Iceland",
          "Italy",
          "Jersey",
          "Jamaica",
          "Jordan",
          "Japan",
          "Kenya",
          "Kyrgyzstan",
          "Cambodia",
          "Kiribati",
          "Comoros",
          "Saint Kitts and Nevis",
          "Korea, Republic of",
          "Kuwait",
          "Cayman Islands",
          "Kazakhstan",
          "Lao People's Democratic Republic",
          "Lebanon",
          "Saint Lucia",
          "Liechtenstein",
          "Sri Lanka",
          "Liberia",
          "Lesotho",
          "Lithuania",
          "Luxembourg",
          "Latvia",
          "Libya",
          "Morocco",
          "Monaco",
          "Moldova, Republic of",
          "Montenegro",
          "Madagascar",
          "Marshall Islands",
          "North Macedonia",
          "Mali",
          "Myanmar",
          "Mongolia",
          "Macao",
          "Northern Mariana Islands",
          "Martinique",
          "Mauritania",
          "Montserrat",
          "Malta",
          "Mauritius",
          "Maldives",
          "Malawi",
          "Mexico",
          "Malaysia",
          "Mozambique",
          "Namibia",
          "New Caledonia",
          "Niger",
          "Norfolk Island",
          "Nigeria",
          "Nicaragua",
          "Netherlands",
          "Norway",
          "Nepal",
          "Nauru",
          "Niue",
          "New Zealand",
          "Oman",
          "Panama",
          "Peru",
          "French Polynesia",
          "Papua New Guinea",
          "Philippines",
          "Pakistan",
          "Poland",
          "Saint Pierre and Miquelon",
          "Pitcairn",
          "Puerto Rico",
          "Palestine, State of",
          "Portugal",
          "Palau",
          "Paraguay",
          "Qatar",
          "Réunion",
          "Romania",
          "Rwanda",
          "Saudi Arabia",
          "Solomon Islands",
          "Seychelles",
          "Sweden",
          "Singapore",
          "Saint Helena, Ascension and Tristan da Cunha",
          "Slovenia",
          "Svalbard and Jan Mayen",
          "Slovakia",
          "Sierra Leone",
          "San Marino",
          "Senegal",
          "Somalia",
          "Suriname",
          "Sao Tome and Principe",
          "El Salvador",
          "Sint Maarten (Dutch part)",
          "Eswatini",
          "Turks and Caicos Islands",
          "Chad",
          "French Southern Territories",
          "Togo",
          "Thailand",
          "Tajikistan",
          "Tokelau",
          "Timor-Leste",
          "Turkmenistan",
          "Tunisia",
          "Tonga",
          "Türkiye",
          "Trinidad and Tobago",
          "Tuvalu",
          "Taiwan, Province of China",
          "Tanzania, United Republic of",
          "Ukraine",
          "Uganda",
          "United States Minor Outlying Islands",
          "United States",
          "Uruguay",
          "Uzbekistan",
          "Holy See (Vatican City State)",
          "Saint Vincent and the Grenadines",
          "Venezuela, Bolivarian Republic of",
          "Virgin Islands, British",
          "Virgin Islands, U.S.",
          "Viet Nam",
          "Vanuatu",
          "Wallis and Futuna",
          "Samoa",
          "Yemen",
          "Mayotte",
          "South Africa",
          "Zambia",
          "Zimbabwe"
        ],
        "type": "string"
      },
      "prefill": [
        "US"
      ],
      "title": "Countries",
      "type": "array"
    },
    "dateFrom": {
      "description": "Only return ads first shown on or after this date (YYYY-MM-DD).",
      "editor": "datepicker",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "title": "First shown on/after (YYYY-MM-DD)",
      "type": "string"
    },
    "dateTo": {
      "description": "Only return ads last shown on or before this date (YYYY-MM-DD).",
      "editor": "datepicker",
      "pattern": "^\\d{4}-\\d{2}-\\d{2}$",
      "title": "First shown on/before (YYYY-MM-DD)",
      "type": "string"
    },
    "includeVideoDetails": {
      "default": false,
      "description": "Fetch the ad detail page for each ad to resolve the video URL and format (slower, but gives the actual video asset for video ads).",
      "prefill": false,
      "title": "Include video details",
      "type": "boolean"
    },
    "maxAdvertisersPerTerm": {
      "default": 5,
      "description": "Maximum advertisers to scrape per keyword (when searchTerms is used).",
      "maximum": 50,
      "minimum": 1,
      "prefill": 5,
      "title": "Max advertisers per search term",
      "type": "integer"
    },
    "maxConcurrency": {
      "default": 2,
      "description": "Advertisers scraped in parallel. Higher is faster but increases rate-limit risk.",
      "maximum": 5,
      "minimum": 1,
      "prefill": 2,
      "title": "Max concurrency",
      "type": "integer"
    },
    "maxItems": {
      "default": 100,
      "description": "Hard cap on total ad records returned (1-5000).",
      "maximum": 5000,
      "minimum": 1,
      "prefill": 50,
      "title": "Max items",
      "type": "integer"
    },
    "outputFormat": {
      "default": "json",
      "description": "Dataset always receives JSON records. Additionally export results as CSV, Excel, or HTML in the key-value store (OUTPUT.csv / OUTPUT.xlsx / OUTPUT.html).",
      "editor": "select",
      "enum": [
        "json",
        "csv",
        "excel",
        "html"
      ],
      "enumTitles": [
        "JSON (dataset only)",
        "CSV (OUTPUT.csv)",
        "Excel (OUTPUT.xlsx)",
        "HTML (OUTPUT.html)"
      ],
      "prefill": "json",
      "title": "Output format",
      "type": "string"
    },
    "proxyConfiguration": {
      "description": "Optional proxy. For moderate traffic no proxy is needed. Enable Apify proxy for high-volume scraping.",
      "editor": "proxy",
      "title": "Proxy Configuration",
      "type": "object"
    },
    "searchTerms": {
      "description": "Keywords or domain names to discover advertisers, then scrape their YouTube ads (e.g. 'electric car', 'nike.com').",
      "editor": "stringList",
      "items": {
        "type": "string"
      },
      "prefill": [
        "electric car"
      ],
      "title": "Search Terms (keywords)",
      "type": "array"
    }
  },
  "schemaVersion": 1,
  "title": "YouTube Ads Scraper Input",
  "type": "object"
}
