3.11.0 • Published 4 years ago
ask-utils v3.11.0
ASK-Utils - Utility functions for ask-sdk
Getting started
$ npm i -S ask-utils
Packages
Skill Builder (Beta)
We can easy to create your own skill builder
import {
createSkill,
SkillHandlersFactory
} from 'ask-utils'
// can get skill constancts by request attributes
const ExampleHandler = {
canHandle: () => true,
handle: handlerInput => {
const { CONSTANTS } = handlerInput.attributesManager.getRequestAttributes()
return handlerInput.responseBuilder
.speak(`Welcome to the ${CONSTANTS.SKILL_NAME}!`)
.getResponse()
}
}
const handlers = SkillHandlersFactory.create()
.addRequestHandlers(
LaunchRequest,
NextIntent,
AnswerIntent,
YesNextIntent,
HelpIntent,
ResumeIntent,
StopIntent,
NoIntent,
CancelIntent,
FallBackIntent
)
.addRequestInterceptors(
MyRequestInterceptor1,
MyRequestInterceptor2,
)
.addResponseInterceptors(
MyResponseInterceptor1,
MyResponseInterceptor2,
)
.addErrorHandlers(
MyErrorHandler1,
MyErrorHandler2,
)
export const handler = createSkill({
persistanceType: 'S3',
bucketName: process.env.BUCKET_NAME as string,
bucketPathPrefix: process.env.PATH_PREFIX as string,
isISP: true,
constants: {
SKILL_NAME: 'My Awesome Skill'
}
}, handlers.getHandlers())
.lambda()
development
$ git clone git@github.com:hideokamoto/ask-utils.git
$ cd ask-utils
$ yarn
$ yarn bootstrap
test
$ npm test
Lint
$ npm run lint
or
$ npm run lint -- --fix
History
-> Release Note
Contributors
Name | Version |
---|---|
@ArtskydJ | v0.13.0 |
3.11.0
4 years ago
3.9.0
4 years ago
3.8.0
4 years ago
3.6.0
4 years ago
3.5.0
4 years ago
3.4.0
4 years ago
3.3.5
4 years ago
3.3.4
4 years ago
3.3.3
4 years ago
3.3.2
4 years ago
3.3.1
4 years ago
3.3.0
4 years ago
3.2.2
5 years ago
3.2.1
5 years ago
3.2.0
5 years ago
3.1.4
5 years ago
3.1.3
5 years ago
3.1.2
5 years ago
3.1.1
5 years ago
3.0.8
5 years ago
2.3.2
5 years ago
2.3.1
5 years ago
2.3.0
5 years ago
2.2.0
5 years ago
2.1.0
5 years ago
2.0.0
5 years ago
1.6.0
5 years ago
1.5.1
5 years ago
1.5.0
5 years ago
1.4.1
5 years ago
1.4.0
5 years ago
1.3.0
5 years ago
1.2.0
5 years ago
1.1.3
5 years ago
1.1.2
5 years ago
1.1.1
5 years ago
1.1.0
5 years ago
1.0.1
5 years ago
1.0.0
5 years ago
0.15.0
5 years ago
0.14.0
5 years ago
0.13.0
5 years ago
0.12.5
5 years ago
0.12.4
6 years ago
0.12.3
6 years ago
0.12.2
6 years ago
0.12.1
6 years ago
0.12.0
6 years ago
0.11.1
6 years ago
0.11.0
6 years ago
0.10.0
6 years ago
0.9.1
6 years ago
0.8.0
6 years ago
0.7.0
6 years ago
0.6.0
6 years ago
0.5.1
6 years ago
0.4.2
6 years ago
0.4.0
6 years ago
0.3.0
6 years ago
0.2.0
6 years ago
0.1.1
6 years ago
0.1.0
6 years ago