fs-persistence-adapter
v0.1.3
Published
An implementation of the Alexa Persistence Adapter using the file system
Downloads
4
Maintainers
Readme
What is Alexa
Alexa is Amazon’s cloud-based voice service (...). You can build natural voice experiences that offer customers a more intuitive way to interact with the technology they use every day (...).
What is a Skill
In this context, a Skill
is the name assigned to an application designed to enhance Alexa's functionalities.
Learn more about Skills on Alexa Skills Kit.
File System Persistence Adapter
The File System Persistence Adapter implements the ASK Core interface with the same name and provides a bridge between the FileSystem node.js library and the Alexa Persistence Attributes.
Install
When you creating your skill, just import fs-persistence-adapter
into your package.json
, or alternatively run:
npm i fs-persistence-adapter
and import into your project using one of two options bellow:
const { FileSystemPersistenceAdapter } = require('fs-persistence-adapter');
...Alexa.SkillBuilders.custom().withPersistenceAdapter(
new FileSystemPersistenceAdapter('path/to/file') // to save all attributes of all users in a single file
/* OR */
new FileSystemPersistenceAdapter('path/') // to save attributes in files separated by user id
)
NOTE: The path needs to already exists, only the files are created.
Author
- Created and maintained by Emerson C. Romaneli (@ECRomaneli).