freeclimb 2.0.1 → 2.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +100 -0
- data/README.md +11 -4
- data/docs/GetDigits.md +3 -1
- data/docs/GetDigitsAllOf.md +3 -1
- data/docs/GetSpeech.md +2 -2
- data/docs/GetSpeechAllOf.md +2 -2
- data/docs/Hangup.md +17 -0
- data/docs/HangupAllOf.md +17 -0
- data/docs/MakeCallRequest.md +7 -3
- data/docs/MessageResult.md +1 -1
- data/docs/MessageResultAllOf.md +1 -1
- data/docs/OutDial.md +3 -1
- data/docs/OutDialAllOf.md +3 -1
- data/docs/Play.md +3 -1
- data/docs/PlayAllOf.md +3 -1
- data/docs/RecordUtterance.md +3 -1
- data/docs/RecordUtteranceAllOf.md +3 -1
- data/docs/Redirect.md +1 -1
- data/docs/RedirectAllOf.md +1 -1
- data/docs/Reject.md +17 -0
- data/docs/RejectAllOf.md +17 -0
- data/docs/Say.md +2 -2
- data/docs/SayAllOf.md +2 -2
- data/docs/SendDigits.md +3 -1
- data/docs/SendDigitsAllOf.md +3 -1
- data/freeclimb-2.0.3.gem +0 -0
- data/freeclimb-2.1.0.gem +0 -0
- data/freeclimb-2.1.1.gem +0 -0
- data/lib/freeclimb.rb +4 -0
- data/lib/freeclimb/api_client.rb +1 -1
- data/lib/freeclimb/models/get_digits.rb +14 -4
- data/lib/freeclimb/models/get_digits_all_of.rb +14 -4
- data/lib/freeclimb/models/get_speech.rb +8 -8
- data/lib/freeclimb/models/get_speech_all_of.rb +8 -8
- data/lib/freeclimb/models/hangup.rb +220 -0
- data/lib/freeclimb/models/hangup_all_of.rb +207 -0
- data/lib/freeclimb/models/make_call_request.rb +26 -11
- data/lib/freeclimb/models/message_result.rb +3 -3
- data/lib/freeclimb/models/message_result_all_of.rb +3 -3
- data/lib/freeclimb/models/out_dial.rb +14 -4
- data/lib/freeclimb/models/out_dial_all_of.rb +14 -4
- data/lib/freeclimb/models/play.rb +14 -4
- data/lib/freeclimb/models/play_all_of.rb +14 -4
- data/lib/freeclimb/models/record_utterance.rb +14 -4
- data/lib/freeclimb/models/record_utterance_all_of.rb +14 -4
- data/lib/freeclimb/models/redirect.rb +7 -2
- data/lib/freeclimb/models/redirect_all_of.rb +6 -1
- data/lib/freeclimb/models/reject.rb +220 -0
- data/lib/freeclimb/models/reject_all_of.rb +207 -0
- data/lib/freeclimb/models/say.rb +8 -8
- data/lib/freeclimb/models/say_all_of.rb +8 -8
- data/lib/freeclimb/models/send_digits.rb +14 -4
- data/lib/freeclimb/models/send_digits_all_of.rb +14 -4
- data/lib/freeclimb/version.rb +1 -1
- data/spec/models/hangup_spec.rb +41 -0
- data/spec/models/reject_spec.rb +41 -0
- metadata +18 -2
data/docs/RedirectAllOf.md
CHANGED
@@ -4,7 +4,7 @@
|
|
4
4
|
|
5
5
|
Name | Type | Description | Notes
|
6
6
|
------------ | ------------- | ------------- | -------------
|
7
|
-
**action_url** | **String** |
|
7
|
+
**action_url** | **String** | URL to request a new PerCL script to continue with the current Call's processing. When `Redirect` invokes the `actionUrl`, an `inbound` Webhook is sent. This request therefore looks identical to the initial request (made to the `voiceUrl` of the number that was called) for an inbound Call. |
|
8
8
|
|
9
9
|
## Code Sample
|
10
10
|
|
data/docs/Reject.md
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# Freeclimb::Reject
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
Name | Type | Description | Notes
|
6
|
+
------------ | ------------- | ------------- | -------------
|
7
|
+
**reason** | **String** | Reason for the rejection. This can be any string value. In general, applications should use a set of enumerated values that are predefined to cover all exit points of the call flows for the given application. | [optional]
|
8
|
+
|
9
|
+
## Code Sample
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
require 'freeclimb'
|
13
|
+
|
14
|
+
instance = Freeclimb::Reject.new(reason: nil)
|
15
|
+
```
|
16
|
+
|
17
|
+
|
data/docs/RejectAllOf.md
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# Freeclimb::RejectAllOf
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
Name | Type | Description | Notes
|
6
|
+
------------ | ------------- | ------------- | -------------
|
7
|
+
**reason** | **String** | Reason for the rejection. This can be any string value. In general, applications should use a set of enumerated values that are predefined to cover all exit points of the call flows for the given application. | [optional]
|
8
|
+
|
9
|
+
## Code Sample
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
require 'freeclimb'
|
13
|
+
|
14
|
+
instance = Freeclimb::RejectAllOf.new(reason: nil)
|
15
|
+
```
|
16
|
+
|
17
|
+
|
data/docs/Say.md
CHANGED
@@ -8,7 +8,7 @@ Name | Type | Description | Notes
|
|
8
8
|
**language** | **String** | Language and (by implication) the locale to use. This implies the accent and pronunciations to be usde for the TTS. The complete list of valid values for the language attribute is shown below. | [optional]
|
9
9
|
**loop** | **Integer** | Number of times the text is said. Specifying '0' causes the `Say` action to loop until the Call is hung up. | [optional]
|
10
10
|
**conference_id** | **String** | D of the Conference the speech should be rendered to. If this is not specified, the speech is by default rendered to the Caller associated with the call leg that corresponds to the current PerCL execution context. The call leg associated with this command must be in the specified Conference or the command will return an error. | [optional]
|
11
|
-
**
|
11
|
+
**privacy_mode** | **Boolean** | Parameter `privacyMode` will not log the `text` as required by PCI compliance. | [optional]
|
12
12
|
|
13
13
|
## Code Sample
|
14
14
|
|
@@ -19,7 +19,7 @@ instance = Freeclimb::Say.new(text: nil,
|
|
19
19
|
language: nil,
|
20
20
|
loop: nil,
|
21
21
|
conference_id: nil,
|
22
|
-
|
22
|
+
privacy_mode: nil)
|
23
23
|
```
|
24
24
|
|
25
25
|
|
data/docs/SayAllOf.md
CHANGED
@@ -8,7 +8,7 @@ Name | Type | Description | Notes
|
|
8
8
|
**language** | **String** | Language and (by implication) the locale to use. This implies the accent and pronunciations to be usde for the TTS. The complete list of valid values for the language attribute is shown below. | [optional]
|
9
9
|
**loop** | **Integer** | Number of times the text is said. Specifying '0' causes the `Say` action to loop until the Call is hung up. | [optional]
|
10
10
|
**conference_id** | **String** | D of the Conference the speech should be rendered to. If this is not specified, the speech is by default rendered to the Caller associated with the call leg that corresponds to the current PerCL execution context. The call leg associated with this command must be in the specified Conference or the command will return an error. | [optional]
|
11
|
-
**
|
11
|
+
**privacy_mode** | **Boolean** | Parameter `privacyMode` will not log the `text` as required by PCI compliance. | [optional]
|
12
12
|
|
13
13
|
## Code Sample
|
14
14
|
|
@@ -19,7 +19,7 @@ instance = Freeclimb::SayAllOf.new(text: nil,
|
|
19
19
|
language: nil,
|
20
20
|
loop: nil,
|
21
21
|
conference_id: nil,
|
22
|
-
|
22
|
+
privacy_mode: nil)
|
23
23
|
```
|
24
24
|
|
25
25
|
|
data/docs/SendDigits.md
CHANGED
@@ -6,6 +6,7 @@ Name | Type | Description | Notes
|
|
6
6
|
------------ | ------------- | ------------- | -------------
|
7
7
|
**digits** | **String** | String containing the digits to be played. The string cannot be empty and can include any digit, plus `#`, or `*`, and allows embedding specification for delay or pause between the output of individual digits. |
|
8
8
|
**pause_ms** | **Integer** | Pause between digits in milliseconds. Valid values are 100-1000 milliseconds and will be adjusted by FreeClimb to satisfy the constraint. | [optional]
|
9
|
+
**privacy_mode** | **Boolean** | Parameter `privacyMode` will not log the `text` as required by PCI compliance. | [optional]
|
9
10
|
|
10
11
|
## Code Sample
|
11
12
|
|
@@ -13,7 +14,8 @@ Name | Type | Description | Notes
|
|
13
14
|
require 'freeclimb'
|
14
15
|
|
15
16
|
instance = Freeclimb::SendDigits.new(digits: nil,
|
16
|
-
pause_ms: nil
|
17
|
+
pause_ms: nil,
|
18
|
+
privacy_mode: nil)
|
17
19
|
```
|
18
20
|
|
19
21
|
|
data/docs/SendDigitsAllOf.md
CHANGED
@@ -6,6 +6,7 @@ Name | Type | Description | Notes
|
|
6
6
|
------------ | ------------- | ------------- | -------------
|
7
7
|
**digits** | **String** | String containing the digits to be played. The string cannot be empty and can include any digit, plus `#`, or `*`, and allows embedding specification for delay or pause between the output of individual digits. |
|
8
8
|
**pause_ms** | **Integer** | Pause between digits in milliseconds. Valid values are 100-1000 milliseconds and will be adjusted by FreeClimb to satisfy the constraint. | [optional]
|
9
|
+
**privacy_mode** | **Boolean** | Parameter `privacyMode` will not log the `text` as required by PCI compliance. | [optional]
|
9
10
|
|
10
11
|
## Code Sample
|
11
12
|
|
@@ -13,7 +14,8 @@ Name | Type | Description | Notes
|
|
13
14
|
require 'freeclimb'
|
14
15
|
|
15
16
|
instance = Freeclimb::SendDigitsAllOf.new(digits: nil,
|
16
|
-
pause_ms: nil
|
17
|
+
pause_ms: nil,
|
18
|
+
privacy_mode: nil)
|
17
19
|
```
|
18
20
|
|
19
21
|
|
data/freeclimb-2.0.3.gem
ADDED
Binary file
|
data/freeclimb-2.1.0.gem
ADDED
Binary file
|
data/freeclimb-2.1.1.gem
ADDED
Binary file
|
data/lib/freeclimb.rb
CHANGED
@@ -55,6 +55,8 @@ require 'freeclimb/models/get_digits'
|
|
55
55
|
require 'freeclimb/models/get_digits_all_of'
|
56
56
|
require 'freeclimb/models/get_speech'
|
57
57
|
require 'freeclimb/models/get_speech_all_of'
|
58
|
+
require 'freeclimb/models/hangup'
|
59
|
+
require 'freeclimb/models/hangup_all_of'
|
58
60
|
require 'freeclimb/models/incoming_number_list'
|
59
61
|
require 'freeclimb/models/incoming_number_list_all_of'
|
60
62
|
require 'freeclimb/models/incoming_number_request'
|
@@ -98,6 +100,8 @@ require 'freeclimb/models/recording_result'
|
|
98
100
|
require 'freeclimb/models/recording_result_all_of'
|
99
101
|
require 'freeclimb/models/redirect'
|
100
102
|
require 'freeclimb/models/redirect_all_of'
|
103
|
+
require 'freeclimb/models/reject'
|
104
|
+
require 'freeclimb/models/reject_all_of'
|
101
105
|
require 'freeclimb/models/remove_from_conference'
|
102
106
|
require 'freeclimb/models/remove_from_conference_all_of'
|
103
107
|
require 'freeclimb/models/say'
|
data/lib/freeclimb/api_client.rb
CHANGED
@@ -30,7 +30,7 @@ module Freeclimb
|
|
30
30
|
# @option config [Configuration] Configuration for initializing the object, default to Configuration.default
|
31
31
|
def initialize(config = Configuration.default)
|
32
32
|
@config = config
|
33
|
-
@user_agent = "FreeClimbSDK/2.
|
33
|
+
@user_agent = "FreeClimbSDK/2.1.2/ruby"
|
34
34
|
@default_headers = {
|
35
35
|
'Content-Type' => 'application/json',
|
36
36
|
'User-Agent' => @user_agent
|
@@ -39,6 +39,9 @@ module Freeclimb
|
|
39
39
|
# JSON array of PerCL commands to nest within the `GetDigits` command. The `Say`, `Play`, and `Pause` commands can be used. The nested actions are executed while FreeClimb is waiting for input from the Caller.
|
40
40
|
attr_accessor :prompts
|
41
41
|
|
42
|
+
# Parameter `privacyMode` will not log the `text` as required by PCI compliance.
|
43
|
+
attr_accessor :privacy_mode
|
44
|
+
|
42
45
|
# Attribute mapping from ruby-style variable name to JSON key.
|
43
46
|
def self.attribute_map
|
44
47
|
{
|
@@ -49,7 +52,8 @@ module Freeclimb
|
|
49
52
|
:'initial_timeout_ms' => :'initialTimeoutMs',
|
50
53
|
:'max_digits' => :'maxDigits',
|
51
54
|
:'min_digits' => :'minDigits',
|
52
|
-
:'prompts' => :'prompts'
|
55
|
+
:'prompts' => :'prompts',
|
56
|
+
:'privacy_mode' => :'privacyMode'
|
53
57
|
}
|
54
58
|
end
|
55
59
|
|
@@ -63,7 +67,8 @@ module Freeclimb
|
|
63
67
|
:'initial_timeout_ms' => :'String',
|
64
68
|
:'max_digits' => :'Integer',
|
65
69
|
:'min_digits' => :'Integer',
|
66
|
-
:'prompts' => :'Array<PerclCommand>'
|
70
|
+
:'prompts' => :'Array<PerclCommand>',
|
71
|
+
:'privacy_mode' => :'Boolean'
|
67
72
|
}
|
68
73
|
end
|
69
74
|
|
@@ -132,6 +137,10 @@ module Freeclimb
|
|
132
137
|
self.prompts = value
|
133
138
|
end
|
134
139
|
end
|
140
|
+
|
141
|
+
if attributes.key?(:'privacy_mode')
|
142
|
+
self.privacy_mode = attributes[:'privacy_mode']
|
143
|
+
end
|
135
144
|
end
|
136
145
|
|
137
146
|
# Show invalid properties with the reasons. Usually used together with valid?
|
@@ -164,7 +173,8 @@ module Freeclimb
|
|
164
173
|
initial_timeout_ms == o.initial_timeout_ms &&
|
165
174
|
max_digits == o.max_digits &&
|
166
175
|
min_digits == o.min_digits &&
|
167
|
-
prompts == o.prompts &&
|
176
|
+
prompts == o.prompts &&
|
177
|
+
privacy_mode == o.privacy_mode && super(o)
|
168
178
|
end
|
169
179
|
|
170
180
|
# @see the `==` method
|
@@ -176,7 +186,7 @@ module Freeclimb
|
|
176
186
|
# Calculates hash code according to all attributes.
|
177
187
|
# @return [Integer] Hash code
|
178
188
|
def hash
|
179
|
-
[action_url, digit_timeout_ms, finish_on_key, flush_buffer, initial_timeout_ms, max_digits, min_digits, prompts].hash
|
189
|
+
[action_url, digit_timeout_ms, finish_on_key, flush_buffer, initial_timeout_ms, max_digits, min_digits, prompts, privacy_mode].hash
|
180
190
|
end
|
181
191
|
|
182
192
|
# Builds the object from hash
|
@@ -38,6 +38,9 @@ module Freeclimb
|
|
38
38
|
# JSON array of PerCL commands to nest within the `GetDigits` command. The `Say`, `Play`, and `Pause` commands can be used. The nested actions are executed while FreeClimb is waiting for input from the Caller.
|
39
39
|
attr_accessor :prompts
|
40
40
|
|
41
|
+
# Parameter `privacyMode` will not log the `text` as required by PCI compliance.
|
42
|
+
attr_accessor :privacy_mode
|
43
|
+
|
41
44
|
# Attribute mapping from ruby-style variable name to JSON key.
|
42
45
|
def self.attribute_map
|
43
46
|
{
|
@@ -48,7 +51,8 @@ module Freeclimb
|
|
48
51
|
:'initial_timeout_ms' => :'initialTimeoutMs',
|
49
52
|
:'max_digits' => :'maxDigits',
|
50
53
|
:'min_digits' => :'minDigits',
|
51
|
-
:'prompts' => :'prompts'
|
54
|
+
:'prompts' => :'prompts',
|
55
|
+
:'privacy_mode' => :'privacyMode'
|
52
56
|
}
|
53
57
|
end
|
54
58
|
|
@@ -62,7 +66,8 @@ module Freeclimb
|
|
62
66
|
:'initial_timeout_ms' => :'String',
|
63
67
|
:'max_digits' => :'Integer',
|
64
68
|
:'min_digits' => :'Integer',
|
65
|
-
:'prompts' => :'Array<PerclCommand>'
|
69
|
+
:'prompts' => :'Array<PerclCommand>',
|
70
|
+
:'privacy_mode' => :'Boolean'
|
66
71
|
}
|
67
72
|
end
|
68
73
|
|
@@ -120,6 +125,10 @@ module Freeclimb
|
|
120
125
|
self.prompts = value
|
121
126
|
end
|
122
127
|
end
|
128
|
+
|
129
|
+
if attributes.key?(:'privacy_mode')
|
130
|
+
self.privacy_mode = attributes[:'privacy_mode']
|
131
|
+
end
|
123
132
|
end
|
124
133
|
|
125
134
|
# Show invalid properties with the reasons. Usually used together with valid?
|
@@ -152,7 +161,8 @@ module Freeclimb
|
|
152
161
|
initial_timeout_ms == o.initial_timeout_ms &&
|
153
162
|
max_digits == o.max_digits &&
|
154
163
|
min_digits == o.min_digits &&
|
155
|
-
prompts == o.prompts
|
164
|
+
prompts == o.prompts &&
|
165
|
+
privacy_mode == o.privacy_mode
|
156
166
|
end
|
157
167
|
|
158
168
|
# @see the `==` method
|
@@ -164,7 +174,7 @@ module Freeclimb
|
|
164
174
|
# Calculates hash code according to all attributes.
|
165
175
|
# @return [Integer] Hash code
|
166
176
|
def hash
|
167
|
-
[action_url, digit_timeout_ms, finish_on_key, flush_buffer, initial_timeout_ms, max_digits, min_digits, prompts].hash
|
177
|
+
[action_url, digit_timeout_ms, finish_on_key, flush_buffer, initial_timeout_ms, max_digits, min_digits, prompts, privacy_mode].hash
|
168
178
|
end
|
169
179
|
|
170
180
|
# Builds the object from hash
|
@@ -51,8 +51,8 @@ module Freeclimb
|
|
51
51
|
# Parameter `speechIncompleteTimeoutMs` specifies the length of silence following user speech after which a recognizer finalizes a result. This timeout applies when the speech prior to the silence is an incomplete match of all active grammars. Timeout `speechIncompleteTimeoutMs` is usually longer than `speechCompleteTimeoutMs` to allow users to pause mid-utterance.
|
52
52
|
attr_accessor :speech_incomplete_timeout_ms
|
53
53
|
|
54
|
-
# Parameter
|
55
|
-
attr_accessor :
|
54
|
+
# Parameter privacyMode will not log the `text` as required by PCI compliance.
|
55
|
+
attr_accessor :privacy_mode
|
56
56
|
|
57
57
|
# Attribute mapping from ruby-style variable name to JSON key.
|
58
58
|
def self.attribute_map
|
@@ -69,7 +69,7 @@ module Freeclimb
|
|
69
69
|
:'sensitivity_level' => :'sensitivityLevel',
|
70
70
|
:'speech_complete_timeout_ms' => :'speechCompleteTimeoutMs',
|
71
71
|
:'speech_incomplete_timeout_ms' => :'speechIncompleteTimeoutMs',
|
72
|
-
:'
|
72
|
+
:'privacy_mode' => :'privacyMode'
|
73
73
|
}
|
74
74
|
end
|
75
75
|
|
@@ -88,7 +88,7 @@ module Freeclimb
|
|
88
88
|
:'sensitivity_level' => :'Float',
|
89
89
|
:'speech_complete_timeout_ms' => :'Integer',
|
90
90
|
:'speech_incomplete_timeout_ms' => :'Integer',
|
91
|
-
:'
|
91
|
+
:'privacy_mode' => :'Boolean'
|
92
92
|
}
|
93
93
|
end
|
94
94
|
|
@@ -174,8 +174,8 @@ module Freeclimb
|
|
174
174
|
self.speech_incomplete_timeout_ms = attributes[:'speech_incomplete_timeout_ms']
|
175
175
|
end
|
176
176
|
|
177
|
-
if attributes.key?(:'
|
178
|
-
self.
|
177
|
+
if attributes.key?(:'privacy_mode')
|
178
|
+
self.privacy_mode = attributes[:'privacy_mode']
|
179
179
|
end
|
180
180
|
end
|
181
181
|
|
@@ -219,7 +219,7 @@ module Freeclimb
|
|
219
219
|
sensitivity_level == o.sensitivity_level &&
|
220
220
|
speech_complete_timeout_ms == o.speech_complete_timeout_ms &&
|
221
221
|
speech_incomplete_timeout_ms == o.speech_incomplete_timeout_ms &&
|
222
|
-
|
222
|
+
privacy_mode == o.privacy_mode && super(o)
|
223
223
|
end
|
224
224
|
|
225
225
|
# @see the `==` method
|
@@ -231,7 +231,7 @@ module Freeclimb
|
|
231
231
|
# Calculates hash code according to all attributes.
|
232
232
|
# @return [Integer] Hash code
|
233
233
|
def hash
|
234
|
-
[action_url, grammar_type, grammar_file, grammar_rule, play_beep, prompts, no_input_timeout_ms, recognition_timeout_ms, confidence_threshold, sensitivity_level, speech_complete_timeout_ms, speech_incomplete_timeout_ms,
|
234
|
+
[action_url, grammar_type, grammar_file, grammar_rule, play_beep, prompts, no_input_timeout_ms, recognition_timeout_ms, confidence_threshold, sensitivity_level, speech_complete_timeout_ms, speech_incomplete_timeout_ms, privacy_mode].hash
|
235
235
|
end
|
236
236
|
|
237
237
|
# Builds the object from hash
|
@@ -50,8 +50,8 @@ module Freeclimb
|
|
50
50
|
# Parameter `speechIncompleteTimeoutMs` specifies the length of silence following user speech after which a recognizer finalizes a result. This timeout applies when the speech prior to the silence is an incomplete match of all active grammars. Timeout `speechIncompleteTimeoutMs` is usually longer than `speechCompleteTimeoutMs` to allow users to pause mid-utterance.
|
51
51
|
attr_accessor :speech_incomplete_timeout_ms
|
52
52
|
|
53
|
-
# Parameter
|
54
|
-
attr_accessor :
|
53
|
+
# Parameter privacyMode will not log the `text` as required by PCI compliance.
|
54
|
+
attr_accessor :privacy_mode
|
55
55
|
|
56
56
|
# Attribute mapping from ruby-style variable name to JSON key.
|
57
57
|
def self.attribute_map
|
@@ -68,7 +68,7 @@ module Freeclimb
|
|
68
68
|
:'sensitivity_level' => :'sensitivityLevel',
|
69
69
|
:'speech_complete_timeout_ms' => :'speechCompleteTimeoutMs',
|
70
70
|
:'speech_incomplete_timeout_ms' => :'speechIncompleteTimeoutMs',
|
71
|
-
:'
|
71
|
+
:'privacy_mode' => :'privacyMode'
|
72
72
|
}
|
73
73
|
end
|
74
74
|
|
@@ -87,7 +87,7 @@ module Freeclimb
|
|
87
87
|
:'sensitivity_level' => :'Float',
|
88
88
|
:'speech_complete_timeout_ms' => :'Integer',
|
89
89
|
:'speech_incomplete_timeout_ms' => :'Integer',
|
90
|
-
:'
|
90
|
+
:'privacy_mode' => :'Boolean'
|
91
91
|
}
|
92
92
|
end
|
93
93
|
|
@@ -162,8 +162,8 @@ module Freeclimb
|
|
162
162
|
self.speech_incomplete_timeout_ms = attributes[:'speech_incomplete_timeout_ms']
|
163
163
|
end
|
164
164
|
|
165
|
-
if attributes.key?(:'
|
166
|
-
self.
|
165
|
+
if attributes.key?(:'privacy_mode')
|
166
|
+
self.privacy_mode = attributes[:'privacy_mode']
|
167
167
|
end
|
168
168
|
end
|
169
169
|
|
@@ -207,7 +207,7 @@ module Freeclimb
|
|
207
207
|
sensitivity_level == o.sensitivity_level &&
|
208
208
|
speech_complete_timeout_ms == o.speech_complete_timeout_ms &&
|
209
209
|
speech_incomplete_timeout_ms == o.speech_incomplete_timeout_ms &&
|
210
|
-
|
210
|
+
privacy_mode == o.privacy_mode
|
211
211
|
end
|
212
212
|
|
213
213
|
# @see the `==` method
|
@@ -219,7 +219,7 @@ module Freeclimb
|
|
219
219
|
# Calculates hash code according to all attributes.
|
220
220
|
# @return [Integer] Hash code
|
221
221
|
def hash
|
222
|
-
[action_url, grammar_type, grammar_file, grammar_rule, play_beep, prompts, no_input_timeout_ms, recognition_timeout_ms, confidence_threshold, sensitivity_level, speech_complete_timeout_ms, speech_incomplete_timeout_ms,
|
222
|
+
[action_url, grammar_type, grammar_file, grammar_rule, play_beep, prompts, no_input_timeout_ms, recognition_timeout_ms, confidence_threshold, sensitivity_level, speech_complete_timeout_ms, speech_incomplete_timeout_ms, privacy_mode].hash
|
223
223
|
end
|
224
224
|
|
225
225
|
# Builds the object from hash
|
@@ -0,0 +1,220 @@
|
|
1
|
+
=begin
|
2
|
+
#FreeClimb API
|
3
|
+
|
4
|
+
#FreeClimb is a cloud-based application programming interface (API) that puts the power of the Vail platform in your hands. FreeClimb simplifies the process of creating applications that can use a full range of telephony features without requiring specialized or on-site telephony equipment. Using the FreeClimb REST API to write applications is easy! You have the option to use the language of your choice or hit the API directly. Your application can execute a command by issuing a RESTful request to the FreeClimb API. The base URL to send HTTP requests to the FreeClimb REST API is: /apiserver. FreeClimb authenticates and processes your request.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module Freeclimb
|
16
|
+
# The `Hangup` command terminates a Call. If `Hangup` is used as the first action in a PerCL response, it does not prevent FreeClimb from answering the Call and billing your account. See the `Reject` command to hang up at no charge.
|
17
|
+
class Hangup < PerclCommand
|
18
|
+
# The user defined reason for the hangup. In general, applications should use a set of enumerated values that are predefined to cover all exit points of the Call flows for the given application.
|
19
|
+
attr_accessor :reason
|
20
|
+
|
21
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
22
|
+
def self.attribute_map
|
23
|
+
{
|
24
|
+
:'reason' => :'reason'
|
25
|
+
}
|
26
|
+
end
|
27
|
+
|
28
|
+
# Attribute type mapping.
|
29
|
+
def self.openapi_types
|
30
|
+
{
|
31
|
+
:'reason' => :'String'
|
32
|
+
}
|
33
|
+
end
|
34
|
+
|
35
|
+
# List of attributes with nullable: true
|
36
|
+
def self.openapi_nullable
|
37
|
+
Set.new([
|
38
|
+
])
|
39
|
+
end
|
40
|
+
|
41
|
+
# List of class defined in allOf (OpenAPI v3)
|
42
|
+
def self.openapi_all_of
|
43
|
+
[
|
44
|
+
:'HangupAllOf',
|
45
|
+
:'PerclCommand'
|
46
|
+
]
|
47
|
+
end
|
48
|
+
|
49
|
+
# Initializes the object
|
50
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
51
|
+
def initialize(attributes = {})
|
52
|
+
if (!attributes.is_a?(Hash))
|
53
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Freeclimb::Hangup` initialize method"
|
54
|
+
end
|
55
|
+
|
56
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
57
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
58
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
59
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Freeclimb::Hangup`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
60
|
+
end
|
61
|
+
h[k.to_sym] = v
|
62
|
+
}
|
63
|
+
|
64
|
+
# call parent's initialize
|
65
|
+
super(attributes)
|
66
|
+
|
67
|
+
if attributes.key?(:'reason')
|
68
|
+
self.reason = attributes[:'reason']
|
69
|
+
end
|
70
|
+
end
|
71
|
+
|
72
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
73
|
+
# @return Array for valid properties with the reasons
|
74
|
+
def list_invalid_properties
|
75
|
+
invalid_properties = super
|
76
|
+
invalid_properties
|
77
|
+
end
|
78
|
+
|
79
|
+
# Check to see if the all the properties in the model are valid
|
80
|
+
# @return true if the model is valid
|
81
|
+
def valid?
|
82
|
+
true && super
|
83
|
+
end
|
84
|
+
|
85
|
+
# Checks equality by comparing each attribute.
|
86
|
+
# @param [Object] Object to be compared
|
87
|
+
def ==(o)
|
88
|
+
return true if self.equal?(o)
|
89
|
+
self.class == o.class &&
|
90
|
+
reason == o.reason && super(o)
|
91
|
+
end
|
92
|
+
|
93
|
+
# @see the `==` method
|
94
|
+
# @param [Object] Object to be compared
|
95
|
+
def eql?(o)
|
96
|
+
self == o
|
97
|
+
end
|
98
|
+
|
99
|
+
# Calculates hash code according to all attributes.
|
100
|
+
# @return [Integer] Hash code
|
101
|
+
def hash
|
102
|
+
[reason].hash
|
103
|
+
end
|
104
|
+
|
105
|
+
# Builds the object from hash
|
106
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
107
|
+
# @return [Object] Returns the model itself
|
108
|
+
def self.build_from_hash(attributes)
|
109
|
+
new.build_from_hash(attributes)
|
110
|
+
end
|
111
|
+
|
112
|
+
# Builds the object from hash
|
113
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
114
|
+
# @return [Object] Returns the model itself
|
115
|
+
def build_from_hash(attributes)
|
116
|
+
return nil unless attributes.is_a?(Hash)
|
117
|
+
super(attributes)
|
118
|
+
self.class.openapi_types.each_pair do |key, type|
|
119
|
+
if type =~ /\AArray<(.*)>/i
|
120
|
+
# check to ensure the input is an array given that the attribute
|
121
|
+
# is documented as an array but the input is not
|
122
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
123
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
124
|
+
end
|
125
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
126
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
127
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
128
|
+
end
|
129
|
+
|
130
|
+
self
|
131
|
+
end
|
132
|
+
|
133
|
+
# Deserializes the data based on type
|
134
|
+
# @param string type Data type
|
135
|
+
# @param string value Value to be deserialized
|
136
|
+
# @return [Object] Deserialized data
|
137
|
+
def _deserialize(type, value)
|
138
|
+
case type.to_sym
|
139
|
+
when :DateTime
|
140
|
+
DateTime.parse(value)
|
141
|
+
when :Date
|
142
|
+
Date.parse(value)
|
143
|
+
when :String
|
144
|
+
value.to_s
|
145
|
+
when :Integer
|
146
|
+
value.to_i
|
147
|
+
when :Float
|
148
|
+
value.to_f
|
149
|
+
when :Boolean
|
150
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
151
|
+
true
|
152
|
+
else
|
153
|
+
false
|
154
|
+
end
|
155
|
+
when :Object
|
156
|
+
# generic object (usually a Hash), return directly
|
157
|
+
value
|
158
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
159
|
+
inner_type = Regexp.last_match[:inner_type]
|
160
|
+
value.map { |v| _deserialize(inner_type, v) }
|
161
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
162
|
+
k_type = Regexp.last_match[:k_type]
|
163
|
+
v_type = Regexp.last_match[:v_type]
|
164
|
+
{}.tap do |hash|
|
165
|
+
value.each do |k, v|
|
166
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
167
|
+
end
|
168
|
+
end
|
169
|
+
else # model
|
170
|
+
Freeclimb.const_get(type).build_from_hash(value)
|
171
|
+
end
|
172
|
+
end
|
173
|
+
|
174
|
+
# Returns the string representation of the object
|
175
|
+
# @return [String] String presentation of the object
|
176
|
+
def to_s
|
177
|
+
to_hash.to_s
|
178
|
+
end
|
179
|
+
|
180
|
+
# to_body is an alias to to_hash (backward compatibility)
|
181
|
+
# @return [Hash] Returns the object in the form of hash
|
182
|
+
def to_body
|
183
|
+
to_hash
|
184
|
+
end
|
185
|
+
|
186
|
+
# Returns the object in the form of hash
|
187
|
+
# @return [Hash] Returns the object in the form of hash
|
188
|
+
def to_hash
|
189
|
+
hash = super
|
190
|
+
self.class.attribute_map.each_pair do |attr, param|
|
191
|
+
value = self.send(attr)
|
192
|
+
if value.nil?
|
193
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
194
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
195
|
+
end
|
196
|
+
|
197
|
+
hash[param] = _to_hash(value)
|
198
|
+
end
|
199
|
+
hash
|
200
|
+
end
|
201
|
+
|
202
|
+
# Outputs non-array value in the form of hash
|
203
|
+
# For object, use to_hash. Otherwise, just return the value
|
204
|
+
# @param [Object] value Any valid value
|
205
|
+
# @return [Hash] Returns the value in the form of hash
|
206
|
+
def _to_hash(value)
|
207
|
+
if value.is_a?(Array)
|
208
|
+
value.compact.map { |v| _to_hash(v) }
|
209
|
+
elsif value.is_a?(Hash)
|
210
|
+
{}.tap do |hash|
|
211
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
212
|
+
end
|
213
|
+
elsif value.respond_to? :to_hash
|
214
|
+
value.to_hash
|
215
|
+
else
|
216
|
+
value
|
217
|
+
end
|
218
|
+
end
|
219
|
+
end
|
220
|
+
end
|