Lists what people searched for before seeing a Google Ads account’s search ads, with the keyword that matched, match type and clicks, cost and conversions for a date range.
curl -X POST "https://api.primaryapi.com/v1/run/google-ads.search_terms" \
-H "Authorization: Bearer $PRIMARYAPI_API_KEY" \
-H "Content-Type: application/json" \
-d '{"customerId":"1234567890"}'{
"output": {
"found": true,
"data": {
"currencyCode": "USD",
"period": "DURING LAST_30_DAYS",
"nextCursor": null,
"searchTerms": [
{
"searchTerm": "example store online",
"status": "NONE",
"matchType": "PHRASE",
"keyword": { … }, …
}
], …
}
},
"credits": 1
}Input and output
10 fields
1234567890.customerId THROUGH a manager (MCC) account: that manager account’s id (10 digits). Sent as the login-customer-id header. Omit for accounts the Google account can open directly.5 fields
Good to know
Runs as your connected Google account. Needs the Google Ads capability.
One row per search term, ad group, matching keyword and match type. Performance Max searches are not included.
Amounts are in the account currency.
Sorted by cost, highest first.
Narrow with campaignId or adGroupId.
Unknown customer ID? It comes back as not found, not as an error.
The same key and credits work for every API.