Skip to content
Simple SMTP-based email sending adapter for the Mozilla WebThings Gateway
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
doc
.eslintrc.js
.gitignore
CODE_OF_CONDUCT.md
LICENSE
README.md
email-sender-adapter.js
index.js
package-lock.json
package.json

README.md

email-sender-adapter

A simple adapter exposing actions to send emails through the Mozilla IoT Gateway.

Setup

First we need to get an app password from Google's account services to use with the email sender adapter. If you want to use a non-Google email account, skip ahead to the Installation and Configuration section and hope that your email server supports SMTP (or submit a pull request!).

To get an app password from Google, first click your profile icon on any google property to bring up the helpful Google Account link. Next, go to the Security section by clicking on it.

The profile icon dropdown with the Google Account and Security links highlighted

In the security section navigate to the App passwords list.

Google's security section

Now we can generate a new app password for the email sender adapter. Name it something you'll remember and click generate to get the app password that you should copy down for later.

Generate App password view

Installation and Configuration

Next, we install the email adapter from the addon list. On your gateway, go to the Settings section and click on Addons. Next, click the plus (+) button and scroll down to install the email adapter. With the adapter installed, we can click "Configure" to configure the adapter with our email address and app password from the Google account page. Gateway's addon list, highlighting the plus button Gateway's addon list, highlighting the email sender adapter's configure button Configuration screen for the email sender adapter

Finally, navigate to the main Things page and click the plus button to add the email sender thing. Image of the Email Thing's detail page

We can even drop the Email thing into rules to send basic notification emails to ourselves. Look for an upcoming update to the rules engine which will allow us to create even cooler behaviors in the future.

Image of a basic email-sending rule where a leak sensor is connected to email notification

You can’t perform that action at this time.