trails 1.1.5 → 1.1.6
Sign up to get free protection for your applications and to get access to all the features.
- data/.gemtest +0 -0
- data/Rakefile +1 -1
- data/lib/trails.rb +1 -1
- data/lib/trails/twilio/incoming.rb +30 -26
- metadata +29 -30
data/.gemtest
ADDED
File without changes
|
data/Rakefile
CHANGED
data/lib/trails.rb
CHANGED
@@ -23,35 +23,39 @@ module Trails
|
|
23
23
|
attr_reader :request
|
24
24
|
|
25
25
|
INCOMING_VARS = [
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
26
|
+
# Always available:
|
27
|
+
'CallSid', # A unique identifier for this call, generated by Twilio.
|
28
|
+
'AccountSid', # Your Twilio account id. It is 34 characters long, and always starts with the letters AC.
|
29
|
+
'From', # The phone number of the party that initiated the call. Formatted with a '+' and country code e.g., +16175551212 (E.164 format). If the call is inbound, then it is the caller's caller ID. If the call is outbound, i.e., initiated via a request to the REST API, then this is the phone number you specify as the caller ID.
|
30
|
+
'To', # The phone number of the called party. Formatted with a '+' and country code e.g., +16175551212 (E.164 format). If the call is inbound, then it's your Twilio phone number. If the call is outbound, then it's the phone number you provided to call.
|
31
|
+
'CallStatus', # A descriptive status for the call. The value is one of queued, ringing, in-progress, completed, busy, failed or no-answer. See the CallStatus section below for more details.
|
32
|
+
'ApiVersion', # The version of the Twilio API used to handle this call. For incoming calls, this is determined by the API version set on the called number. For outgoing calls, this is the API version used by the outgoing call's REST API request.
|
33
|
+
'Direction', # Indicates the direction of the call. In most cases this will be inbound, but if you are using <Dial> it will be outbound-dial.
|
34
|
+
'ForwardedFrom', # This parameter is set only when Twilio receives a forwarded call, but its value depends on the caller's carrier including information when forwarding. Not all carriers support passing this information.
|
35
|
+
'FromCity', # The city of the caller.
|
36
|
+
'FromState', # The state or province of the caller.
|
37
|
+
'FromZip', # The postal code of the caller.
|
38
|
+
'FromCountry', # The country of the caller.
|
39
|
+
'ToCity', # The city of the called party.
|
40
|
+
'ToState', # The state or province of the called party.
|
41
|
+
'ToZip', # The postal code of the called party.
|
42
|
+
'ToCountry', # The country of the called party.
|
42
43
|
|
43
|
-
|
44
|
-
|
45
|
-
'Digits', # What (if any) key was pressed to end the recording
|
44
|
+
# Gather:
|
45
|
+
'Digits', # The digits received from the caller
|
46
46
|
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
'From', #
|
51
|
-
'To', #
|
52
|
-
'Body', # 160 chars
|
47
|
+
'RecordingUrl', # The URL of the recorded audio file
|
48
|
+
'Duration', # The time duration of the recorded audio file
|
49
|
+
'Digits', # What (if any) key was pressed to end the recording
|
53
50
|
|
54
|
-
|
51
|
+
# SMS:
|
52
|
+
'SmsMessageSid', # Message SID
|
53
|
+
'AccountSid', # Account ID
|
54
|
+
'From', #
|
55
|
+
'To', #
|
56
|
+
'Body', # 160 chars
|
57
|
+
|
58
|
+
].freeze
|
55
59
|
public
|
56
60
|
INCOMING_VARS.uniq.each do |pname|
|
57
61
|
mname = pname.gsub( /[A-Z]/ ) { |s| "_#{s.downcase}" }.gsub( /^_/, '' )
|
metadata
CHANGED
@@ -1,7 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: trails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
|
4
|
+
hash: 31
|
5
|
+
prerelease: false
|
6
|
+
segments:
|
7
|
+
- 1
|
8
|
+
- 1
|
9
|
+
- 6
|
10
|
+
version: 1.1.6
|
5
11
|
platform: ruby
|
6
12
|
authors:
|
7
13
|
- Hemant Bhanoo
|
@@ -9,39 +15,25 @@ autorequire:
|
|
9
15
|
bindir: bin
|
10
16
|
cert_chain: []
|
11
17
|
|
12
|
-
date:
|
18
|
+
date: 2011-02-19 00:00:00 -08:00
|
13
19
|
default_executable:
|
14
20
|
dependencies:
|
15
|
-
- !ruby/object:Gem::Dependency
|
16
|
-
name: rubyforge
|
17
|
-
type: :development
|
18
|
-
version_requirement:
|
19
|
-
version_requirements: !ruby/object:Gem::Requirement
|
20
|
-
requirements:
|
21
|
-
- - ">="
|
22
|
-
- !ruby/object:Gem::Version
|
23
|
-
version: 2.0.3
|
24
|
-
version:
|
25
|
-
- !ruby/object:Gem::Dependency
|
26
|
-
name: gemcutter
|
27
|
-
type: :development
|
28
|
-
version_requirement:
|
29
|
-
version_requirements: !ruby/object:Gem::Requirement
|
30
|
-
requirements:
|
31
|
-
- - ">="
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: 0.3.0
|
34
|
-
version:
|
35
21
|
- !ruby/object:Gem::Dependency
|
36
22
|
name: hoe
|
37
|
-
|
38
|
-
|
39
|
-
|
23
|
+
prerelease: false
|
24
|
+
requirement: &id001 !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
40
26
|
requirements:
|
41
27
|
- - ">="
|
42
28
|
- !ruby/object:Gem::Version
|
43
|
-
|
44
|
-
|
29
|
+
hash: 41
|
30
|
+
segments:
|
31
|
+
- 2
|
32
|
+
- 9
|
33
|
+
- 1
|
34
|
+
version: 2.9.1
|
35
|
+
type: :development
|
36
|
+
version_requirements: *id001
|
45
37
|
description: |-
|
46
38
|
Makes developing twilio applications (even) easier in rails.
|
47
39
|
Support for SMS, twiml MimeType alias, functional test helpers.
|
@@ -111,6 +103,7 @@ files:
|
|
111
103
|
- test/example/test/test_helper.rb
|
112
104
|
- test/example/test/unit/helpers/calls_helper_test.rb
|
113
105
|
- test/test_trails.rb
|
106
|
+
- .gemtest
|
114
107
|
has_rdoc: true
|
115
108
|
homepage: http://code.google.com/p/twilio-on-rails/
|
116
109
|
licenses: []
|
@@ -122,21 +115,27 @@ rdoc_options:
|
|
122
115
|
require_paths:
|
123
116
|
- lib
|
124
117
|
required_ruby_version: !ruby/object:Gem::Requirement
|
118
|
+
none: false
|
125
119
|
requirements:
|
126
120
|
- - ">="
|
127
121
|
- !ruby/object:Gem::Version
|
122
|
+
hash: 3
|
123
|
+
segments:
|
124
|
+
- 0
|
128
125
|
version: "0"
|
129
|
-
version:
|
130
126
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
127
|
+
none: false
|
131
128
|
requirements:
|
132
129
|
- - ">="
|
133
130
|
- !ruby/object:Gem::Version
|
131
|
+
hash: 3
|
132
|
+
segments:
|
133
|
+
- 0
|
134
134
|
version: "0"
|
135
|
-
version:
|
136
135
|
requirements: []
|
137
136
|
|
138
137
|
rubyforge_project: trails
|
139
|
-
rubygems_version: 1.3.
|
138
|
+
rubygems_version: 1.3.7
|
140
139
|
signing_key:
|
141
140
|
specification_version: 3
|
142
141
|
summary: Makes developing twilio applications (even) easier in rails
|