DEV Community

loading...
Cover image for Github actions triggering Alexa notifications

Github actions triggering Alexa notifications

Tony Diaz
🐊 Florida Gator alum. πŸ“š MBA. πŸ§‘πŸ»β€πŸ’»Engineer. πŸ‘πŸβ“‚οΈ IBMer
・2 min read

I've been interested in leveraging virtual assistant devices such as Alexa in my everyday routine. I've even documented working from home with Alexa during the pandemic. What a great way to stay up to date on your repo(s) than getting notified on Alexa when an event happens.

For anyone working out of GitHub, you could get informed of new pull requests or issues. Any of the Github action triggers could be used to activate a notification

My Workflow

The GitHub action is called Alexa Notification Github Action.

To make the connection to Alexa happen I'm using an existing Alexa skill called Notify me. This skill allows you to easily set up a REST API to send notifications with your Alexa device.

Setup NotifyMe

First, ask your Alexa device to Open Notify Me :

"Alexa, open notify me"

It will add the skill to your device. You will then need to link your Alexa account to the skill by using the Alexa app on your mobile device.

Alexa app

Once in the app, you will just need to sign-in to your Amazon account. Amazon will ask if you allow the skill access to your profile. It will just use your email to allow you to get an API key and secret later.

Notify me account is linked

Optionally you can edit the skill settings to turn on the green light notification on your device when the skill receives a message.

Notify me permissions

Login to https://www.getnotify.me/ to test a message on your Alexa device and get your API credentials. Once you have your key and secret go ahead and add those secrets to the repository you have set for your GitHub action.

Submission Category:

Interesting IoT

Yaml File or Link to Code

GitHub logo tonydiaz / amazon-alexa-notification-github-action

Get notifications on your Amazon Alexa device through GitHub actions

amazon-alexa-notification-github-action

Get notifications on your Amazon Alexa device through GitHub actions

Steps

1. Enable the NotifyMe skill on your Alexa App

Alexa, enable NotifyMe

Go to your Alexa app on your mobile device to link the skill with your account. This will allow the skill to tie the API credentials to your email account.

Optional: Turn on the notification indicator for this skill:

Steps:

2. Login to https://www.getnotify.me/ for credentials

Here you can send a test message to you Alexa device and generate credentials for to use with the API.

3. Setup you action on your repository

This action cab be triggered from any of the available events

Here is an example for an issue being opened:

on
  issues
    types: [opened]
jobs
  # This workflow contains a single job called "alexa-notify"
  alexa-notify:
    # The type of runner that the job will run on
    runs-on: 
…

GitHub action in action

I posted a video to show how the Github Action will work when a new issue is created. After the action executes Amazon Alexa will chime with the notification light. I can then ask Alexa to tell me the notification. The notification is set to tell me a new is was created with the issue number and title.

Additional Resources / Info

Using Notify me skill.

Discussion (4)

Collapse
qainsights profile image
NaveenKumar Namachivayam ⚑

I created similar GitHub action which will announce the GitHub releases :) github.com/QAInsights/Echo-The-Rel...

Collapse
rdlucas2 profile image
rdlucas2
Collapse
tonydiaz profile image
Tony Diaz Author

Very cool! It is using the same Notify me skill πŸ˜ƒ

Collapse
dsidev profile image
DSI Developer

This calls for a skill dedicated to GitHub notifications!