npm.io
1.3.2 • Published 10 years ago

alexa-express

Licence
MIT
Version
1.3.2
Deps
2
Vulns
0
Weekly
0
Stars
1

alexa-express

Create Amazon Alexa apps with expressjs-like middleware.

Installation

Install with npm

npm install alexa-express

Example

Create app
app = new require("alexa-express")()
module.exports = app.handler
Handle LaunchRequest
app.use "/launch", ( req, res, next ) ->
  res.tell "Welcome!"
Built-in Intents
# AMAZON.HelpIntent
app.use "/intent/amazon/help", ( req, res, next ) ->
  res.ask "How can I help you today?"
Custom Intents
# StartGameIntent
app.use "/intent/startGame", ( req, res, next ) ->
  res.ask "What do you want to play?"