Google Ads Transparency API
The Google Ads Transparency API lets you pull ad data from the Google Ads Transparency Center. You can look up ads by advertiser ID or keyword, and narrow results by platform, region, date range, or creative format.
Costs 5 API credits per request.
Endpoint:
https://api.scrapingdog.com/google/ads_transparencyAPI Parameters
·
Scrapingdog Parameters
api_keyRequiredYour Scrapingdog API key.
Type: StringhtmlOptionalSet totrueto receive the raw HTML of the page instead of parsed JSON.
Default:false
Type: Boolean
·
Search Query
advertiser_idOptionalThe unique ID assigned to a Google advertiser. You can find it in the Ads Transparency Center URL — for example, the ID inhttps://adstransparency.google.com/advertiser/AR17828074650563772417isAR17828074650563772417.
You can pass a single ID or a comma-separated list:AR17828074650563772417,AR03911981557522366465.
You can also use thetextparameter instead for keyword-based searches.
Type: String
·
Advanced Ads Transparency Parameters
textOptionalA keyword or domain to search within the Google Ads Transparency Center — works the same way as typing into the search bar. Use this as an alternative toadvertiser_id; when provided,advertiser_idis not required.
Type: StringplatformOptionalFilters results to a specific Google platform. Leave blank to get ads from all platforms.
Supported values:PLAY— Google PlayMAPS— Google MapsSEARCH— Google SearchSHOPPING— Google ShoppingYOUTUBE— YouTube
political_adsOptionalSet totrueto include only political advertisements. Political ads are tracked separately and are excluded from regular results by default. This parameter must be combined withregion.
Default:false
Type: Boolean
·
Geographic Location
regionOptionalLimits results to a specific geographic region. When omitted, results are returned globally. Use a numeric region code — e.g.,2840for the United States.
Type: String
·
Date Range
start_dateOptionalThe earliest date for which ads should be returned. Use the formatYYYYMMDD.
Example:20221201
Type: Stringend_dateOptionalThe latest date for which ads should be returned. Use the formatYYYYMMDD.
Example:20221231
To fetch ads for a single day, setend_dateto one day afterstart_date.
Type: String
·
Advanced Filters
creative_formatOptionalFilters ads by their creative type. Only ads matching the chosen format will appear in the response.
Supported values:text— Text adsimage— Image adsvideo— Video ads
·
Pagination
numOptionalMaximum number of ad results to return per request.
Default:40
Type: Integernext_page_tokenOptionalToken for fetching the next page of results. Obtain this value from the previous response to paginate through large result sets.
Type: String
API Examples
Code to Integrate
curl "https://api.scrapingdog.com/google/ads_transparency?api_key=APIKEY&text=apple.com®ion=2840"
import requests params = { "api_key": "APIKEY", "text": "apple.com", "region": "2840", } response = requests.get("https://api.scrapingdog.com/google/ads_transparency", params=params) print(response.json())
const axios = require("axios"); axios.get("https://api.scrapingdog.com/google/ads_transparency", { params: { api_key: "APIKEY", text: "apple.com", region: "2840", }, }).then(res => console.log(res.data));
<?php $params = http_build_query([ "api_key" => "APIKEY", "text" => "apple.com", "region" => "2840", ]); $response = file_get_contents("https://api.scrapingdog.com/google/ads_transparency?" . $params); echo $response;
require "net/http" require "uri" require "json" uri = URI("https://api.scrapingdog.com/google/ads_transparency") uri.query = URI.encode_www_form(api_key: "APIKEY", text: "apple.com", region: "2840") response = Net::HTTP.get(uri) puts JSON.parse(response)
import java.net.URI; import java.net.http.*; public class Main { public static void main(String[] args) throws Exception { String url = "https://api.scrapingdog.com/google/ads_transparency?api_key=APIKEY&text=apple.com®ion=2840"; HttpClient client = HttpClient.newHttpClient(); HttpRequest request = HttpRequest.newBuilder().uri(URI.create(url)).build(); HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString()); System.out.println(response.body()); } }
API Response
{
"search_information": {
"total_results": 40
},
"ad_creatives": [
{
"advertiser_id": "AR06318481179766947841",
"advertiser": "BELECONO HOLDINGS LIMITED",
"ad_creative_id": "CR14558968960457375745",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/16504679623469694927",
"total_days_shown": 112,
"first_shown": 1773471632,
"last_shown": 1783081992
},
{
"advertiser_id": "AR10059274394661814273",
"advertiser": "LeoStudio Global Limited",
"ad_creative_id": "CR14276108092289581057",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/2079378594330190699",
"total_days_shown": 360,
"first_shown": 1751883926,
"last_shown": 1783081845
},
{
"advertiser_id": "AR04153829757210853377",
"advertiser": "fun.music IT GmbH",
"ad_creative_id": "CR00042380967750402049",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/16986281515990051498",
"total_days_shown": 628,
"first_shown": 1728572773,
"last_shown": 1783081781
},
{
"advertiser_id": "AR02937520805967298561",
"advertiser": "Rosseca Society SL",
"ad_creative_id": "CR04609002076184248321",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/2438798437307971718",
"total_days_shown": 683,
"first_shown": 1724142286,
"last_shown": 1783081768
},
{
"advertiser_id": "AR15992851274060005377",
"advertiser": "Apple Inc.",
"ad_creative_id": "CR18383048617788178433",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/14685305779610735275",
"total_days_shown": 285,
"first_shown": 1758583084,
"last_shown": 1783081717
},
{
"advertiser_id": "AR15992851274060005377",
"advertiser": "Apple Inc.",
"ad_creative_id": "CR17046394322133450753",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/2042381579430867747",
"total_days_shown": 16,
"first_shown": 1781831118,
"last_shown": 1783081668
},
{
"advertiser_id": "AR15992851274060005377",
"advertiser": "Apple Inc.",
"ad_creative_id": "CR10062173798234324993",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/1317879710507483792",
"total_days_shown": 124,
"first_shown": 1772462245,
"last_shown": 1783081587
},
{
"advertiser_id": "AR00891030358995238913",
"advertiser": "BOTAN APP LIMITED",
"ad_creative_id": "CR17227204637044506625",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/2496006127706277667",
"total_days_shown": 814,
"first_shown": 1712530827,
"last_shown": 1783081561
},
{
"advertiser_id": "AR06737082092733071361",
"advertiser": "BRAINMOUNT LTD",
"ad_creative_id": "CR05261421317982257153",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/6585658968625420722",
"total_days_shown": 1288,
"first_shown": 1671920473,
"last_shown": 1783081421
},
{
"advertiser_id": "AR15992851274060005377",
"advertiser": "Apple Inc.",
"ad_creative_id": "CR01282548299114479617",
"format": "image",
"link": "https://tpc.googlesyndication.com/archive/simgad/12419773814932844519",
"total_days_shown": 68,
"first_shown": 1773797247,
"last_shown": 1783081382
}
],
"scrapingdog_pagination": {
"next_page_token": "CgoAP7zmqTAOXpvjEhDzhbW+ITDuYs3Y7OgAAAAAGgn8+HE7+DbQxAk="
}
}