chuckreynolds / GoogleTrendsToSheets

This is useful to push Google Trends to Google Sheets. From there it can be used to push it for example to Slack.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This is useful to push Google Trends to Google Sheets. From there it can be used to push it for example to Slack using ifttt.

Example sheet

https://docs.google.com/spreadsheets/d/1GXd44Uvzu8rROpFIpFemk-ZpIP1o4qZMLgP2OM2s_F4/edit?usp=sharing

Using Google Cloud functions + Google Cloud Scheduler to run it every 15 minutes

Tools used

Setup

In Google Cloud Platform:

You need a project with:

  • Google Sheets API
  • Google Cloud Functions
  • Google Scheduler API

Create a service account json and download it

In Google Sheets

  • Add the service accounts email with edit permission to a new created Google Spreadsheet
  • Add the sheet id to .env.yaml and/or the local test file. You don't need to go with an .env.yaml in any case
  • Add Sheets e.g. DE, US, CH

Test in terminal

Download service account users json and test:

  • export GOOGLE_APPLICATION_CREDENTIALS="/Users/wio/Documents/GoogleTrendsToSheets/yourServiceAccountsJson.json"
  • node local_index.js

Deploy a Cloud Function

Login Google Cloud + Deploy:

About

This is useful to push Google Trends to Google Sheets. From there it can be used to push it for example to Slack.


Languages

Language:JavaScript 100.0%