Alexa Skill for evenly splitting chores
We have two kids, and both of them want to feed the dog in the evening. We used do it where one fed in the morning and one fed in the evening, but that had "issues". Let's just say mornings can be hectic. I wanted something to track who's turn it was.
The alexa voice interface works well for kids, mine are ages 7 and 9. I looked around for a skill, but really only found Whose Turn. This one turns up high in searches but the order is random? The developer must not have children. There are other skills that use timers and such for sharing an item evenly. But nothing for evenly splitting a daily chore. Time to make our own with blueprints and Google Apps Scripts!
Google Apps Scripts
The Flash Briefing blueprint consumes an RSS feed, so we need to create that first. The most reliable thing to do is to create your own. To do that, use Google Apps Scripts to:
- Create a new project. I called mine FairTurnRSS.
- Replace the default Code.js with this code.
- Click the Deploy button in the upper right and choose "New Deployment"
- In the new modal that pops up, click "Select type" and choose "Web App"
- In the "Who has access" selector, choose "Anyone"
- Click "Deploy"
- You'll need the Web App URL given, so copy it now.
Alternatively, you can use the one I already have with your custom URL arguments to get your skill up and working in under 5 minutes. My URL is:
https://script.google.com/macros/s/AKfycbzlooGEeaxy3IB6lUGN7EEPtRi4e48xOd4zk1jiCrCF82I5--CskCpUd2I2_TqQ9x5L9A/exec
You should test your deployment and determine your URL arguments. Curl will work if you're familiar (use -L) or you can use an online validator. If it looks good, now you need to add your arguments and determine the exact URL you'll be using for your blueprint in the next step. You can add the following GET arguments to your URL:
- option: The names of people that take turns doing the chore. Can specify this multiple times. Order is preserved, so if you need a different start selection, try changing the order. [multiple]
- title: The name of the chore. If not specified, will simply say "turn".[optional]
Continue testing the URL until the responses in the title and description fields of the response match what you want Alexa to say. For example, if you have three kids that take turns feeding the dog, you URL might look like:
https://URL?option=KidOne&option=KidTwo&option=KidThree&title=turn%20to%20feed%20the%20dog
Once you're happy with it, save the URL and move on to making your blueprint.
Blueprints
Blueprints are a sort of no-code solutions for making Alexa skills. I'd used blueprints a few times in the past to make custom skills for our VRBO property. Blueprints work by selecting a template of a skill and then filling in the blanks.
- Select the "Flash Briefing" template
- Select "Make your own"
- Specify a Feed Name. Something like "Who feeds the dog"
- Category doesn't matter, but I usually choose "Other"
- Choose an introductory message, note that it has to start with In or From. I chose "From your chores"
- Under content, choose "RSS", "Text", and put your URL from above into the field.
- Leave the update interval to "Daily"
- Hit "Next: Name" at the top of the page
- Change the name to something short, like "Feeds the dog"
- Click "Next: create skill"
That's it! Wait a few minutes and tell your alexa to "Play your daily briefing". You should hear your new skill output. Now just tell your kids about it.
You can customize your briefings in the Alexa app by going to Settings -> News -> Flash Briefing.