alexa-actions

1.2.2 • Public • Published

Alexa Actions

This is a npm module which adds support for API.ai on the Alexa-SDK to support e.g. Actions on Google.

Usage

The simple way:
Just replace require('alexa-sdk') by require('alexa-actions').

The more advanced usage if something does not work for you:

const AlexaActions = require('alexa-actions');
// [...]
exports.handler = (event, context) => {
    const alexa = Alexa.handler(AlexaActions.toAlexaStyle(event),
                                AlexaActions.addApiAiAttributes(context));
    alexa.app_id = APP_ID;
    alexa.resources = languageStrings;
    alexa.registerHandlers(handlers);
    alexa.execute();
};

The Intents on API.ai have to be the same as in your Alexa Skill, the parameters of your intent API.ai have to be named equal to the slots in your skill.

Examples

Real world examples on Google Home:

  • "Okay Google, ask Dependency Lookup where is the class AdView?""

License

Apache 2.0

Package Sidebar

Install

npm i alexa-actions

Weekly Downloads

3

Version

1.2.2

License

Apache-2.0

Last publish

Collaborators

  • rekire