freeclimb 4.5.2 → 4.6.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (183) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +20 -0
  3. data/Gemfile.lock +1 -1
  4. data/README.md +15 -7
  5. data/docs/AddToConference.md +0 -2
  6. data/docs/AddToConferenceAllOf.md +0 -2
  7. data/docs/CreateWebRTCToken.md +22 -0
  8. data/docs/DefaultApi.md +303 -7
  9. data/docs/GetDigits.md +1 -1
  10. data/docs/GetDigitsAllOf.md +1 -1
  11. data/docs/IncomingNumberResult.md +3 -1
  12. data/docs/IncomingNumberResultAllOf.md +3 -1
  13. data/docs/MessageRequest.md +2 -2
  14. data/docs/MessageRequestAllOf.md +2 -2
  15. data/docs/MessageResult.md +3 -1
  16. data/docs/MessageResultAllOf.md +3 -1
  17. data/docs/Play.md +0 -2
  18. data/docs/PlayAllOf.md +0 -2
  19. data/docs/RemoveFromConference.md +1 -4
  20. data/docs/SMSTenDLCCampaign.md +10 -0
  21. data/docs/SMSTollFreeCampaign.md +30 -0
  22. data/docs/SMSTollFreeCampaignsListResult.md +32 -0
  23. data/docs/SMSTollFreeCampaignsListResultAllOf.md +18 -0
  24. data/docs/Say.md +0 -2
  25. data/docs/SayAllOf.md +0 -2
  26. data/docs/SetListen.md +0 -2
  27. data/docs/SetListenAllOf.md +0 -2
  28. data/docs/SetTalk.md +0 -2
  29. data/docs/SetTalkAllOf.md +0 -2
  30. data/docs/TFN.md +18 -0
  31. data/docs/TerminateConference.md +1 -4
  32. data/docs/TranscribeUtterance.md +1 -1
  33. data/docs/TranscribeUtteranceAllOf.md +28 -0
  34. data/docs/TranscribeUtteranceAllOfRecord.md +22 -0
  35. data/lib/freeclimb/api/default_api.rb +262 -7
  36. data/lib/freeclimb/models/account_request.rb +0 -2
  37. data/lib/freeclimb/models/account_result.rb +0 -6
  38. data/lib/freeclimb/models/add_to_conference.rb +1 -29
  39. data/lib/freeclimb/models/add_to_conference_all_of.rb +1 -29
  40. data/lib/freeclimb/models/application_result.rb +0 -6
  41. data/lib/freeclimb/models/buy_incoming_number_request.rb +0 -4
  42. data/lib/freeclimb/models/call_result.rb +0 -6
  43. data/lib/freeclimb/models/conference_participant_result.rb +0 -6
  44. data/lib/freeclimb/models/conference_result.rb +0 -6
  45. data/lib/freeclimb/models/create_conference.rb +0 -8
  46. data/lib/freeclimb/models/create_conference_all_of.rb +0 -8
  47. data/lib/freeclimb/models/create_conference_request.rb +0 -6
  48. data/lib/freeclimb/models/create_web_rtc_token.rb +274 -0
  49. data/lib/freeclimb/models/dequeue.rb +1 -0
  50. data/lib/freeclimb/models/enqueue.rb +0 -6
  51. data/lib/freeclimb/models/enqueue_all_of.rb +0 -6
  52. data/lib/freeclimb/models/get_digits.rb +1 -17
  53. data/lib/freeclimb/models/get_digits_all_of.rb +1 -17
  54. data/lib/freeclimb/models/get_speech.rb +0 -22
  55. data/lib/freeclimb/models/get_speech_all_of.rb +0 -22
  56. data/lib/freeclimb/models/incoming_number_request.rb +0 -2
  57. data/lib/freeclimb/models/incoming_number_result.rb +14 -13
  58. data/lib/freeclimb/models/incoming_number_result_all_of.rb +14 -5
  59. data/lib/freeclimb/models/make_call_request.rb +0 -18
  60. data/lib/freeclimb/models/message_request.rb +10 -24
  61. data/lib/freeclimb/models/message_request_all_of.rb +10 -16
  62. data/lib/freeclimb/models/message_result.rb +17 -11
  63. data/lib/freeclimb/models/message_result_all_of.rb +17 -5
  64. data/lib/freeclimb/models/mutable_resource_model.rb +0 -6
  65. data/lib/freeclimb/models/out_dial.rb +0 -18
  66. data/lib/freeclimb/models/out_dial_all_of.rb +0 -18
  67. data/lib/freeclimb/models/park.rb +0 -4
  68. data/lib/freeclimb/models/park_all_of.rb +0 -4
  69. data/lib/freeclimb/models/play.rb +1 -17
  70. data/lib/freeclimb/models/play_all_of.rb +1 -17
  71. data/lib/freeclimb/models/queue_request.rb +0 -2
  72. data/lib/freeclimb/models/queue_result.rb +0 -6
  73. data/lib/freeclimb/models/record_utterance.rb +0 -12
  74. data/lib/freeclimb/models/record_utterance_all_of.rb +0 -12
  75. data/lib/freeclimb/models/recording_result.rb +0 -6
  76. data/lib/freeclimb/models/remove_from_conference.rb +4 -23
  77. data/lib/freeclimb/models/say.rb +1 -19
  78. data/lib/freeclimb/models/say_all_of.rb +1 -19
  79. data/lib/freeclimb/models/send_digits.rb +0 -4
  80. data/lib/freeclimb/models/send_digits_all_of.rb +0 -4
  81. data/lib/freeclimb/models/set_listen.rb +2 -18
  82. data/lib/freeclimb/models/set_listen_all_of.rb +2 -18
  83. data/lib/freeclimb/models/set_talk.rb +2 -18
  84. data/lib/freeclimb/models/set_talk_all_of.rb +2 -18
  85. data/lib/freeclimb/models/sms.rb +0 -6
  86. data/lib/freeclimb/models/sms_all_of.rb +0 -6
  87. data/lib/freeclimb/models/sms_ten_dlc_brand.rb +0 -60
  88. data/lib/freeclimb/models/sms_ten_dlc_campaign.rb +121 -41
  89. data/lib/freeclimb/models/sms_ten_dlc_partner_campaign.rb +0 -44
  90. data/lib/freeclimb/models/sms_ten_dlc_partner_campaign_brand.rb +0 -20
  91. data/lib/freeclimb/models/sms_toll_free_campaign.rb +337 -0
  92. data/lib/freeclimb/models/sms_toll_free_campaigns_list_result.rb +311 -0
  93. data/lib/freeclimb/models/{remove_from_conference_all_of.rb → sms_toll_free_campaigns_list_result_all_of.rb} +14 -16
  94. data/lib/freeclimb/models/start_record_call.rb +1 -0
  95. data/lib/freeclimb/models/terminate_conference.rb +4 -23
  96. data/lib/freeclimb/models/{terminate_conference_all_of.rb → tfn.rb} +15 -14
  97. data/lib/freeclimb/models/transcribe_utterance.rb +11 -16
  98. data/lib/freeclimb/models/transcribe_utterance_all_of.rb +281 -0
  99. data/lib/freeclimb/models/{transcribe_utterance_record.rb → transcribe_utterance_all_of_record.rb} +3 -7
  100. data/lib/freeclimb/models/unpark.rb +1 -0
  101. data/lib/freeclimb/models/update_conference_participant_request.rb +0 -2
  102. data/lib/freeclimb/models/update_conference_request.rb +0 -2
  103. data/lib/freeclimb/version.rb +1 -1
  104. data/lib/freeclimb.rb +8 -4
  105. data/openapi.json +407 -88
  106. data/package.json +8 -0
  107. data/spec/api/default_api_spec.rb +215 -55
  108. data/spec/models/account_request_spec.rb +8 -6
  109. data/spec/models/account_result_spec.rb +28 -9
  110. data/spec/models/add_to_conference_spec.rb +21 -37
  111. data/spec/models/application_list_spec.rb +46 -22
  112. data/spec/models/application_request_spec.rb +13 -6
  113. data/spec/models/application_result_spec.rb +24 -9
  114. data/spec/models/available_number_list_spec.rb +46 -22
  115. data/spec/models/available_number_spec.rb +23 -10
  116. data/spec/models/buy_incoming_number_request_spec.rb +11 -7
  117. data/spec/models/call_list_spec.rb +46 -22
  118. data/spec/models/call_result_spec.rb +49 -15
  119. data/spec/models/capabilities_spec.rb +26 -11
  120. data/spec/models/conference_list_spec.rb +46 -22
  121. data/spec/models/conference_participant_list_spec.rb +46 -22
  122. data/spec/models/conference_participant_result_spec.rb +24 -9
  123. data/spec/models/conference_result_spec.rb +32 -9
  124. data/spec/models/create_conference_request_spec.rb +15 -6
  125. data/spec/models/create_conference_spec.rb +19 -7
  126. data/spec/models/create_web_rtc_token_spec.rb +231 -0
  127. data/spec/models/enqueue_spec.rb +16 -9
  128. data/spec/models/filter_logs_request_spec.rb +9 -7
  129. data/spec/models/get_digits_spec.rb +59 -35
  130. data/spec/models/get_speech_spec.rb +60 -24
  131. data/spec/models/hangup_spec.rb +7 -6
  132. data/spec/models/incoming_number_list_spec.rb +46 -22
  133. data/spec/models/incoming_number_request_spec.rb +9 -6
  134. data/spec/models/incoming_number_result_spec.rb +68 -13
  135. data/spec/models/log_list_spec.rb +46 -22
  136. data/spec/models/log_result_spec.rb +21 -9
  137. data/spec/models/make_call_request_spec.rb +26 -11
  138. data/spec/models/message_request_spec.rb +49 -35
  139. data/spec/models/message_result_spec.rb +64 -11
  140. data/spec/models/messages_list_spec.rb +46 -22
  141. data/spec/models/mutable_resource_model_spec.rb +15 -9
  142. data/spec/models/out_dial_spec.rb +33 -13
  143. data/spec/models/pagination_model_spec.rb +40 -21
  144. data/spec/models/park_spec.rb +13 -8
  145. data/spec/models/pause_spec.rb +14 -10
  146. data/spec/models/percl_command_spec.rb +6 -6
  147. data/spec/models/percl_script_spec.rb +11 -6
  148. data/spec/models/play_early_media_spec.rb +9 -7
  149. data/spec/models/play_spec.rb +17 -40
  150. data/spec/models/queue_list_spec.rb +46 -22
  151. data/spec/models/queue_member_list_spec.rb +46 -22
  152. data/spec/models/queue_member_spec.rb +21 -12
  153. data/spec/models/queue_request_spec.rb +13 -9
  154. data/spec/models/queue_result_spec.rb +37 -18
  155. data/spec/models/record_utterance_spec.rb +28 -13
  156. data/spec/models/recording_list_spec.rb +46 -22
  157. data/spec/models/recording_result_spec.rb +25 -12
  158. data/spec/models/redirect_spec.rb +9 -7
  159. data/spec/models/reject_spec.rb +7 -6
  160. data/spec/models/remove_from_conference_spec.rb +0 -133
  161. data/spec/models/say_spec.rb +18 -40
  162. data/spec/models/send_digits_spec.rb +17 -10
  163. data/spec/models/set_listen_spec.rb +8 -37
  164. data/spec/models/set_talk_spec.rb +8 -37
  165. data/spec/models/sms_spec.rb +16 -9
  166. data/spec/models/sms_ten_dlc_brand_spec.rb +38 -4
  167. data/spec/models/sms_ten_dlc_brands_list_result_spec.rb +46 -22
  168. data/spec/models/sms_ten_dlc_campaign_spec.rb +228 -4
  169. data/spec/models/sms_ten_dlc_campaigns_list_result_spec.rb +46 -22
  170. data/spec/models/sms_ten_dlc_partner_campaign_brand_spec.rb +25 -7
  171. data/spec/models/sms_ten_dlc_partner_campaign_spec.rb +56 -8
  172. data/spec/models/sms_ten_dlc_partner_campaigns_list_result_spec.rb +46 -22
  173. data/spec/models/sms_toll_free_campaign_spec.rb +382 -0
  174. data/spec/models/sms_toll_free_campaigns_list_result_spec.rb +395 -0
  175. data/spec/models/terminate_conference_spec.rb +0 -133
  176. data/spec/models/tfn_spec.rb +164 -0
  177. data/spec/models/{transcribe_utterance_record_spec.rb → transcribe_utterance_all_of_record_spec.rb} +78 -67
  178. data/spec/models/transcribe_utterance_spec.rb +37 -96
  179. data/spec/models/update_call_request_spec.rb +12 -7
  180. data/spec/models/update_conference_participant_request_spec.rb +10 -6
  181. data/spec/models/update_conference_request_spec.rb +15 -6
  182. data/yarn.lock +1292 -0
  183. metadata +105 -84
@@ -0,0 +1,311 @@
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 SMSTollFreeCampaignsListResult
18
+ # Total amount of requested resource.
19
+ attr_accessor :total
20
+
21
+ # Resource index at start of current page
22
+ attr_accessor :start
23
+
24
+ # Resource index at end of current page
25
+ attr_accessor :_end
26
+
27
+ # Current page
28
+ attr_accessor :page
29
+
30
+ # Total number of pages
31
+ attr_accessor :num_pages
32
+
33
+ # Number of items per page
34
+ attr_accessor :page_size
35
+
36
+ # Uri to retrieve the next page of items
37
+ attr_accessor :next_page_uri
38
+
39
+ attr_accessor :brands
40
+
41
+ # Attribute mapping from ruby-style variable name to JSON key.
42
+ def self.attribute_map
43
+ {
44
+ :'total' => :'total',
45
+ :'start' => :'start',
46
+ :'_end' => :'end',
47
+ :'page' => :'page',
48
+ :'num_pages' => :'numPages',
49
+ :'page_size' => :'pageSize',
50
+ :'next_page_uri' => :'nextPageUri',
51
+ :'brands' => :'brands'
52
+ }
53
+ end
54
+
55
+ # Returns all the JSON keys this model knows about
56
+ def self.acceptable_attributes
57
+ attribute_map.values
58
+ end
59
+
60
+ # Attribute type mapping.
61
+ def self.openapi_types
62
+ {
63
+ :'total' => :'Integer',
64
+ :'start' => :'Integer',
65
+ :'_end' => :'Integer',
66
+ :'page' => :'Integer',
67
+ :'num_pages' => :'Integer',
68
+ :'page_size' => :'Integer',
69
+ :'next_page_uri' => :'String',
70
+ :'brands' => :'Array<SMSTollFreeCampaign>'
71
+ }
72
+ end
73
+
74
+ # List of attributes with nullable: true
75
+ def self.openapi_nullable
76
+ Set.new([
77
+ :'total',
78
+ :'start',
79
+ :'_end',
80
+ :'page',
81
+ :'num_pages',
82
+ :'page_size',
83
+ :'next_page_uri',
84
+ :'brands'
85
+ ])
86
+ end
87
+
88
+ # List of class defined in allOf (OpenAPI v3)
89
+ def self.openapi_all_of
90
+ [
91
+ :'PaginationModel',
92
+ :'SMSTollFreeCampaignsListResultAllOf'
93
+ ]
94
+ end
95
+
96
+ # Initializes the object
97
+ # @param [Hash] attributes Model attributes in the form of hash
98
+ def initialize(attributes = {})
99
+ if (!attributes.is_a?(Hash))
100
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Freeclimb::SMSTollFreeCampaignsListResult` initialize method"
101
+ end
102
+
103
+ # check to see if the attribute exists and convert string to symbol for hash key
104
+ attributes = attributes.each_with_object({}) { |(k, v), h|
105
+ if (!self.class.attribute_map.key?(k.to_sym))
106
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Freeclimb::SMSTollFreeCampaignsListResult`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
107
+ end
108
+ h[k.to_sym] = v
109
+ }
110
+
111
+ if attributes.key?(:'total')
112
+ self.total = attributes[:'total']
113
+ end
114
+
115
+ if attributes.key?(:'start')
116
+ self.start = attributes[:'start']
117
+ end
118
+
119
+ if attributes.key?(:'_end')
120
+ self._end = attributes[:'_end']
121
+ end
122
+
123
+ if attributes.key?(:'page')
124
+ self.page = attributes[:'page']
125
+ end
126
+
127
+ if attributes.key?(:'num_pages')
128
+ self.num_pages = attributes[:'num_pages']
129
+ end
130
+
131
+ if attributes.key?(:'page_size')
132
+ self.page_size = attributes[:'page_size']
133
+ end
134
+
135
+ if attributes.key?(:'next_page_uri')
136
+ self.next_page_uri = attributes[:'next_page_uri']
137
+ end
138
+
139
+ if attributes.key?(:'brands')
140
+ if (value = attributes[:'brands']).is_a?(Array)
141
+ self.brands = value
142
+ end
143
+ end
144
+ end
145
+
146
+ # Show invalid properties with the reasons. Usually used together with valid?
147
+ # @return Array for valid properties with the reasons
148
+ def list_invalid_properties
149
+ invalid_properties = Array.new
150
+ invalid_properties
151
+ end
152
+
153
+ # Check to see if the all the properties in the model are valid
154
+ # @return true if the model is valid
155
+ def valid?
156
+
157
+ if @total.nil?
158
+ false
159
+ else
160
+ list_invalid_properties.length() == 0
161
+ end
162
+ end
163
+
164
+ # Checks equality by comparing each attribute.
165
+ # @param [Object] Object to be compared
166
+ def ==(o)
167
+ return true if self.equal?(o)
168
+ self.class == o.class &&
169
+ total == o.total &&
170
+ start == o.start &&
171
+ _end == o._end &&
172
+ page == o.page &&
173
+ num_pages == o.num_pages &&
174
+ page_size == o.page_size &&
175
+ next_page_uri == o.next_page_uri &&
176
+ brands == o.brands
177
+ end
178
+
179
+ # @see the `==` method
180
+ # @param [Object] Object to be compared
181
+ def eql?(o)
182
+ self == o
183
+ end
184
+
185
+ # Calculates hash code according to all attributes.
186
+ # @return [Integer] Hash code
187
+ def hash
188
+ [total, start, _end, page, num_pages, page_size, next_page_uri, brands].hash
189
+ end
190
+
191
+ # Builds the object from hash
192
+ # @param [Hash] attributes Model attributes in the form of hash
193
+ # @return [Object] Returns the model itself
194
+ def self.build_from_hash(attributes)
195
+ new.build_from_hash(attributes)
196
+ end
197
+
198
+ # Builds the object from hash
199
+ # @param [Hash] attributes Model attributes in the form of hash
200
+ # @return [Object] Returns the model itself
201
+ def build_from_hash(attributes)
202
+ return nil unless attributes.is_a?(Hash)
203
+ self.class.openapi_types.each_pair do |key, type|
204
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
205
+ self.send("#{key}=", nil)
206
+ elsif type =~ /\AArray<(.*)>/i
207
+ # check to ensure the input is an array given that the attribute
208
+ # is documented as an array but the input is not
209
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
210
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
211
+ end
212
+ elsif !attributes[self.class.attribute_map[key]].nil?
213
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
214
+ end
215
+ end
216
+
217
+ self
218
+ end
219
+
220
+ # Deserializes the data based on type
221
+ # @param string type Data type
222
+ # @param string value Value to be deserialized
223
+ # @return [Object] Deserialized data
224
+ def _deserialize(type, value)
225
+ case type.to_sym
226
+ when :Time
227
+ Time.parse(value)
228
+ when :Date
229
+ Date.parse(value)
230
+ when :String
231
+ value.to_s
232
+ when :Integer
233
+ value.to_i
234
+ when :Float
235
+ value.to_f
236
+ when :Boolean
237
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
238
+ true
239
+ else
240
+ false
241
+ end
242
+ when :Object
243
+ # generic object (usually a Hash), return directly
244
+ value
245
+ when /\AArray<(?<inner_type>.+)>\z/
246
+ inner_type = Regexp.last_match[:inner_type]
247
+ value.map { |v| _deserialize(inner_type, v) }
248
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
249
+ k_type = Regexp.last_match[:k_type]
250
+ v_type = Regexp.last_match[:v_type]
251
+ {}.tap do |hash|
252
+ value.each do |k, v|
253
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
254
+ end
255
+ end
256
+ else # model
257
+ # models (e.g. Pet) or oneOf
258
+ klass = Freeclimb.const_get(type)
259
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
260
+ end
261
+ end
262
+
263
+ # Returns the string representation of the object
264
+ # @return [String] String presentation of the object
265
+ def to_s
266
+ to_hash.to_s
267
+ end
268
+
269
+ # to_body is an alias to to_hash (backward compatibility)
270
+ # @return [Hash] Returns the object in the form of hash
271
+ def to_body
272
+ to_hash
273
+ end
274
+
275
+ # Returns the object in the form of hash
276
+ # @return [Hash] Returns the object in the form of hash
277
+ def to_hash
278
+ hash = {}
279
+ self.class.attribute_map.each_pair do |attr, param|
280
+ value = self.send(attr)
281
+ if value.nil?
282
+ is_nullable = self.class.openapi_nullable.include?(attr)
283
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
284
+ end
285
+
286
+ hash[param] = _to_hash(value)
287
+ end
288
+ hash
289
+ end
290
+
291
+ # Outputs non-array value in the form of hash
292
+ # For object, use to_hash. Otherwise, just return the value
293
+ # @param [Object] value Any valid value
294
+ # @return [Hash] Returns the value in the form of hash
295
+ def _to_hash(value)
296
+ if value.is_a?(Array)
297
+ value.compact.map { |v| _to_hash(v) }
298
+ elsif value.is_a?(Hash)
299
+ {}.tap do |hash|
300
+ value.each { |k, v| hash[k] = _to_hash(v) }
301
+ end
302
+ elsif value.respond_to? :to_hash
303
+ value.to_hash
304
+ else
305
+ value
306
+ end
307
+ end
308
+
309
+ end
310
+
311
+ end
@@ -14,14 +14,13 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Freeclimb
17
- class RemoveFromConferenceAllOf
18
- # ID of the Call leg to be removed from the Conference. The Call must be in a Conference or an error will be triggered.
19
- attr_accessor :call_id
17
+ class SMSTollFreeCampaignsListResultAllOf
18
+ attr_accessor :brands
20
19
 
21
20
  # Attribute mapping from ruby-style variable name to JSON key.
22
21
  def self.attribute_map
23
22
  {
24
- :'call_id' => :'callId'
23
+ :'brands' => :'brands'
25
24
  }
26
25
  end
27
26
 
@@ -33,13 +32,14 @@ module Freeclimb
33
32
  # Attribute type mapping.
34
33
  def self.openapi_types
35
34
  {
36
- :'call_id' => :'String'
35
+ :'brands' => :'Array<SMSTollFreeCampaign>'
37
36
  }
38
37
  end
39
38
 
40
39
  # List of attributes with nullable: true
41
40
  def self.openapi_nullable
42
41
  Set.new([
42
+ :'brands'
43
43
  ])
44
44
  end
45
45
 
@@ -47,19 +47,21 @@ module Freeclimb
47
47
  # @param [Hash] attributes Model attributes in the form of hash
48
48
  def initialize(attributes = {})
49
49
  if (!attributes.is_a?(Hash))
50
- fail ArgumentError, "The input argument (attributes) must be a hash in `Freeclimb::RemoveFromConferenceAllOf` initialize method"
50
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Freeclimb::SMSTollFreeCampaignsListResultAllOf` initialize method"
51
51
  end
52
52
 
53
53
  # check to see if the attribute exists and convert string to symbol for hash key
54
54
  attributes = attributes.each_with_object({}) { |(k, v), h|
55
55
  if (!self.class.attribute_map.key?(k.to_sym))
56
- fail ArgumentError, "`#{k}` is not a valid attribute in `Freeclimb::RemoveFromConferenceAllOf`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Freeclimb::SMSTollFreeCampaignsListResultAllOf`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
57
57
  end
58
58
  h[k.to_sym] = v
59
59
  }
60
60
 
61
- if attributes.key?(:'call_id')
62
- self.call_id = attributes[:'call_id']
61
+ if attributes.key?(:'brands')
62
+ if (value = attributes[:'brands']).is_a?(Array)
63
+ self.brands = value
64
+ end
63
65
  end
64
66
  end
65
67
 
@@ -67,10 +69,6 @@ module Freeclimb
67
69
  # @return Array for valid properties with the reasons
68
70
  def list_invalid_properties
69
71
  invalid_properties = Array.new
70
- if @call_id.nil?
71
- invalid_properties.push('invalid value for "call_id", call_id cannot be nil.')
72
- end
73
-
74
72
  invalid_properties
75
73
  end
76
74
 
@@ -78,7 +76,7 @@ module Freeclimb
78
76
  # @return true if the model is valid
79
77
  def valid?
80
78
 
81
- if @call_id.nil?
79
+ if @brands.nil?
82
80
  false
83
81
  else
84
82
  list_invalid_properties.length() == 0
@@ -90,7 +88,7 @@ module Freeclimb
90
88
  def ==(o)
91
89
  return true if self.equal?(o)
92
90
  self.class == o.class &&
93
- call_id == o.call_id
91
+ brands == o.brands
94
92
  end
95
93
 
96
94
  # @see the `==` method
@@ -102,7 +100,7 @@ module Freeclimb
102
100
  # Calculates hash code according to all attributes.
103
101
  # @return [Integer] Hash code
104
102
  def hash
105
- [call_id].hash
103
+ [brands].hash
106
104
  end
107
105
 
108
106
  # Builds the object from hash
@@ -77,6 +77,7 @@ module Freeclimb
77
77
  # @return true if the model is valid
78
78
  def valid?
79
79
 
80
+ true
80
81
  end
81
82
 
82
83
  # Checks equality by comparing each attribute.
@@ -16,13 +16,9 @@ require 'time'
16
16
  module Freeclimb
17
17
  # The `TerminateConference` command terminates an existing Conference. Any active participants are hung up on by FreeClimb. If this is not the desired behavior, use the `RemoveFromConference` command to unbridge Calls that should not be hung up. Note: The Call requesting TerminateConference must be on the same Conference for this command to execute.
18
18
  class TerminateConference < PerclCommand
19
- # ID of the conference to terminate.
20
- attr_accessor :conference_id
21
-
22
19
  # Attribute mapping from ruby-style variable name to JSON key.
23
20
  def self.attribute_map
24
21
  {
25
- :'conference_id' => :'conferenceId'
26
22
  }
27
23
  end
28
24
 
@@ -34,7 +30,6 @@ module Freeclimb
34
30
  # Attribute type mapping.
35
31
  def self.openapi_types
36
32
  {
37
- :'conference_id' => :'String'
38
33
  }
39
34
  end
40
35
 
@@ -47,8 +42,7 @@ module Freeclimb
47
42
  # List of class defined in allOf (OpenAPI v3)
48
43
  def self.openapi_all_of
49
44
  [
50
- :'PerclCommand',
51
- :'TerminateConferenceAllOf'
45
+ :'PerclCommand'
52
46
  ]
53
47
  end
54
48
 
@@ -69,10 +63,6 @@ module Freeclimb
69
63
 
70
64
  # call parent's initialize
71
65
  super(attributes)
72
-
73
- if attributes.key?(:'conference_id')
74
- self.conference_id = attributes[:'conference_id']
75
- end
76
66
  self.command = "TerminateConference"
77
67
  end
78
68
 
@@ -80,10 +70,6 @@ module Freeclimb
80
70
  # @return Array for valid properties with the reasons
81
71
  def list_invalid_properties
82
72
  invalid_properties = super
83
- if @conference_id.nil?
84
- invalid_properties.push('invalid value for "conference_id", conference_id cannot be nil.')
85
- end
86
-
87
73
  invalid_properties
88
74
  end
89
75
 
@@ -91,19 +77,14 @@ module Freeclimb
91
77
  # @return true if the model is valid
92
78
  def valid?
93
79
 
94
- if @conference_id.nil?
95
- false
96
- else
97
- list_invalid_properties.length() == 0
98
- end
80
+ true
99
81
  end
100
82
 
101
83
  # Checks equality by comparing each attribute.
102
84
  # @param [Object] Object to be compared
103
85
  def ==(o)
104
86
  return true if self.equal?(o)
105
- self.class == o.class &&
106
- conference_id == o.conference_id && super(o)
87
+ self.class == o.class && super(o)
107
88
  end
108
89
 
109
90
  # @see the `==` method
@@ -115,7 +96,7 @@ module Freeclimb
115
96
  # Calculates hash code according to all attributes.
116
97
  # @return [Integer] Hash code
117
98
  def hash
118
- [conference_id].hash
99
+ [].hash
119
100
  end
120
101
 
121
102
  # Builds the object from hash
@@ -14,14 +14,15 @@ require 'date'
14
14
  require 'time'
15
15
 
16
16
  module Freeclimb
17
- class TerminateConferenceAllOf
18
- # ID of the conference to terminate.
19
- attr_accessor :conference_id
17
+ # TollFree Campaign details for this number
18
+ class TFN
19
+ # alphanumeric identifier for the TollFree campaign associated with this number
20
+ attr_accessor :campaign_id
20
21
 
21
22
  # Attribute mapping from ruby-style variable name to JSON key.
22
23
  def self.attribute_map
23
24
  {
24
- :'conference_id' => :'conferenceId'
25
+ :'campaign_id' => :'campaignId'
25
26
  }
26
27
  end
27
28
 
@@ -33,7 +34,7 @@ module Freeclimb
33
34
  # Attribute type mapping.
34
35
  def self.openapi_types
35
36
  {
36
- :'conference_id' => :'String'
37
+ :'campaign_id' => :'String'
37
38
  }
38
39
  end
39
40
 
@@ -47,19 +48,19 @@ module Freeclimb
47
48
  # @param [Hash] attributes Model attributes in the form of hash
48
49
  def initialize(attributes = {})
49
50
  if (!attributes.is_a?(Hash))
50
- fail ArgumentError, "The input argument (attributes) must be a hash in `Freeclimb::TerminateConferenceAllOf` initialize method"
51
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Freeclimb::TFN` initialize method"
51
52
  end
52
53
 
53
54
  # check to see if the attribute exists and convert string to symbol for hash key
54
55
  attributes = attributes.each_with_object({}) { |(k, v), h|
55
56
  if (!self.class.attribute_map.key?(k.to_sym))
56
- fail ArgumentError, "`#{k}` is not a valid attribute in `Freeclimb::TerminateConferenceAllOf`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
57
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Freeclimb::TFN`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
57
58
  end
58
59
  h[k.to_sym] = v
59
60
  }
60
61
 
61
- if attributes.key?(:'conference_id')
62
- self.conference_id = attributes[:'conference_id']
62
+ if attributes.key?(:'campaign_id')
63
+ self.campaign_id = attributes[:'campaign_id']
63
64
  end
64
65
  end
65
66
 
@@ -67,8 +68,8 @@ module Freeclimb
67
68
  # @return Array for valid properties with the reasons
68
69
  def list_invalid_properties
69
70
  invalid_properties = Array.new
70
- if @conference_id.nil?
71
- invalid_properties.push('invalid value for "conference_id", conference_id cannot be nil.')
71
+ if @campaign_id.nil?
72
+ invalid_properties.push('invalid value for "campaign_id", campaign_id cannot be nil.')
72
73
  end
73
74
 
74
75
  invalid_properties
@@ -78,7 +79,7 @@ module Freeclimb
78
79
  # @return true if the model is valid
79
80
  def valid?
80
81
 
81
- if @conference_id.nil?
82
+ if @campaign_id.nil?
82
83
  false
83
84
  else
84
85
  list_invalid_properties.length() == 0
@@ -90,7 +91,7 @@ module Freeclimb
90
91
  def ==(o)
91
92
  return true if self.equal?(o)
92
93
  self.class == o.class &&
93
- conference_id == o.conference_id
94
+ campaign_id == o.campaign_id
94
95
  end
95
96
 
96
97
  # @see the `==` method
@@ -102,7 +103,7 @@ module Freeclimb
102
103
  # Calculates hash code according to all attributes.
103
104
  # @return [Integer] Hash code
104
105
  def hash
105
- [conference_id].hash
106
+ [campaign_id].hash
106
107
  end
107
108
 
108
109
  # Builds the object from hash
@@ -40,9 +40,9 @@ module Freeclimb
40
40
  }
41
41
  end
42
42
 
43
- # Returns all the JSON keys this model knows about
43
+ # Returns all the JSON keys this model knows about, including the ones defined in its parent(s)
44
44
  def self.acceptable_attributes
45
- attribute_map.values
45
+ attribute_map.values.concat(superclass.acceptable_attributes)
46
46
  end
47
47
 
48
48
  # Attribute type mapping.
@@ -50,7 +50,7 @@ module Freeclimb
50
50
  {
51
51
  :'action_url' => :'String',
52
52
  :'play_beep' => :'Boolean',
53
- :'record' => :'TranscribeUtteranceRecord',
53
+ :'record' => :'TranscribeUtteranceAllOfRecord',
54
54
  :'privacy_for_logging' => :'Boolean',
55
55
  :'privacy_for_recording' => :'Boolean',
56
56
  :'prompts' => :'Array<Object>'
@@ -66,7 +66,8 @@ module Freeclimb
66
66
  # List of class defined in allOf (OpenAPI v3)
67
67
  def self.openapi_all_of
68
68
  [
69
- :'PerclCommand'
69
+ :'PerclCommand',
70
+ :'TranscribeUtteranceAllOf'
70
71
  ]
71
72
  end
72
73
 
@@ -85,6 +86,9 @@ module Freeclimb
85
86
  h[k.to_sym] = v
86
87
  }
87
88
 
89
+ # call parent's initialize
90
+ super(attributes)
91
+
88
92
  if attributes.key?(:'action_url')
89
93
  self.action_url = attributes[:'action_url']
90
94
  end
@@ -122,7 +126,7 @@ module Freeclimb
122
126
  # Show invalid properties with the reasons. Usually used together with valid?
123
127
  # @return Array for valid properties with the reasons
124
128
  def list_invalid_properties
125
- invalid_properties = Array.new
129
+ invalid_properties = super
126
130
  if @action_url.nil?
127
131
  invalid_properties.push('invalid value for "action_url", action_url cannot be nil.')
128
132
  end
@@ -136,16 +140,6 @@ module Freeclimb
136
140
 
137
141
  if @action_url.nil?
138
142
  false
139
- elsif @play_beep.nil?
140
- false
141
- elsif @record.nil?
142
- false
143
- elsif @privacy_for_logging.nil?
144
- false
145
- elsif @privacy_for_recording.nil?
146
- false
147
- elsif @prompts.nil?
148
- false
149
143
  else
150
144
  list_invalid_properties.length() == 0
151
145
  end
@@ -161,7 +155,7 @@ module Freeclimb
161
155
  record == o.record &&
162
156
  privacy_for_logging == o.privacy_for_logging &&
163
157
  privacy_for_recording == o.privacy_for_recording &&
164
- prompts == o.prompts
158
+ prompts == o.prompts && super(o)
165
159
  end
166
160
 
167
161
  # @see the `==` method
@@ -188,6 +182,7 @@ module Freeclimb
188
182
  # @return [Object] Returns the model itself
189
183
  def build_from_hash(attributes)
190
184
  return nil unless attributes.is_a?(Hash)
185
+ super(attributes)
191
186
  self.class.openapi_types.each_pair do |key, type|
192
187
  if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
193
188
  self.send("#{key}=", nil)