freeclimb 4.0.4 → 4.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (125) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +91 -9
  3. data/Gemfile.lock +1 -1
  4. data/README.md +25 -4
  5. data/docs/AccountResult.md +2 -2
  6. data/docs/AccountResultAllOf.md +2 -2
  7. data/docs/AccountStatus.md +18 -0
  8. data/docs/AccountType.md +17 -0
  9. data/docs/AnsweredBy.md +17 -0
  10. data/docs/CallDirection.md +18 -0
  11. data/docs/CallResult.md +3 -3
  12. data/docs/CallResultAllOf.md +3 -3
  13. data/docs/CallStatus.md +23 -0
  14. data/docs/ConferenceResult.md +2 -2
  15. data/docs/ConferenceResultAllOf.md +2 -2
  16. data/docs/ConferenceStatus.md +19 -0
  17. data/docs/CreateConference.md +2 -2
  18. data/docs/CreateConferenceAllOf.md +2 -2
  19. data/docs/CreateConferenceRequest.md +1 -1
  20. data/docs/DefaultApi.md +5 -5
  21. data/docs/Dequeue.md +1 -1
  22. data/docs/GetSpeech.md +3 -3
  23. data/docs/GetSpeechAllOf.md +3 -3
  24. data/docs/GetSpeechReason.md +21 -0
  25. data/docs/GrammarFileBuiltIn.md +30 -0
  26. data/docs/GrammarType.md +17 -0
  27. data/docs/IfMachine.md +17 -0
  28. data/docs/Language.md +41 -0
  29. data/docs/LogLevel.md +18 -0
  30. data/docs/LogResult.md +1 -1
  31. data/docs/MachineType.md +17 -0
  32. data/docs/MessageDirection.md +17 -0
  33. data/docs/MessageResult.md +1 -1
  34. data/docs/MessageResultAllOf.md +1 -1
  35. data/docs/MessageStatus.md +26 -0
  36. data/docs/OutDial.md +1 -1
  37. data/docs/OutDialAllOf.md +1 -1
  38. data/docs/PlayBeep.md +19 -0
  39. data/docs/QueueResultStatus.md +19 -0
  40. data/docs/RecordUtteranceTermReason.md +19 -0
  41. data/docs/RequestType.md +38 -0
  42. data/docs/StartRecordCall.md +1 -1
  43. data/docs/Unpark.md +1 -1
  44. data/docs/UpdateCallRequest.md +1 -1
  45. data/docs/UpdateCallRequestStatus.md +17 -0
  46. data/docs/UpdateConferenceRequest.md +2 -2
  47. data/docs/UpdateConferenceRequestStatus.md +17 -0
  48. data/lib/freeclimb/api/default_api.rb +4 -8
  49. data/lib/freeclimb/models/account_result.rb +2 -52
  50. data/lib/freeclimb/models/account_result_all_of.rb +2 -52
  51. data/lib/freeclimb/models/account_status.rb +38 -0
  52. data/lib/freeclimb/models/account_type.rb +37 -0
  53. data/lib/freeclimb/models/answered_by.rb +37 -0
  54. data/lib/freeclimb/models/call_direction.rb +38 -0
  55. data/lib/freeclimb/models/call_result.rb +3 -43
  56. data/lib/freeclimb/models/call_result_all_of.rb +3 -43
  57. data/lib/freeclimb/models/call_status.rb +43 -0
  58. data/lib/freeclimb/models/conference_result.rb +4 -52
  59. data/lib/freeclimb/models/conference_result_all_of.rb +4 -52
  60. data/lib/freeclimb/models/conference_status.rb +39 -0
  61. data/lib/freeclimb/models/create_conference.rb +4 -3
  62. data/lib/freeclimb/models/create_conference_all_of.rb +4 -3
  63. data/lib/freeclimb/models/create_conference_request.rb +1 -36
  64. data/lib/freeclimb/models/get_speech.rb +3 -4
  65. data/lib/freeclimb/models/get_speech_all_of.rb +3 -4
  66. data/lib/freeclimb/models/get_speech_reason.rb +41 -0
  67. data/lib/freeclimb/models/grammar_file_built_in.rb +50 -0
  68. data/lib/freeclimb/models/grammar_type.rb +37 -0
  69. data/lib/freeclimb/models/if_machine.rb +37 -0
  70. data/lib/freeclimb/models/language.rb +61 -0
  71. data/lib/freeclimb/models/log_level.rb +38 -0
  72. data/lib/freeclimb/models/log_result.rb +1 -37
  73. data/lib/freeclimb/models/machine_type.rb +37 -0
  74. data/lib/freeclimb/models/message_direction.rb +37 -0
  75. data/lib/freeclimb/models/message_result.rb +1 -37
  76. data/lib/freeclimb/models/message_result_all_of.rb +1 -37
  77. data/lib/freeclimb/models/message_status.rb +46 -0
  78. data/lib/freeclimb/models/out_dial.rb +1 -2
  79. data/lib/freeclimb/models/out_dial_all_of.rb +1 -2
  80. data/lib/freeclimb/models/play_beep.rb +39 -0
  81. data/lib/freeclimb/models/queue_result_status.rb +39 -0
  82. data/lib/freeclimb/models/record_utterance_term_reason.rb +39 -0
  83. data/lib/freeclimb/models/request_type.rb +58 -0
  84. data/lib/freeclimb/models/update_call_request.rb +1 -36
  85. data/lib/freeclimb/models/update_call_request_status.rb +37 -0
  86. data/lib/freeclimb/models/update_conference_request.rb +2 -50
  87. data/lib/freeclimb/models/update_conference_request_status.rb +37 -0
  88. data/lib/freeclimb/version.rb +1 -1
  89. data/lib/freeclimb.rb +21 -0
  90. data/openapi.json +4220 -0
  91. data/spec/api/default_api_spec.rb +532 -700
  92. data/spec/configuration_spec.rb +2 -1
  93. data/spec/models/account_result_spec.rb +0 -8
  94. data/spec/models/account_status_spec.rb +43 -0
  95. data/spec/models/account_type_spec.rb +38 -0
  96. data/spec/models/answered_by_spec.rb +38 -0
  97. data/spec/models/available_number_spec.rb +6 -0
  98. data/spec/models/call_direction_spec.rb +43 -0
  99. data/spec/models/call_result_spec.rb +0 -4
  100. data/spec/models/call_status_spec.rb +68 -0
  101. data/spec/models/conference_result_spec.rb +0 -8
  102. data/spec/models/conference_status_spec.rb +48 -0
  103. data/spec/models/create_conference_request_spec.rb +0 -4
  104. data/spec/models/get_speech_reason_spec.rb +58 -0
  105. data/spec/models/grammar_file_built_in_spec.rb +103 -0
  106. data/spec/models/grammar_type_spec.rb +38 -0
  107. data/spec/models/if_machine_spec.rb +38 -0
  108. data/spec/models/incoming_number_result_spec.rb +12 -0
  109. data/spec/models/language_spec.rb +158 -0
  110. data/spec/models/log_level_spec.rb +43 -0
  111. data/spec/models/log_result_spec.rb +0 -4
  112. data/spec/models/machine_type_spec.rb +38 -0
  113. data/spec/models/message_direction_spec.rb +38 -0
  114. data/spec/models/message_result_spec.rb +0 -4
  115. data/spec/models/message_status_spec.rb +83 -0
  116. data/spec/models/play_beep_spec.rb +48 -0
  117. data/spec/models/queue_result_spec.rb +1 -1
  118. data/spec/models/queue_result_status_spec.rb +48 -0
  119. data/spec/models/record_utterance_term_reason_spec.rb +48 -0
  120. data/spec/models/request_type_spec.rb +143 -0
  121. data/spec/models/update_call_request_spec.rb +0 -4
  122. data/spec/models/update_call_request_status_spec.rb +38 -0
  123. data/spec/models/update_conference_request_spec.rb +0 -4
  124. data/spec/models/update_conference_request_status_spec.rb +38 -0
  125. metadata +138 -53
@@ -0,0 +1,38 @@
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
+ Contact: support@freeclimb.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Freeclimb
17
+ class LogLevel
18
+ INFO = "info".freeze
19
+ WARNING = "warning".freeze
20
+ ERROR = "error".freeze
21
+
22
+ # Builds the enum from string
23
+ # @param [String] The enum value in the form of the string
24
+ # @return [String] The enum value
25
+ def self.build_from_hash(value)
26
+ new.build_from_hash(value)
27
+ end
28
+
29
+ # Builds the enum from string
30
+ # @param [String] The enum value in the form of the string
31
+ # @return [String] The enum value
32
+ def build_from_hash(value)
33
+ constantValues = LogLevel.constants.select { |c| LogLevel::const_get(c) == value }
34
+ raise "Invalid ENUM value #{value} for class #LogLevel" if constantValues.empty?
35
+ value
36
+ end
37
+ end
38
+ end
@@ -18,7 +18,6 @@ module Freeclimb
18
18
  # Time that the log was generated. The time is represented as microseconds since the Unix Epoch.
19
19
  attr_accessor :timestamp
20
20
 
21
- # Level of the log. Possible values are info, warning, and error.
22
21
  attr_accessor :level
23
22
 
24
23
  # ID of the request associated with the log. The requestId is propagated across all logs generated by FreeClimb when processing a request.
@@ -36,28 +35,6 @@ module Freeclimb
36
35
  # JSON document containing metadata about the event. Some log messages may include request and response header content in this field.
37
36
  attr_accessor :metadata
38
37
 
39
- class EnumAttributeValidator
40
- attr_reader :datatype
41
- attr_reader :allowable_values
42
-
43
- def initialize(datatype, allowable_values)
44
- @allowable_values = allowable_values.map do |value|
45
- case datatype.to_s
46
- when /Integer/i
47
- value.to_i
48
- when /Float/i
49
- value.to_f
50
- else
51
- value
52
- end
53
- end
54
- end
55
-
56
- def valid?(value)
57
- !value || allowable_values.include?(value)
58
- end
59
- end
60
-
61
38
  # Attribute mapping from ruby-style variable name to JSON key.
62
39
  def self.attribute_map
63
40
  {
@@ -80,7 +57,7 @@ module Freeclimb
80
57
  def self.openapi_types
81
58
  {
82
59
  :'timestamp' => :'Integer',
83
- :'level' => :'String',
60
+ :'level' => :'LogLevel',
84
61
  :'request_id' => :'String',
85
62
  :'account_id' => :'String',
86
63
  :'call_id' => :'String',
@@ -93,7 +70,6 @@ module Freeclimb
93
70
  def self.openapi_nullable
94
71
  Set.new([
95
72
  :'timestamp',
96
- :'level',
97
73
  :'request_id',
98
74
  :'account_id',
99
75
  :'call_id',
@@ -156,21 +132,9 @@ module Freeclimb
156
132
  # Check to see if the all the properties in the model are valid
157
133
  # @return true if the model is valid
158
134
  def valid?
159
- level_validator = EnumAttributeValidator.new('String', ["info", "warning", "error"])
160
- return false unless level_validator.valid?(@level)
161
135
  true
162
136
  end
163
137
 
164
- # Custom attribute writer method checking allowed values (enum).
165
- # @param [Object] level Object to be assigned
166
- def level=(level)
167
- validator = EnumAttributeValidator.new('String', ["info", "warning", "error"])
168
- unless validator.valid?(level)
169
- fail ArgumentError, "invalid value for \"level\", must be one of #{validator.allowable_values}."
170
- end
171
- @level = level
172
- end
173
-
174
138
  # Checks equality by comparing each attribute.
175
139
  # @param [Object] Object to be compared
176
140
  def ==(o)
@@ -0,0 +1,37 @@
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
+ Contact: support@freeclimb.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Freeclimb
17
+ class MachineType
18
+ ANSWERING_MACHINE = "answeringMachine".freeze
19
+ FAX_MACHINE = "faxMachine".freeze
20
+
21
+ # Builds the enum from string
22
+ # @param [String] The enum value in the form of the string
23
+ # @return [String] The enum value
24
+ def self.build_from_hash(value)
25
+ new.build_from_hash(value)
26
+ end
27
+
28
+ # Builds the enum from string
29
+ # @param [String] The enum value in the form of the string
30
+ # @return [String] The enum value
31
+ def build_from_hash(value)
32
+ constantValues = MachineType.constants.select { |c| MachineType::const_get(c) == value }
33
+ raise "Invalid ENUM value #{value} for class #MachineType" if constantValues.empty?
34
+ value
35
+ end
36
+ end
37
+ end
@@ -0,0 +1,37 @@
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
+ Contact: support@freeclimb.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Freeclimb
17
+ class MessageDirection
18
+ INBOUND = "inbound".freeze
19
+ OUTBOUND = "outbound".freeze
20
+
21
+ # Builds the enum from string
22
+ # @param [String] The enum value in the form of the string
23
+ # @return [String] The enum value
24
+ def self.build_from_hash(value)
25
+ new.build_from_hash(value)
26
+ end
27
+
28
+ # Builds the enum from string
29
+ # @param [String] The enum value in the form of the string
30
+ # @return [String] The enum value
31
+ def build_from_hash(value)
32
+ constantValues = MessageDirection.constants.select { |c| MessageDirection::const_get(c) == value }
33
+ raise "Invalid ENUM value #{value} for class #MessageDirection" if constantValues.empty?
34
+ value
35
+ end
36
+ end
37
+ end
@@ -33,7 +33,6 @@ module Freeclimb
33
33
  # String that uniquely identifies this message resource
34
34
  attr_accessor :message_id
35
35
 
36
- # Indicates the state of the message through the message lifecycle including: new, queued, rejected, sending, sent, failed, received, undelivered, expired, deleted, and unknown
37
36
  attr_accessor :status
38
37
 
39
38
  # Phone number in E.164 format that sent the message.
@@ -51,28 +50,6 @@ module Freeclimb
51
50
  # URL invoked when message sent
52
51
  attr_accessor :notification_url
53
52
 
54
- class EnumAttributeValidator
55
- attr_reader :datatype
56
- attr_reader :allowable_values
57
-
58
- def initialize(datatype, allowable_values)
59
- @allowable_values = allowable_values.map do |value|
60
- case datatype.to_s
61
- when /Integer/i
62
- value.to_i
63
- when /Float/i
64
- value.to_f
65
- else
66
- value
67
- end
68
- end
69
- end
70
-
71
- def valid?(value)
72
- !value || allowable_values.include?(value)
73
- end
74
- end
75
-
76
53
  # Attribute mapping from ruby-style variable name to JSON key.
77
54
  def self.attribute_map
78
55
  {
@@ -105,7 +82,7 @@ module Freeclimb
105
82
  :'revision' => :'Integer',
106
83
  :'account_id' => :'String',
107
84
  :'message_id' => :'String',
108
- :'status' => :'String',
85
+ :'status' => :'MessageStatus',
109
86
  :'from' => :'String',
110
87
  :'to' => :'String',
111
88
  :'text' => :'String',
@@ -119,7 +96,6 @@ module Freeclimb
119
96
  Set.new([
120
97
  :'account_id',
121
98
  :'message_id',
122
- :'status',
123
99
  :'from',
124
100
  :'to',
125
101
  :'text',
@@ -210,21 +186,9 @@ module Freeclimb
210
186
  # Check to see if the all the properties in the model are valid
211
187
  # @return true if the model is valid
212
188
  def valid?
213
- status_validator = EnumAttributeValidator.new('String', ["new", "queued", "rejected", "sending", "sent", "failed", "received", "undelivered", "expired", "deleted", "unknown"])
214
- return false unless status_validator.valid?(@status)
215
189
  true
216
190
  end
217
191
 
218
- # Custom attribute writer method checking allowed values (enum).
219
- # @param [Object] status Object to be assigned
220
- def status=(status)
221
- validator = EnumAttributeValidator.new('String', ["new", "queued", "rejected", "sending", "sent", "failed", "received", "undelivered", "expired", "deleted", "unknown"])
222
- unless validator.valid?(status)
223
- fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
224
- end
225
- @status = status
226
- end
227
-
228
192
  # Checks equality by comparing each attribute.
229
193
  # @param [Object] Object to be compared
230
194
  def ==(o)
@@ -21,7 +21,6 @@ module Freeclimb
21
21
  # String that uniquely identifies this message resource
22
22
  attr_accessor :message_id
23
23
 
24
- # Indicates the state of the message through the message lifecycle including: new, queued, rejected, sending, sent, failed, received, undelivered, expired, deleted, and unknown
25
24
  attr_accessor :status
26
25
 
27
26
  # Phone number in E.164 format that sent the message.
@@ -39,28 +38,6 @@ module Freeclimb
39
38
  # URL invoked when message sent
40
39
  attr_accessor :notification_url
41
40
 
42
- class EnumAttributeValidator
43
- attr_reader :datatype
44
- attr_reader :allowable_values
45
-
46
- def initialize(datatype, allowable_values)
47
- @allowable_values = allowable_values.map do |value|
48
- case datatype.to_s
49
- when /Integer/i
50
- value.to_i
51
- when /Float/i
52
- value.to_f
53
- else
54
- value
55
- end
56
- end
57
- end
58
-
59
- def valid?(value)
60
- !value || allowable_values.include?(value)
61
- end
62
- end
63
-
64
41
  # Attribute mapping from ruby-style variable name to JSON key.
65
42
  def self.attribute_map
66
43
  {
@@ -85,7 +62,7 @@ module Freeclimb
85
62
  {
86
63
  :'account_id' => :'String',
87
64
  :'message_id' => :'String',
88
- :'status' => :'String',
65
+ :'status' => :'MessageStatus',
89
66
  :'from' => :'String',
90
67
  :'to' => :'String',
91
68
  :'text' => :'String',
@@ -99,7 +76,6 @@ module Freeclimb
99
76
  Set.new([
100
77
  :'account_id',
101
78
  :'message_id',
102
- :'status',
103
79
  :'from',
104
80
  :'to',
105
81
  :'text',
@@ -166,21 +142,9 @@ module Freeclimb
166
142
  # Check to see if the all the properties in the model are valid
167
143
  # @return true if the model is valid
168
144
  def valid?
169
- status_validator = EnumAttributeValidator.new('String', ["new", "queued", "rejected", "sending", "sent", "failed", "received", "undelivered", "expired", "deleted", "unknown"])
170
- return false unless status_validator.valid?(@status)
171
145
  true
172
146
  end
173
147
 
174
- # Custom attribute writer method checking allowed values (enum).
175
- # @param [Object] status Object to be assigned
176
- def status=(status)
177
- validator = EnumAttributeValidator.new('String', ["new", "queued", "rejected", "sending", "sent", "failed", "received", "undelivered", "expired", "deleted", "unknown"])
178
- unless validator.valid?(status)
179
- fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
180
- end
181
- @status = status
182
- end
183
-
184
148
  # Checks equality by comparing each attribute.
185
149
  # @param [Object] Object to be compared
186
150
  def ==(o)
@@ -0,0 +1,46 @@
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
+ Contact: support@freeclimb.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Freeclimb
17
+ class MessageStatus
18
+ NEW = "new".freeze
19
+ QUEUED = "queued".freeze
20
+ REJECTED = "rejected".freeze
21
+ SENDING = "sending".freeze
22
+ SENT = "sent".freeze
23
+ FAILED = "failed".freeze
24
+ RECEIVED = "received".freeze
25
+ UNDELIVERED = "undelivered".freeze
26
+ EXPIRED = "expired".freeze
27
+ DELETED = "deleted".freeze
28
+ UNKNOWN = "unknown".freeze
29
+
30
+ # Builds the enum from string
31
+ # @param [String] The enum value in the form of the string
32
+ # @return [String] The enum value
33
+ def self.build_from_hash(value)
34
+ new.build_from_hash(value)
35
+ end
36
+
37
+ # Builds the enum from string
38
+ # @param [String] The enum value in the form of the string
39
+ # @return [String] The enum value
40
+ def build_from_hash(value)
41
+ constantValues = MessageStatus.constants.select { |c| MessageStatus::const_get(c) == value }
42
+ raise "Invalid ENUM value #{value} for class #MessageStatus" if constantValues.empty?
43
+ value
44
+ end
45
+ end
46
+ end
@@ -28,7 +28,6 @@ module Freeclimb
28
28
  # E.164 representation of the phone number to Call.
29
29
  attr_accessor :destination
30
30
 
31
- # Specifies how FreeClimb should handle this OutDial if an answering machine answers the Call. Valid values: `redirect` invokes the ifMachineUrl for instructions. `hangup` hangs up the Call. The ifMachineUrl will not be invoked.
32
31
  attr_accessor :if_machine
33
32
 
34
33
  # When the `ifMachine` flag is set to `redirect`, this attribute specifies a URL to which FreeClimb makes a POST request when an answering machine or a fax machine is detected. This URL is required if the `ifMachine` flag is set to `redirect`. Otherwise, it should not be included.
@@ -74,7 +73,7 @@ module Freeclimb
74
73
  :'call_connect_url' => :'String',
75
74
  :'calling_number' => :'Float',
76
75
  :'destination' => :'Float',
77
- :'if_machine' => :'String',
76
+ :'if_machine' => :'IfMachine',
78
77
  :'if_machine_url' => :'String',
79
78
  :'send_digits' => :'String',
80
79
  :'status_callback_url' => :'String',
@@ -27,7 +27,6 @@ module Freeclimb
27
27
  # E.164 representation of the phone number to Call.
28
28
  attr_accessor :destination
29
29
 
30
- # Specifies how FreeClimb should handle this OutDial if an answering machine answers the Call. Valid values: `redirect` invokes the ifMachineUrl for instructions. `hangup` hangs up the Call. The ifMachineUrl will not be invoked.
31
30
  attr_accessor :if_machine
32
31
 
33
32
  # When the `ifMachine` flag is set to `redirect`, this attribute specifies a URL to which FreeClimb makes a POST request when an answering machine or a fax machine is detected. This URL is required if the `ifMachine` flag is set to `redirect`. Otherwise, it should not be included.
@@ -73,7 +72,7 @@ module Freeclimb
73
72
  :'call_connect_url' => :'String',
74
73
  :'calling_number' => :'Float',
75
74
  :'destination' => :'Float',
76
- :'if_machine' => :'String',
75
+ :'if_machine' => :'IfMachine',
77
76
  :'if_machine_url' => :'String',
78
77
  :'send_digits' => :'String',
79
78
  :'status_callback_url' => :'String',
@@ -0,0 +1,39 @@
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
+ Contact: support@freeclimb.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Freeclimb
17
+ class PlayBeep
18
+ ALWAYS = "always".freeze
19
+ NEVER = "never".freeze
20
+ ENTRY_ONLY = "entryOnly".freeze
21
+ EXIT_ONLY = "exitOnly".freeze
22
+
23
+ # Builds the enum from string
24
+ # @param [String] The enum value in the form of the string
25
+ # @return [String] The enum value
26
+ def self.build_from_hash(value)
27
+ new.build_from_hash(value)
28
+ end
29
+
30
+ # Builds the enum from string
31
+ # @param [String] The enum value in the form of the string
32
+ # @return [String] The enum value
33
+ def build_from_hash(value)
34
+ constantValues = PlayBeep.constants.select { |c| PlayBeep::const_get(c) == value }
35
+ raise "Invalid ENUM value #{value} for class #PlayBeep" if constantValues.empty?
36
+ value
37
+ end
38
+ end
39
+ end
@@ -0,0 +1,39 @@
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
+ Contact: support@freeclimb.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Freeclimb
17
+ class QueueResultStatus
18
+ QUEUE_FULL = "queueFull".freeze
19
+ DEQUEUED = "dequeued".freeze
20
+ HANGUP = "hangup".freeze
21
+ SYSTEM_ERROR = "systemError".freeze
22
+
23
+ # Builds the enum from string
24
+ # @param [String] The enum value in the form of the string
25
+ # @return [String] The enum value
26
+ def self.build_from_hash(value)
27
+ new.build_from_hash(value)
28
+ end
29
+
30
+ # Builds the enum from string
31
+ # @param [String] The enum value in the form of the string
32
+ # @return [String] The enum value
33
+ def build_from_hash(value)
34
+ constantValues = QueueResultStatus.constants.select { |c| QueueResultStatus::const_get(c) == value }
35
+ raise "Invalid ENUM value #{value} for class #QueueResultStatus" if constantValues.empty?
36
+ value
37
+ end
38
+ end
39
+ end
@@ -0,0 +1,39 @@
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
+ Contact: support@freeclimb.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Freeclimb
17
+ class RecordUtteranceTermReason
18
+ FINISH_KEY = "finishKey".freeze
19
+ TIMEOUT = "timeout".freeze
20
+ HANGUP = "hangup".freeze
21
+ MAX_LENGTH = "maxLength".freeze
22
+
23
+ # Builds the enum from string
24
+ # @param [String] The enum value in the form of the string
25
+ # @return [String] The enum value
26
+ def self.build_from_hash(value)
27
+ new.build_from_hash(value)
28
+ end
29
+
30
+ # Builds the enum from string
31
+ # @param [String] The enum value in the form of the string
32
+ # @return [String] The enum value
33
+ def build_from_hash(value)
34
+ constantValues = RecordUtteranceTermReason.constants.select { |c| RecordUtteranceTermReason::const_get(c) == value }
35
+ raise "Invalid ENUM value #{value} for class #RecordUtteranceTermReason" if constantValues.empty?
36
+ value
37
+ end
38
+ end
39
+ end
@@ -0,0 +1,58 @@
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
+ Contact: support@freeclimb.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 5.4.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Freeclimb
17
+ class RequestType
18
+ INBOUND_CALL = "inboundCall".freeze
19
+ RECORD = "record".freeze
20
+ GET_DIGITS = "getDigits".freeze
21
+ GET_SPEECH = "getSpeech".freeze
22
+ REDIRECT = "redirect".freeze
23
+ PAUSE = "pause".freeze
24
+ OUT_DIAL_START = "outDialStart".freeze
25
+ OUT_DIAL_CONNECT = "outDialConnect".freeze
26
+ OUT_DIAL_API_CONNECT = "outDialApiConnect".freeze
27
+ MACHINE_DETECTED = "machineDetected".freeze
28
+ DEQUEUE = "dequeue".freeze
29
+ QUEUE_WAIT = "queueWait".freeze
30
+ ADD_TO_QUEUE_NOTIFICATION = "addToQueueNotification".freeze
31
+ REMOVE_FROM_QUEUE_NOTIFICATION = "removeFromQueueNotification".freeze
32
+ CALL_STATUS = "callStatus".freeze
33
+ CREATE_CONFERENCE = "createConference".freeze
34
+ CONFERENCE_STATUS = "conferenceStatus".freeze
35
+ LEAVE_CONFERENCE = "leaveConference".freeze
36
+ ADD_TO_CONFERENCE_NOTIFICATION = "addToConferenceNotification".freeze
37
+ CONFERENCE_RECORDING_STATUS = "conferenceRecordingStatus".freeze
38
+ CONFERENCE_CALL_CONTROL = "conferenceCallControl".freeze
39
+ MESSAGE_DELIVERY = "messageDelivery".freeze
40
+ MESSAGE_STATUS = "messageStatus".freeze
41
+
42
+ # Builds the enum from string
43
+ # @param [String] The enum value in the form of the string
44
+ # @return [String] The enum value
45
+ def self.build_from_hash(value)
46
+ new.build_from_hash(value)
47
+ end
48
+
49
+ # Builds the enum from string
50
+ # @param [String] The enum value in the form of the string
51
+ # @return [String] The enum value
52
+ def build_from_hash(value)
53
+ constantValues = RequestType.constants.select { |c| RequestType::const_get(c) == value }
54
+ raise "Invalid ENUM value #{value} for class #RequestType" if constantValues.empty?
55
+ value
56
+ end
57
+ end
58
+ end
@@ -15,31 +15,8 @@ require 'time'
15
15
 
16
16
  module Freeclimb
17
17
  class UpdateCallRequest
18
- # Either `canceled` or `completed`. Specifying `canceled` attempts to hang up calls that are queued without affecting calls already in progress. Specifying `completed` attempts to hang up a call already in progress.
19
18
  attr_accessor :status
20
19
 
21
- class EnumAttributeValidator
22
- attr_reader :datatype
23
- attr_reader :allowable_values
24
-
25
- def initialize(datatype, allowable_values)
26
- @allowable_values = allowable_values.map do |value|
27
- case datatype.to_s
28
- when /Integer/i
29
- value.to_i
30
- when /Float/i
31
- value.to_f
32
- else
33
- value
34
- end
35
- end
36
- end
37
-
38
- def valid?(value)
39
- !value || allowable_values.include?(value)
40
- end
41
- end
42
-
43
20
  # Attribute mapping from ruby-style variable name to JSON key.
44
21
  def self.attribute_map
45
22
  {
@@ -55,7 +32,7 @@ module Freeclimb
55
32
  # Attribute type mapping.
56
33
  def self.openapi_types
57
34
  {
58
- :'status' => :'String'
35
+ :'status' => :'UpdateCallRequestStatus'
59
36
  }
60
37
  end
61
38
 
@@ -100,21 +77,9 @@ module Freeclimb
100
77
  # @return true if the model is valid
101
78
  def valid?
102
79
  return false if @status.nil?
103
- status_validator = EnumAttributeValidator.new('String', ["canceled", "completed"])
104
- return false unless status_validator.valid?(@status)
105
80
  true
106
81
  end
107
82
 
108
- # Custom attribute writer method checking allowed values (enum).
109
- # @param [Object] status Object to be assigned
110
- def status=(status)
111
- validator = EnumAttributeValidator.new('String', ["canceled", "completed"])
112
- unless validator.valid?(status)
113
- fail ArgumentError, "invalid value for \"status\", must be one of #{validator.allowable_values}."
114
- end
115
- @status = status
116
- end
117
-
118
83
  # Checks equality by comparing each attribute.
119
84
  # @param [Object] Object to be compared
120
85
  def ==(o)