passy / carbon-intensity-bot

A Google Home bot to enquire about your local electricity's carbon intensity.

Home Page:https://assistant.google.com/services/a/uid/00000075196ece08?hl=en-GB

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Carbon Intensity Build Status Greenkeeper badge

A Google Assistant Action to query your current local electricity carbon intensity.

View in the Google Assistant Directory.

Running locally

There's an odd limitation of the firebase-tools CLI that requires you to export your configuration locally first. Otherwise you'll get some nice untyped errors at runtime.

To do that first export your config:

firebase functions:config:get > functions/.runtimeconfig.json

Then run the local "emulator":

firebase serve --only functions

I like using ngrok to poke a tunnel into my NAT:

ngrok http 5000

Then point your Fulfilment link to your local endpoint which looks something like this: https://deadbeef.ngrok.io/carbon-intensity/us-central1/webhook

Deployment

cd functions
npm run deploy

About

A Google Home bot to enquire about your local electricity's carbon intensity.

https://assistant.google.com/services/a/uid/00000075196ece08?hl=en-GB


Languages

Language:TypeScript 86.6%Language:PureScript 6.6%Language:Dhall 5.4%Language:JavaScript 1.0%Language:Shell 0.4%