Public NodeJS Server used to retrive google trends data directly on client-side in order to avoid cors restrictions
using the google-trends-api package
Hosten on Heroku
- Recommended mainly for small projects
As of right now, the only avaliable endpoint is /average-word-search
I plan on adding different ones in the future as well as parameters for all of them
Returns the number of daily average searches for a word worldwide from 2016-01-01 until the present
https://google-trends-average.herokuapp.com/average-word-search/{word}
const word = "apple";
fetch("https://google-trends-average.herokuapp.com/average-word-search/" + word).then(response => {
return response.json();
}).then(data => {
console.log("Average searches for the word apple:" + data);
})
Average searches for the word apple: 44.12048192771084