Core APIs
...
Google
Core Requests

Trends

4min
google trends parameters get get /search?engine=google\&search type=trends the google trends parameters are applicable when making a request with search type=trends to retrieve google's interest over time trend or interest by subregion trend results for a given search term the search term is specified in the q parameter the trend is specified with the data type parameter localizing google trends requests to localize trends requests you should use the trends geo request parameter for a list of all available trends geo values see the trends geo reference https //docs trajectdata com/serpwow/search api/reference/google trends geos multiple trends keywords you can request comparative trends results for up to 5 keywords in one request specify multiple trends keywords in comma seperated notation in the q parameter for example, to replicate the request shown in the screenshot below the q parameter would be q=pizza,burger,chips,sausages,bread to request trends results for the keyword pizza , worldwide (i e without a trends geo parameter), the request would be http https //api serpwow\ com/live/search?api key=demo\&search type=trends\&q=pizza\&data type=interest over timecurl l get https //api serpwow\ com/live/search \\ d api key="demo" \\ d q="pizza" \\ d search type="trends"\\ d data type="interest over time"const axios = require('axios'); // set up the request parameters const params = { api key "demo", q "pizza", search type "trends", data type "interest over time" } // make the http get request axios get('https //api serpwow\ com/live"/search', { params }) then(response => { // print the json response console log(json stringify(response data, 0, 2)); }) catch(error => { // catch and print the error console log(error); })import requests import json \# set up the request parameters params = { 'api key' 'demo', 'q' 'pizza', 'search type' 'trends', 'data type' 'interest over time' } \# make the http get request api result = requests get('https //api serpwow\ com/live/search', params) \# print the json response print(json dumps(api result json()))\<?php \# set up the request parameters $querystring = http build query(\[ 'api key' => 'demo', 'q' => 'pizza', 'search type' => 'trends', 'data type' => 'interest over time' ]); \# make the http get request $ch = curl init(sprintf('%s?%s', 'https //api serpwow\ com/live/search', $querystring)); curl setopt($ch, curlopt returntransfer, true); curl setopt($ch, curlopt followlocation, true); \# the following options are required if you're using an outdated openssl version \# more details https //www openssl org/blog/blog/2021/09/13/letsencryptrootcertexpire/ curl setopt($ch, curlopt ssl verifyhost, false); curl setopt($ch, curlopt ssl verifypeer, false); curl setopt($ch, curlopt timeout, 180); $api result = curl exec($ch); curl close($ch); \# print the json response echo $api result; ?> google trends parameters the following parameters are available for all requests made when search type=trends parameter required description engine required should be set to engine=google search type required should be set to search type=trends q required the keyword you want to use to perform the trends search you can request up to 5 trends keywords to compare in one request to specify multiple keywords, seperate each with a comma i e q=dog,cat data type required the type of trend you want results for, interest over time or the interest by subregion set data type to data type=interest over time or data type=interest by subregion gl optional the gl parameter determines the google country to use for the query view the full list of supported gl values here https //docs trajectdata com/serpwow/search api/reference/google countries defaults to us hl optional the hl parameter determines the google ui language to return results view the full list of supported hl values here https //docs trajectdata com/serpwow/search api/reference/google languages defaults to en time period optional determines the time period of the results shown it can be set to last hour , last day (for the last 24 hours), last week (for the last 7 days), last month , last year or custom when using custom you must also specifiy one or both of the time period min or time period max parameters to define the custom time period time period min optional determines the minimum (i e 'from') time to use when time period is set to custom should be in the form mm/dd/yyyy , i e for 31st december 2018 time period min would be 12/31/2018 time period max optional determines the maximum (i e 'to') time to use when time period is set to custom should be in the form mm/dd/yyyy , i e for 31st december 2018 time period max would be 12/31/2018 trends type optional determines the google property to search for trends data valid values are web , images , news , youtube or shopping trends resolution optional determines the resolution requested for the trends interest by subregion section of serpwow's google trends results valid values are country , city , dma or region trends geo optional a google trends geo id typically a 2 letter country code, for example trends geo=de for trends data for germany can also specify a more specific trends geo for a specific location within a country view the full list of supported trends geo values here https //docs trajectdata com/serpwow/search api/reference/google trends geos omit the trends geo parameter entirely if you wish to run your query as "worldwide" trends category optional a google trends category id view the full list of supported trends category values here https //docs trajectdata com/serpwow/search api/reference/google trends categories next steps google trends results https //docs trajectdata com/serpwow/search api/results/google/trends