purecloudplatformclientv2 11.0.0 → 12.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +2 -2
  3. data/docs/CallbackConversationNotificationCallbackMediaParticipant.md +1 -1
  4. data/docs/CallbackConversationNotificationParticipants.md +1 -1
  5. data/docs/CallbackConversationNotificationVoicemail.md +1 -0
  6. data/docs/ConversationNotificationCallback.md +1 -1
  7. data/docs/ConversationNotificationCallbacks.md +1 -1
  8. data/docs/ConversationNotificationVoicemail.md +1 -0
  9. data/docs/RuleSetNotificationCondition.md +2 -0
  10. data/docs/RuleSetNotificationConditions.md +2 -0
  11. data/docs/StatsNotificationNotification.md +14 -0
  12. data/docs/StatsNotificationNotificationData.md +14 -0
  13. data/docs/StatsNotificationNotificationDatum.md +14 -0
  14. data/docs/StatsNotificationNotificationMetric.md +15 -0
  15. data/docs/StatsNotificationNotificationMetrics.md +15 -0
  16. data/docs/WfmHistoricalAdherenceCalculationsCompleteNoticeNotification.md +15 -0
  17. data/lib/purecloudplatformclientv2.rb +6 -0
  18. data/lib/purecloudplatformclientv2/models/callback_conversation_notification_callback_media_participant.rb +1 -1
  19. data/lib/purecloudplatformclientv2/models/callback_conversation_notification_participants.rb +1 -1
  20. data/lib/purecloudplatformclientv2/models/callback_conversation_notification_voicemail.rb +43 -4
  21. data/lib/purecloudplatformclientv2/models/conversation_notification_callback.rb +3 -3
  22. data/lib/purecloudplatformclientv2/models/conversation_notification_callbacks.rb +3 -3
  23. data/lib/purecloudplatformclientv2/models/conversation_notification_voicemail.rb +43 -4
  24. data/lib/purecloudplatformclientv2/models/flow_notification_notification_architect_operation.rb +2 -2
  25. data/lib/purecloudplatformclientv2/models/prompt_notification_notification_architect_operation.rb +2 -2
  26. data/lib/purecloudplatformclientv2/models/prompt_notification_notification_current_operation.rb +2 -2
  27. data/lib/purecloudplatformclientv2/models/rule_set_notification_condition.rb +65 -1
  28. data/lib/purecloudplatformclientv2/models/rule_set_notification_conditions.rb +65 -1
  29. data/lib/purecloudplatformclientv2/models/stats_notification_notification.rb +230 -0
  30. data/lib/purecloudplatformclientv2/models/stats_notification_notification_data.rb +228 -0
  31. data/lib/purecloudplatformclientv2/models/stats_notification_notification_datum.rb +228 -0
  32. data/lib/purecloudplatformclientv2/models/stats_notification_notification_metric.rb +253 -0
  33. data/lib/purecloudplatformclientv2/models/stats_notification_notification_metrics.rb +253 -0
  34. data/lib/purecloudplatformclientv2/models/wfm_historical_adherence_calculations_complete_notice_notification.rb +265 -0
  35. data/lib/purecloudplatformclientv2/version.rb +1 -1
  36. metadata +14 -2
@@ -0,0 +1,253 @@
1
+ =begin
2
+ PureCloud Platform API
3
+
4
+ With the PureCloud Platform API, you can control all aspects of your PureCloud environment. With the APIs you can access the system configuration, manage conversations and more.
5
+
6
+ OpenAPI spec version: v2
7
+ Contact: DeveloperEvangelists@genesys.com
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+
10
+ License: ININ
11
+ http://www.inin.com
12
+
13
+ Terms of Service: https://developer.mypurecloud.com/tos
14
+
15
+ =end
16
+
17
+ require 'date'
18
+
19
+ module PureCloud
20
+ class StatsNotificationNotificationMetric
21
+ attr_accessor :metric
22
+
23
+ attr_accessor :qualifier
24
+
25
+ attr_accessor :stats
26
+
27
+ # Attribute mapping from ruby-style variable name to JSON key.
28
+ def self.attribute_map
29
+ {
30
+
31
+ :'metric' => :'metric',
32
+
33
+ :'qualifier' => :'qualifier',
34
+
35
+ :'stats' => :'stats'
36
+
37
+ }
38
+ end
39
+
40
+ # Attribute type mapping.
41
+ def self.swagger_types
42
+ {
43
+
44
+ :'metric' => :'String',
45
+
46
+ :'qualifier' => :'String',
47
+
48
+ :'stats' => :'Hash<String, Float>'
49
+
50
+ }
51
+ end
52
+
53
+ # Initializes the object
54
+ # @param [Hash] attributes Model attributes in the form of hash
55
+ def initialize(attributes = {})
56
+ return unless attributes.is_a?(Hash)
57
+
58
+ # convert string to symbol for hash key
59
+ attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
60
+
61
+
62
+ if attributes.has_key?(:'metric')
63
+
64
+
65
+ self.metric = attributes[:'metric']
66
+
67
+
68
+ end
69
+
70
+
71
+ if attributes.has_key?(:'qualifier')
72
+
73
+
74
+ self.qualifier = attributes[:'qualifier']
75
+
76
+
77
+ end
78
+
79
+
80
+ if attributes.has_key?(:'stats')
81
+
82
+ if (value = attributes[:'stats']).is_a?(Array)
83
+ self.stats = value
84
+ end
85
+
86
+
87
+
88
+ end
89
+
90
+
91
+ end
92
+
93
+ # Show invalid properties with the reasons. Usually used together with valid?
94
+ # @return Array for valid properies with the reasons
95
+ def list_invalid_properties
96
+ invalid_properties = Array.new
97
+
98
+
99
+ return invalid_properties
100
+ end
101
+
102
+ # Check to see if the all the properties in the model are valid
103
+ # @return true if the model is valid
104
+ def valid?
105
+
106
+
107
+
108
+
109
+
110
+
111
+
112
+
113
+
114
+
115
+
116
+
117
+
118
+ end
119
+
120
+
121
+
122
+
123
+
124
+
125
+
126
+
127
+
128
+
129
+
130
+
131
+
132
+
133
+
134
+
135
+
136
+ # Checks equality by comparing each attribute.
137
+ # @param [Object] Object to be compared
138
+ def ==(o)
139
+ return true if self.equal?(o)
140
+ self.class == o.class &&
141
+ metric == o.metric &&
142
+ qualifier == o.qualifier &&
143
+ stats == o.stats
144
+ end
145
+
146
+ # @see the `==` method
147
+ # @param [Object] Object to be compared
148
+ def eql?(o)
149
+ self == o
150
+ end
151
+
152
+ # Calculates hash code according to all attributes.
153
+ # @return [Fixnum] Hash code
154
+ def hash
155
+ [metric, qualifier, stats].hash
156
+ end
157
+
158
+ # build the object from hash
159
+ def build_from_hash(attributes)
160
+ return nil unless attributes.is_a?(Hash)
161
+ self.class.swagger_types.each_pair do |key, type|
162
+ if type =~ /^Array<(.*)>/i
163
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
164
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
165
+ else
166
+ #TODO show warning in debug mode
167
+ end
168
+ elsif !attributes[self.class.attribute_map[key]].nil?
169
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
170
+ else
171
+ # data not found in attributes(hash), not an issue as the data can be optional
172
+ end
173
+ end
174
+
175
+ self
176
+ end
177
+
178
+ def _deserialize(type, value)
179
+ case type.to_sym
180
+ when :DateTime
181
+ DateTime.parse(value)
182
+ when :Date
183
+ Date.parse(value)
184
+ when :String
185
+ value.to_s
186
+ when :Integer
187
+ value.to_i
188
+ when :Float
189
+ value.to_f
190
+ when :BOOLEAN
191
+ if value.to_s =~ /^(true|t|yes|y|1)$/i
192
+ true
193
+ else
194
+ false
195
+ end
196
+ when :Object
197
+ # generic object (usually a Hash), return directly
198
+ value
199
+ when /\AArray<(?<inner_type>.+)>\z/
200
+ inner_type = Regexp.last_match[:inner_type]
201
+ value.map { |v| _deserialize(inner_type, v) }
202
+ when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
203
+ k_type = Regexp.last_match[:k_type]
204
+ v_type = Regexp.last_match[:v_type]
205
+ {}.tap do |hash|
206
+ value.each do |k, v|
207
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
208
+ end
209
+ end
210
+ else # model
211
+ _model = Object.const_get("PureCloud").const_get(type).new
212
+ _model.build_from_hash(value)
213
+ end
214
+ end
215
+
216
+ def to_s
217
+ to_hash.to_s
218
+ end
219
+
220
+ # to_body is an alias to to_body (backward compatibility))
221
+ def to_body
222
+ to_hash
223
+ end
224
+
225
+ # return the object in the form of hash
226
+ def to_hash
227
+ hash = {}
228
+ self.class.attribute_map.each_pair do |attr, param|
229
+ value = self.send(attr)
230
+ next if value.nil?
231
+ hash[param] = _to_hash(value)
232
+ end
233
+ hash
234
+ end
235
+
236
+ # Method to output non-array value in the form of hash
237
+ # For object, use to_hash. Otherwise, just return the value
238
+ def _to_hash(value)
239
+ if value.is_a?(Array)
240
+ value.compact.map{ |v| _to_hash(v) }
241
+ elsif value.is_a?(Hash)
242
+ {}.tap do |hash|
243
+ value.each { |k, v| hash[k] = _to_hash(v) }
244
+ end
245
+ elsif value.respond_to? :to_hash
246
+ value.to_hash
247
+ else
248
+ value
249
+ end
250
+ end
251
+
252
+ end
253
+ end
@@ -0,0 +1,253 @@
1
+ =begin
2
+ PureCloud Platform API
3
+
4
+ With the PureCloud Platform API, you can control all aspects of your PureCloud environment. With the APIs you can access the system configuration, manage conversations and more.
5
+
6
+ OpenAPI spec version: v2
7
+ Contact: DeveloperEvangelists@genesys.com
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+
10
+ License: ININ
11
+ http://www.inin.com
12
+
13
+ Terms of Service: https://developer.mypurecloud.com/tos
14
+
15
+ =end
16
+
17
+ require 'date'
18
+
19
+ module PureCloud
20
+ class StatsNotificationNotificationMetrics
21
+ attr_accessor :metric
22
+
23
+ attr_accessor :qualifier
24
+
25
+ attr_accessor :stats
26
+
27
+ # Attribute mapping from ruby-style variable name to JSON key.
28
+ def self.attribute_map
29
+ {
30
+
31
+ :'metric' => :'metric',
32
+
33
+ :'qualifier' => :'qualifier',
34
+
35
+ :'stats' => :'stats'
36
+
37
+ }
38
+ end
39
+
40
+ # Attribute type mapping.
41
+ def self.swagger_types
42
+ {
43
+
44
+ :'metric' => :'String',
45
+
46
+ :'qualifier' => :'String',
47
+
48
+ :'stats' => :'Hash<String, Float>'
49
+
50
+ }
51
+ end
52
+
53
+ # Initializes the object
54
+ # @param [Hash] attributes Model attributes in the form of hash
55
+ def initialize(attributes = {})
56
+ return unless attributes.is_a?(Hash)
57
+
58
+ # convert string to symbol for hash key
59
+ attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
60
+
61
+
62
+ if attributes.has_key?(:'metric')
63
+
64
+
65
+ self.metric = attributes[:'metric']
66
+
67
+
68
+ end
69
+
70
+
71
+ if attributes.has_key?(:'qualifier')
72
+
73
+
74
+ self.qualifier = attributes[:'qualifier']
75
+
76
+
77
+ end
78
+
79
+
80
+ if attributes.has_key?(:'stats')
81
+
82
+ if (value = attributes[:'stats']).is_a?(Array)
83
+ self.stats = value
84
+ end
85
+
86
+
87
+
88
+ end
89
+
90
+
91
+ end
92
+
93
+ # Show invalid properties with the reasons. Usually used together with valid?
94
+ # @return Array for valid properies with the reasons
95
+ def list_invalid_properties
96
+ invalid_properties = Array.new
97
+
98
+
99
+ return invalid_properties
100
+ end
101
+
102
+ # Check to see if the all the properties in the model are valid
103
+ # @return true if the model is valid
104
+ def valid?
105
+
106
+
107
+
108
+
109
+
110
+
111
+
112
+
113
+
114
+
115
+
116
+
117
+
118
+ end
119
+
120
+
121
+
122
+
123
+
124
+
125
+
126
+
127
+
128
+
129
+
130
+
131
+
132
+
133
+
134
+
135
+
136
+ # Checks equality by comparing each attribute.
137
+ # @param [Object] Object to be compared
138
+ def ==(o)
139
+ return true if self.equal?(o)
140
+ self.class == o.class &&
141
+ metric == o.metric &&
142
+ qualifier == o.qualifier &&
143
+ stats == o.stats
144
+ end
145
+
146
+ # @see the `==` method
147
+ # @param [Object] Object to be compared
148
+ def eql?(o)
149
+ self == o
150
+ end
151
+
152
+ # Calculates hash code according to all attributes.
153
+ # @return [Fixnum] Hash code
154
+ def hash
155
+ [metric, qualifier, stats].hash
156
+ end
157
+
158
+ # build the object from hash
159
+ def build_from_hash(attributes)
160
+ return nil unless attributes.is_a?(Hash)
161
+ self.class.swagger_types.each_pair do |key, type|
162
+ if type =~ /^Array<(.*)>/i
163
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
164
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
165
+ else
166
+ #TODO show warning in debug mode
167
+ end
168
+ elsif !attributes[self.class.attribute_map[key]].nil?
169
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
170
+ else
171
+ # data not found in attributes(hash), not an issue as the data can be optional
172
+ end
173
+ end
174
+
175
+ self
176
+ end
177
+
178
+ def _deserialize(type, value)
179
+ case type.to_sym
180
+ when :DateTime
181
+ DateTime.parse(value)
182
+ when :Date
183
+ Date.parse(value)
184
+ when :String
185
+ value.to_s
186
+ when :Integer
187
+ value.to_i
188
+ when :Float
189
+ value.to_f
190
+ when :BOOLEAN
191
+ if value.to_s =~ /^(true|t|yes|y|1)$/i
192
+ true
193
+ else
194
+ false
195
+ end
196
+ when :Object
197
+ # generic object (usually a Hash), return directly
198
+ value
199
+ when /\AArray<(?<inner_type>.+)>\z/
200
+ inner_type = Regexp.last_match[:inner_type]
201
+ value.map { |v| _deserialize(inner_type, v) }
202
+ when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
203
+ k_type = Regexp.last_match[:k_type]
204
+ v_type = Regexp.last_match[:v_type]
205
+ {}.tap do |hash|
206
+ value.each do |k, v|
207
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
208
+ end
209
+ end
210
+ else # model
211
+ _model = Object.const_get("PureCloud").const_get(type).new
212
+ _model.build_from_hash(value)
213
+ end
214
+ end
215
+
216
+ def to_s
217
+ to_hash.to_s
218
+ end
219
+
220
+ # to_body is an alias to to_body (backward compatibility))
221
+ def to_body
222
+ to_hash
223
+ end
224
+
225
+ # return the object in the form of hash
226
+ def to_hash
227
+ hash = {}
228
+ self.class.attribute_map.each_pair do |attr, param|
229
+ value = self.send(attr)
230
+ next if value.nil?
231
+ hash[param] = _to_hash(value)
232
+ end
233
+ hash
234
+ end
235
+
236
+ # Method to output non-array value in the form of hash
237
+ # For object, use to_hash. Otherwise, just return the value
238
+ def _to_hash(value)
239
+ if value.is_a?(Array)
240
+ value.compact.map{ |v| _to_hash(v) }
241
+ elsif value.is_a?(Hash)
242
+ {}.tap do |hash|
243
+ value.each { |k, v| hash[k] = _to_hash(v) }
244
+ end
245
+ elsif value.respond_to? :to_hash
246
+ value.to_hash
247
+ else
248
+ value
249
+ end
250
+ end
251
+
252
+ end
253
+ end