Skip to content

Instantly share code, notes, and snippets.

@nathanborror
Created July 18, 2015 20:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nathanborror/7979bc70ba7e449b1e9e to your computer and use it in GitHub Desktop.
Save nathanborror/7979bc70ba7e449b1e9e to your computer and use it in GitHub Desktop.
Alexa Skills Kit

Intents you define and upload to Amazon

{
  "intents": [
    {
      "intent": "GetVolume",
      "slots": [
        {
          "name": "Room",
          "type": "LITERAL"
        }
      ]
    },
    {
      "intent": "SetVolume",
      "slots": [
        {
          "name": "Room",
          "type": "LITERAL"
        },
        {
          "name": "Level",
          "type": "NUMBER"
        }
      ]
    }
  ]
}

Utterances you want Alex to listen for:

GetVolume what is the volume for the {kitchen|Room}
GetVolume {living room|Room} volume

SetVolume set the volume for the {bedroom|Room} to {ten|Level}
SetVolume set {bathroom|Room} volume to {five|Level}

Requests sent to a server of your choosing when Alex hears any of the utterances:

{
  "version":"1.0",
  "session":{
    "new":true,
    "sessionId":"amzn1.echo-api.session.XXXX",
    "application":{
      "applicationId":"amzn1.echo-sdk-ams.app.XXXX"
    },
    "user":{
      "userId":"amzn1.account.XXXX"
    }
  },
  "request":{
    "type":"IntentRequest",
    "requestId":"amzn1.echo-api.request.XXXX",
    "timestamp":"2015-07-18T19:54:53Z",
    "intent":{
      "name":"GetVolume",
      "slots":{
        "Room":{
          "name":"Room",
          "value":"kitchen"
        }
      }
    }
  }
}

Docs: https://developer.amazon.com/public/solutions/alexa/alexa-skills-kit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment