LoginSignup
0
0

More than 1 year has passed since last update.

enebularでalexaスキル その2

Posted at

概要

enebularで、alexaスキルのwebhookを返してみた。
herokuに、デプロイしてみた。
サービスリクエストをスクラッチで組み立てて、plunkerから、叩いてみた。
jsonを見直した。

投入したjson

{
	"session": {
		"new": true,
		"sessionId": "SessionId.hogehoge",
		"application": {
			"applicationId": "amzn.hogehoge"
		},
		"attributes": {
			"count": 1
		},
		"user": {
			"userId": "amzn.hogehoge"
		}
	},
	"request": {
		"type": "IntentRequest",
		"requestId": "EdwRequestId.hogehoge",
		"intent": {
			"name": "GenkiIntent",
			"slots": {
				"GenkiSlot": {
					"name": "GenkiSlot",
					"value": "元気"
				}
			}
		},
		"locale": "ja-JP",
		"timestamp": "2022-07-20T07:43:46Z"
	},
	"context": {
		"AudioPlayer": {
			"playerActivity": "IDLE"
		},
		"System": {
			"application": {
				"applicationId": "hogehoge"
			},
			"user": {
				"userId": "hogehoge"
			},
			"device": {
				"supportedInterfaces": {}
			}
		}
	},
	"version": "1.0"
}

実行結果

{"version":"1.0","sessionAttributes":{"count":"2"},"response":{"outputSpeech":{"type":"PlainText","text":"1 回目です。やたら、元気です。"},"card":{"type":"Simple","title":"カードここに書く","content":"今日は新しいことを学ぶチャンスが訪れるでしょう。 それをやり通せば可能性は無限です。"},"reprompt":{"outputSpeech":{"type":"PlainText","text":"他にも質問はありますか?"}},"shouldEndSession":false}}

成果物

以上。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0