Call it
curl https://api.peume.com/v1/call/google-ads-traffic-forecast-for-keywords-and-bid \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"keywords": [
"seo marketing"
],
"bid": 999,
"match": "exact",
"location_code": 2840,
"language_code": "en"
}
}'const res = await fetch("https://api.peume.com/v1/call/google-ads-traffic-forecast-for-keywords-and-bid", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"keywords": [
"seo marketing"
],
"bid": 999,
"match": "exact",
"location_code": 2840,
"language_code": "en"
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/google-ads-traffic-forecast-for-keywords-and-bid",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"keywords": [
"seo marketing"
],
"bid": 999,
"match": "exact",
"location_code": 2840,
"language_code": "en"
}
},
)
print(res.json()["output"])Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: google-ads-traffic-forecast-for-keywords-and-bid.
Parameters
keywordsarraykeywords required field The maximum number of keywords you can specify: 1000 The maximum number of characters for each keyword: 80 The maximum number of words for each keyword phrase: 10 the keywords you specify will be converted to a lowercase format Note: Google Ads may return no data for certain
Example: ["seo marketing"]
bidnumberthe maximum custom bid required field the collected data will be based on this value it stands for the price you are willing to pay for an ad; the higher value you specify here, the higher values you will get in the returned metrics learn more in this help center article
Example: 999
matchstringkeywords match-type required field can take the following values: exact, broad, phrase
Example: exact
location_namestringfull name of search engine location optional field if you do not indicate the location, you will receive worldwide results, i.e., for all available locations; if you use this field, you don’t need to specify location_code or location_coordinate you can receive the list of available locations of the
location_codeintegersearch engine location code optional field if you do not indicate the location, you will receive worldwide results, i.e., for all available locations; if you use this field, you don’t need to specify location_name or location_coordinate; you can receive the list of available locations of the search
Example: 2840
location_coordinatestringGPS coordinates of a location optional field if you do not indicate the location, you will receive worldwide results, i.e., for all available locations; if you use this field, you don’t need to specify location_name or location_code; location_coordinate parameter should be specified in the “latitude
language_namestringfull name of search engine language optional field you can receive the list of available languages of the search engine with their language_name by making a separate request to example: English
language_codestringsearch engine language code optional field you can receive the list of available languages of the search engine with their language_code by making a separate request to example: en
Example: en
date_fromstringstarting date of the forecasting time range required field if you specify date_to if you indicate date_from and date_to, you don’t need to specify date_interval minimum value is tomorrow’s date the value you specify in date_from shouldn’t be further than date_to date format: "yyyy-mm-dd" example: "2
date_tostringending date of the forecasting time range required field if you specify date_from if you indicate date_from and date_to, you don’t need to specify date_interval minimum value is date_from +1 day maximum value is current day and month of the next year date format: "yyyy-mm-dd" example: "2022-10-30"
date_intervalstringforecasting date interval optional field if you specify date_interval, you don’t need to indicate date_from and date_to possible values: next_week, next_month, next_quarter default value: next_month
sort_bystringresults sorting parameters optional field Use these parameters to sort the results by relevance, impressions, ctr, average_cpc, cost, or clicks in the descending order default value: relevance
tagstringuser-defined task identifier optional field the character limit is 255 you can use this parameter to identify the task and match it with the result you will find the specified tag value in the data object of the response
