Understand the Baby Activity Skill API

The Alexa.Health API is a set of interfaces that allows you to build baby activity skills for your health and wellness apps and devices. Your customers can manage health and wellness data for themselves, their children, and other family members by talking to Alexa. Alexa interprets each customer utterance and communicates it to your skill as a request message with a JSON payload that contains an Alexa directive.

When you use the Alexa.Health interfaces, the voice interaction model is already built for you. The following examples show some customer utterances:

Alexa, track weight of twenty pounds.
Alexa, log a bottle feeding of six ounces for Jane.
Alexa, what is the baby’s weight?
Alexa, start sleep tracking.
Alexa, record sleep for three hours starting at two pm.
Alexa, how long did my baby sleep yesterday?
Alexa, log a formula feeding of three ounces at two pm.
Alexa, how much has my baby eaten today?
Alexa, record a dirty diaper at three pm.

You can't use the Alexa.Health API unless you already store customer data and identifiers yourself. Your customers create their user profiles in your app or website. Some apps and websites might allow a single customer to manage multiple profiles. For example, a customer that is a mother can manage a profile for herself and a profile for each of her children. For more information, see User Profiles.

Create a skill

To publish a skill in the Alexa skills store, you create a skill, create an AWS Lambda function to contain your skill code, test the skill, and submit the skill for certification. For baby activity skills, you must also configure account linking and profile reports. For more information, see Steps to Create a Baby Activity Skill.

Alexa.Health Interfaces

The following are the available Alexa.Health interfaces.

Alexa.Health.Weight
The Alexa.Health.Weight interface describes messages that you can use to develop Alexa skills for your weight tracking apps and devices. For more information, see Alexa.Health.Weight.
Alexa.Health.Sleep
The Alexa.Health.Sleep interface describes messages that you can use to develop Alexa skills for your sleep tracking apps and devices. For more information, see Alexa.Health.Sleep.
Alexa.Health.DiaperChange
The Alexa.Health.DiaperChange interface describes messages that you can use to develop Alexa skills for your apps and devices that track diaper changes. For more information, see Alexa.Health.DiaperChange.
Alexa.Health.InfantFeeding
The Alexa.Health.InfantFeeding interface describes messages that you can use to develop Alexa skills for your apps and devices that track infant feeding. For more information, see Alexa.Health.InfantFeeding.

Alexa.Health Directives

The Alexa.Health interfaces have the following types of directives:

Data management directives
The data management directives allow a customer to add data. The data management directives are optional if voice interaction is not required. For example, a smart device can add data without a customer utterance.
Timer directives
The timer directives allow a customer to time a session such as a sleep session or a feeding session. Your skill does not have to support the timer directives. If you skill supports one timer directive, it must support all timer directives.
Query directives
The query directives allow customers to ask questions about their data, and are always required. You can filter and sort the data based on the question that the customer asks. For more information, see Filtering and Sorting Query Results.

The following table shows the directives available for each interface.

Interface Data management directives Timer directives Query directives
Weight Add Get
Sleep Add Start, Pause, Resume, Cancel, Stop Get
DiaperChange Add Get
InfantFeeding Add Start, Switch, Pause, Resume, Cancel, Stop Get