# katana-alexa-https-hosting

> Move Alexa skill on VPS

Latest version **2.0.0** (published 2019-04-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install katana-alexa-https-hosting
pnpm add katana-alexa-https-hosting
yarn add katana-alexa-https-hosting
bun add katana-alexa-https-hosting
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; large bundle.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2019-04-04 |
| First published | 2019-01-21 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 5 |
| Unpacked size | 35.6 MB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 0 |
| Author | MasamiYAMATE |
| Maintainers | aikawa_japan |
| Keywords | alexa |

## Links

- npm: https://www.npmjs.com/package/katana-alexa-https-hosting
- Repository: https://github.com/MasamiYamate/katana-alexa-https-hosting
- Homepage: https://github.com/MasamiYamate/katana-alexa-https-hosting#readme
- Issues: https://github.com/MasamiYamate/katana-alexa-https-hosting/issues
- npm.io page: https://npm.io/package/katana-alexa-https-hosting

## Dependencies (5)

- [ask-sdk](https://npm.io/package/ask-sdk.md) ^2.3.0
- [aws-sdk](https://npm.io/package/aws-sdk.md) ^2.391.0
- [express](https://npm.io/package/express.md) ^4.16.4
- [body-parser](https://npm.io/package/body-parser.md) ^1.18.3
- [alexa-verifier](https://npm.io/package/alexa-verifier.md) ^2.0.1

## Recent versions

- 2.0.0 (latest) — 2019-04-04
- 1.0.0 — 2019-01-22
- 0.0.1 — 2019-01-21

## README

# katana-alexa-https-hosting
Move Alexa skill on VPS

## Description
This module is for running Alexa Skill in an environment not Lambda.

## Installation
From npm

```
npm install --save katana-alexa-https-hosting
```

## How to use
**Please use a daemonization tool such as "forever" together.**

### example
```sample.js
const KatanaHttps = require('katana-alexa-https-hosting')
const Alexa = require('ask-sdk')

//Launch intent handler
const LaunchIntentHandler = {
    canHandle(handlerInput) {
        const request = handlerInput.requestEnvelope.request
        return request.type === 'LaunchRequest'
    },
    handle(handlerInput) {
        return handlerInput.responseBuilder
                .speak('Wellcome!')
                .withShouldEndSession(true)
                .getResponse();
    }
}

//Error intent handler
const ErrorHandler = {
    canHandle(handlerInput) {
        const request = handlerInput.requestEnvelope.request
        return request.type === 'LaunchRequest'
    },
    handle(handlerInput) {
		return handlerInput.responseBuilder
			.speak('Sorry, an error occurred.')
			.withShouldEndSession(true)
			.getResponse();
	}
}

//Generate skill builder.
//At this time, do not call "lambda ()" or "create ()".
var skillBuilder = Alexa.SkillBuilders.standard()
        .addErrorHandlers(LaunchIntentHandler)
        .addErrorHandlers(ErrorHandler)

//When using DynamoDB, region setting of aws-sdk is necessary.
KatanaHttps.awsSetup.setRegion('ap-northeast-1')

//Set the port number to be listened to.
//The default is 3000.
//KatanaHttps.expressSetup.setPortNo(3030)

//Set the path requested by the skill.
//The default value is "/"
//KatanaHttps.expressSetup.setAnyPath('/alexa/')

//I will set up the skill builder that I have created.
KatanaHttps.alexaSetup.setSkill(skillBuilder)

//Start the skill.
KatanaHttps.expressSetup.start()
```

---
_Source: https://npm.io/package/katana-alexa-https-hosting · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
