For example, I would like the user to be able to set their home location as a 6 digit number. Then they can just ask my skill for an update, "when's the next bus coming", rather than having to say, "when's the next bus coming to location 123456".
Asked
Active
Viewed 912 times
2
1 Answers
2
You can persist information using either a database or by passing information along in the session object. There are lots of examples and information about using DynamoDB, such as this Alexa cookbook example.
The session object allows passing data along from each intent to the next, but only persists for the life of the session. The Amazon documentation contains the information about session, but the specifics will depend on the language you are using (eg. Java or NodeJS)

Ron Lisle
- 1,164
- 6
- 11
-
Is there a unique id associated with an Alexa user that I can just use? – higgs241 Jul 06 '17 at 17:57
-
There sure is. It is event.session.user.userId. It won't allow you to access any information about the user, but it will be unique for each user. Refer to the Amazon doc or search on that term for more details. – Ron Lisle Jul 06 '17 at 19:41