alexa_skills_ruby 0.0.5 → 0.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/alexa_skills_ruby/json_objects/base_request.rb +2 -2
- data/lib/alexa_skills_ruby/version.rb +1 -1
- data/spec/fixtures/example_intent.json +1 -0
- data/spec/fixtures/example_launch.json +2 -1
- data/spec/fixtures/example_session_ended.json +1 -0
- data/spec/unit/json_objects/skills_request_spec.rb +4 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6df6b0746a4998158185fa5e834c9fe60dbc755c
|
4
|
+
data.tar.gz: 91dc818107fb6897f1363475f66b08955c510288
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d037f2108e8f47c2aa38811db16787fd0bef1226b687a6671ef452ff933d026b5710e9862e188bcf7b1418de9b1d92f317cade2cc1069499e92663f84eea07fe
|
7
|
+
data.tar.gz: b18af320c86824dfafc0f09b8a0b3bca79b024bbd41199dae251f0b617ddd4f37f7a73a7ac8636fe55eafe69dda6cee6a45ccf777159e4e288952f21ac84050d
|
@@ -1,7 +1,7 @@
|
|
1
1
|
module AlexaSkillsRuby
|
2
2
|
module JsonObjects
|
3
3
|
class BaseRequest < JsonObject
|
4
|
-
attributes :type, :request_id, :timestamp
|
4
|
+
attributes :type, :request_id, :timestamp, :locale
|
5
5
|
|
6
6
|
def self.new(*args, &block)
|
7
7
|
json = args.first
|
@@ -37,4 +37,4 @@ module AlexaSkillsRuby
|
|
37
37
|
|
38
38
|
end
|
39
39
|
end
|
40
|
-
end
|
40
|
+
end
|
@@ -30,6 +30,7 @@ describe AlexaSkillsRuby::JsonObjects::SkillsRequest do
|
|
30
30
|
expect(r.request.type).to eq 'LaunchRequest'
|
31
31
|
expect(r.request.request_id).to eq 'amzn1.echo-api.request.0000000-0000-0000-0000-00000000000'
|
32
32
|
expect(r.request.timestamp).to eq '2015-05-13T12:34:56Z'
|
33
|
+
expect(r.request.locale).to eq 'en-US'
|
33
34
|
end
|
34
35
|
|
35
36
|
it 'constructs an intent request' do
|
@@ -38,6 +39,7 @@ describe AlexaSkillsRuby::JsonObjects::SkillsRequest do
|
|
38
39
|
expect(r.request.type).to eq 'IntentRequest'
|
39
40
|
expect(r.request.request_id).to eq 'amzn1.echo-api.request.0000000-0000-0000-0000-00000000000'
|
40
41
|
expect(r.request.timestamp).to eq '2015-05-13T12:34:56Z'
|
42
|
+
expect(r.request.locale).to eq 'en-US'
|
41
43
|
expect(r.request.intent).to be_a AlexaSkillsRuby::JsonObjects::Intent
|
42
44
|
expect(r.request.intent.name).to eq 'GetZodiacHoroscopeIntent'
|
43
45
|
expect(r.request.intent.slots).to be_a Hash
|
@@ -50,7 +52,8 @@ describe AlexaSkillsRuby::JsonObjects::SkillsRequest do
|
|
50
52
|
expect(r.request.type).to eq 'SessionEndedRequest'
|
51
53
|
expect(r.request.request_id).to eq 'amzn1.echo-api.request.0000000-0000-0000-0000-00000000000'
|
52
54
|
expect(r.request.timestamp).to eq '2015-05-13T12:34:56Z'
|
55
|
+
expect(r.request.locale).to eq 'en-US'
|
53
56
|
expect(r.request.reason).to eq 'USER_INITIATED'
|
54
57
|
end
|
55
58
|
|
56
|
-
end
|
59
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: alexa_skills_ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dan Elbert
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-04
|
11
|
+
date: 2016-11-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -156,7 +156,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
156
156
|
version: '0'
|
157
157
|
requirements: []
|
158
158
|
rubyforge_project:
|
159
|
-
rubygems_version: 2.
|
159
|
+
rubygems_version: 2.5.1
|
160
160
|
signing_key:
|
161
161
|
specification_version: 4
|
162
162
|
summary: Simple library to interface with the Alexa Skills Kit
|