purecloud 0.59.1 → 0.60.1

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 (256) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +3 -3
  3. data/config-ruby.json +1 -1
  4. data/doc_out/AgentActivityEntityListing.html.md +2 -2
  5. data/doc_out/AggregationQuery.html.md +1 -1
  6. data/doc_out/AlertingApi.html.md +1106 -92
  7. data/doc_out/Annotation.html.md +14 -4
  8. data/doc_out/AttemptLimitsEntityListing.html.md +2 -2
  9. data/doc_out/AttributeEntityListing.html.md +2 -2
  10. data/doc_out/CalibrationEntityListing.html.md +2 -2
  11. data/doc_out/CallConversationEntityListing.html.md +2 -2
  12. data/doc_out/CallableTimeSetEntityListing.html.md +2 -2
  13. data/doc_out/CallbackConversationEntityListing.html.md +2 -2
  14. data/doc_out/CampaignEntityListing.html.md +2 -2
  15. data/doc_out/CampaignSequenceEntityListing.html.md +2 -2
  16. data/doc_out/CertificateAuthorityEntityListing.html.md +2 -2
  17. data/doc_out/ChannelEntityListing.html.md +2 -2
  18. data/doc_out/ChatConversationEntityListing.html.md +2 -2
  19. data/doc_out/CobrowseConversationEntityListing.html.md +2 -2
  20. data/doc_out/CommandStatusEntityListing.html.md +2 -2
  21. data/doc_out/ContactListEntityListing.html.md +2 -2
  22. data/doc_out/ContactSort.html.md +1 -1
  23. data/doc_out/ConversationEntityListing.html.md +2 -2
  24. data/doc_out/DIDEntityListing.html.md +2 -2
  25. data/doc_out/DIDPoolEntityListing.html.md +2 -2
  26. data/doc_out/DncListEntityListing.html.md +2 -2
  27. data/doc_out/DocumentAuditEntityListing.html.md +2 -2
  28. data/doc_out/DocumentEntityListing.html.md +2 -2
  29. data/doc_out/DomainEdgeSoftwareVersionDtoEntityListing.html.md +2 -2
  30. data/doc_out/DomainEntityListing.html.md +2 -2
  31. data/doc_out/DomainEntityListingEvaluationForm.html.md +2 -2
  32. data/doc_out/DomainEntityListingQueryResult.html.md +2 -2
  33. data/doc_out/Edge.html.md +1 -1
  34. data/doc_out/EdgeEntityListing.html.md +2 -2
  35. data/doc_out/EdgeGroupEntityListing.html.md +2 -2
  36. data/doc_out/EdgeLineEntityListing.html.md +2 -2
  37. data/doc_out/EmailConversationEntityListing.html.md +2 -2
  38. data/doc_out/EmailMessageListing.html.md +2 -2
  39. data/doc_out/EncryptionKeyEntityListing.html.md +2 -2
  40. data/doc_out/EndpointEntityListing.html.md +2 -2
  41. data/doc_out/EvaluationEntityListing.html.md +2 -2
  42. data/doc_out/EvaluationFormEntityListing.html.md +2 -2
  43. data/doc_out/EvaluatorActivityEntityListing.html.md +2 -2
  44. data/doc_out/ExtensionEntityListing.html.md +2 -2
  45. data/doc_out/ExtensionPoolEntityListing.html.md +2 -2
  46. data/doc_out/FaxDocumentEntityListing.html.md +2 -2
  47. data/doc_out/GroupEntityListing.html.md +2 -2
  48. data/doc_out/HeartBeatAlert.html.md +1 -1
  49. data/doc_out/HeartBeatAlertContainer.html.md +2 -2
  50. data/doc_out/HeartBeatRule.html.md +1 -1
  51. data/doc_out/HeartBeatRuleContainer.html.md +2 -2
  52. data/doc_out/InboundDomainEntityListing.html.md +2 -2
  53. data/doc_out/InboundRouteEntityListing.html.md +2 -2
  54. data/doc_out/InteractionStatsAlert.html.md +1 -1
  55. data/doc_out/InteractionStatsAlertContainer.html.md +2 -2
  56. data/doc_out/InteractionStatsRule.html.md +1 -1
  57. data/doc_out/InteractionStatsRuleContainer.html.md +2 -2
  58. data/doc_out/KeywordSetEntityListing.html.md +2 -2
  59. data/doc_out/LanguageEntityListing.html.md +2 -2
  60. data/doc_out/LibraryEntityListing.html.md +2 -2
  61. data/doc_out/LineBaseEntityListing.html.md +2 -2
  62. data/doc_out/LineEntityListing.html.md +2 -2
  63. data/doc_out/LocalEncryptionConfigurationListing.html.md +2 -2
  64. data/doc_out/LogicalInterfaceEntityListing.html.md +2 -2
  65. data/doc_out/OAuthClient.html.md +2 -2
  66. data/doc_out/OAuthClientEntityListing.html.md +3 -3
  67. data/doc_out/OAuthClientListing.html.md +20 -0
  68. data/doc_out/OAuthProviderEntityListing.html.md +2 -2
  69. data/doc_out/OrganizationPresenceEntityListing.html.md +2 -2
  70. data/doc_out/OrganizationRoleEntityListing.html.md +2 -2
  71. data/doc_out/OrphanRecording.html.md +1 -0
  72. data/doc_out/OrphanRecordingListing.html.md +2 -2
  73. data/doc_out/OrphanUpdateRequest.html.md +15 -0
  74. data/doc_out/OutboundRouteEntityListing.html.md +2 -2
  75. data/doc_out/PermissionCollectionEntityListing.html.md +2 -2
  76. data/doc_out/PhoneBaseEntityListing.html.md +2 -2
  77. data/doc_out/PhoneEntityListing.html.md +2 -2
  78. data/doc_out/PhoneMetaBaseEntityListing.html.md +2 -2
  79. data/doc_out/PhysicalInterfaceEntityListing.html.md +2 -2
  80. data/doc_out/PolicyEntityListing.html.md +2 -2
  81. data/doc_out/QualityApi.html.md +5 -1
  82. data/doc_out/QualityAuditPage.html.md +2 -2
  83. data/doc_out/QueueEntityListing.html.md +2 -2
  84. data/doc_out/QueueMemberEntityListing.html.md +2 -2
  85. data/doc_out/RecordingApi.html.md +132 -4
  86. data/doc_out/ReportMetaDataEntityListing.html.md +2 -2
  87. data/doc_out/ReportRunEntryEntityDomainListing.html.md +2 -2
  88. data/doc_out/ReportScheduleEntityListing.html.md +2 -2
  89. data/doc_out/ResponseEntityList.html.md +2 -2
  90. data/doc_out/ResponseEntityListing.html.md +2 -2
  91. data/doc_out/ResponseSetEntityListing.html.md +2 -2
  92. data/doc_out/RoutingStatusAlert.html.md +23 -0
  93. data/doc_out/RoutingStatusAlertContainer.html.md +22 -0
  94. data/doc_out/RoutingStatusRule.html.md +22 -0
  95. data/doc_out/RoutingStatusRuleContainer.html.md +22 -0
  96. data/doc_out/RuleSetEntityListing.html.md +2 -2
  97. data/doc_out/SchemaCategoryEntityListing.html.md +2 -2
  98. data/doc_out/SchemaReferenceEntityListing.html.md +2 -2
  99. data/doc_out/ScreenRecordingSessionListing.html.md +2 -2
  100. data/doc_out/ScriptEntityListing.html.md +2 -2
  101. data/doc_out/SecurityProfileEntityListing.html.md +2 -2
  102. data/doc_out/ShareEntityListing.html.md +2 -2
  103. data/doc_out/SiteEntityListing.html.md +2 -2
  104. data/doc_out/SkillEntityListing.html.md +2 -2
  105. data/doc_out/StationEntityListing.html.md +2 -2
  106. data/doc_out/StreetAddress.html.md +2 -2
  107. data/doc_out/TagValueEntityListing.html.md +2 -2
  108. data/doc_out/TelephonyProvidersEdgeApi.html.md +21 -17
  109. data/doc_out/TimeZoneEntityListing.html.md +2 -2
  110. data/doc_out/TrunkBaseEntityListing.html.md +2 -2
  111. data/doc_out/TrunkEntityListing.html.md +2 -2
  112. data/doc_out/TrunkMetabaseEntityListing.html.md +2 -2
  113. data/doc_out/UserEntityListing.html.md +2 -2
  114. data/doc_out/UserPresenceAlert.html.md +25 -0
  115. data/doc_out/UserPresenceAlertContainer.html.md +22 -0
  116. data/doc_out/UserPresenceRule.html.md +23 -0
  117. data/doc_out/{UsersEntityListing.html.md → UserPresenceRuleContainer.html.md} +5 -5
  118. data/doc_out/UserQueueEntityListing.html.md +2 -2
  119. data/doc_out/UserRecordingEntityListing.html.md +2 -2
  120. data/doc_out/UserSkillEntityListing.html.md +2 -2
  121. data/doc_out/UsersApi.html.md +2 -2
  122. data/doc_out/WorkspaceEntityListing.html.md +2 -2
  123. data/doc_out/WorkspaceMemberEntityListing.html.md +2 -2
  124. data/doc_out/WrapupCodeEntityListing.html.md +2 -2
  125. data/doc_out/index.html.md +3 -3
  126. data/lib/purecloud.rb +10 -1
  127. data/lib/purecloud/api/alerting_api.rb +1070 -49
  128. data/lib/purecloud/api/quality_api.rb +6 -0
  129. data/lib/purecloud/api/recording_api.rb +140 -2
  130. data/lib/purecloud/api/telephony_providers_edge_api.rb +13 -10
  131. data/lib/purecloud/api/users_api.rb +3 -3
  132. data/lib/purecloud/api_client.rb +1 -1
  133. data/lib/purecloud/models/agent_activity_entity_listing.rb +17 -17
  134. data/lib/purecloud/models/aggregation_query.rb +1 -1
  135. data/lib/purecloud/models/annotation.rb +115 -1
  136. data/lib/purecloud/models/attempt_limits_entity_listing.rb +17 -17
  137. data/lib/purecloud/models/attribute_entity_listing.rb +17 -17
  138. data/lib/purecloud/models/calibration_entity_listing.rb +17 -17
  139. data/lib/purecloud/models/call_conversation_entity_listing.rb +17 -17
  140. data/lib/purecloud/models/callable_time_set_entity_listing.rb +17 -17
  141. data/lib/purecloud/models/callback_conversation_entity_listing.rb +17 -17
  142. data/lib/purecloud/models/campaign_entity_listing.rb +17 -17
  143. data/lib/purecloud/models/campaign_sequence_entity_listing.rb +17 -17
  144. data/lib/purecloud/models/certificate_authority_entity_listing.rb +17 -17
  145. data/lib/purecloud/models/channel_entity_listing.rb +17 -17
  146. data/lib/purecloud/models/chat_conversation_entity_listing.rb +17 -17
  147. data/lib/purecloud/models/cobrowse_conversation_entity_listing.rb +17 -17
  148. data/lib/purecloud/models/command_status_entity_listing.rb +17 -17
  149. data/lib/purecloud/models/contact_list_entity_listing.rb +17 -17
  150. data/lib/purecloud/models/contact_sort.rb +1 -0
  151. data/lib/purecloud/models/conversation_entity_listing.rb +17 -17
  152. data/lib/purecloud/models/did_entity_listing.rb +17 -17
  153. data/lib/purecloud/models/did_pool_entity_listing.rb +17 -17
  154. data/lib/purecloud/models/dnc_list_entity_listing.rb +17 -17
  155. data/lib/purecloud/models/document_audit_entity_listing.rb +17 -17
  156. data/lib/purecloud/models/document_entity_listing.rb +17 -17
  157. data/lib/purecloud/models/domain_edge_software_version_dto_entity_listing.rb +17 -17
  158. data/lib/purecloud/models/domain_entity_listing.rb +17 -17
  159. data/lib/purecloud/models/domain_entity_listing_evaluation_form.rb +17 -17
  160. data/lib/purecloud/models/domain_entity_listing_query_result.rb +17 -17
  161. data/lib/purecloud/models/edge.rb +2 -1
  162. data/lib/purecloud/models/edge_entity_listing.rb +17 -17
  163. data/lib/purecloud/models/edge_group_entity_listing.rb +17 -17
  164. data/lib/purecloud/models/edge_line_entity_listing.rb +17 -17
  165. data/lib/purecloud/models/email_conversation_entity_listing.rb +17 -17
  166. data/lib/purecloud/models/email_message_listing.rb +17 -17
  167. data/lib/purecloud/models/encryption_key_entity_listing.rb +17 -17
  168. data/lib/purecloud/models/endpoint_entity_listing.rb +17 -17
  169. data/lib/purecloud/models/evaluation_entity_listing.rb +17 -17
  170. data/lib/purecloud/models/evaluation_form_entity_listing.rb +17 -17
  171. data/lib/purecloud/models/evaluator_activity_entity_listing.rb +17 -17
  172. data/lib/purecloud/models/extension_entity_listing.rb +17 -17
  173. data/lib/purecloud/models/extension_pool_entity_listing.rb +17 -17
  174. data/lib/purecloud/models/fax_document_entity_listing.rb +17 -17
  175. data/lib/purecloud/models/group_entity_listing.rb +17 -17
  176. data/lib/purecloud/models/group_search_criteria.rb +1 -1
  177. data/lib/purecloud/models/heart_beat_alert.rb +1 -1
  178. data/lib/purecloud/models/heart_beat_alert_container.rb +17 -17
  179. data/lib/purecloud/models/heart_beat_rule.rb +1 -1
  180. data/lib/purecloud/models/heart_beat_rule_container.rb +17 -17
  181. data/lib/purecloud/models/inbound_domain_entity_listing.rb +17 -17
  182. data/lib/purecloud/models/inbound_route_entity_listing.rb +17 -17
  183. data/lib/purecloud/models/interaction_stats_alert.rb +1 -1
  184. data/lib/purecloud/models/interaction_stats_alert_container.rb +17 -17
  185. data/lib/purecloud/models/interaction_stats_rule.rb +1 -1
  186. data/lib/purecloud/models/interaction_stats_rule_container.rb +17 -17
  187. data/lib/purecloud/models/keyword_set_entity_listing.rb +17 -17
  188. data/lib/purecloud/models/language_entity_listing.rb +17 -17
  189. data/lib/purecloud/models/library_entity_listing.rb +17 -17
  190. data/lib/purecloud/models/line_base_entity_listing.rb +17 -17
  191. data/lib/purecloud/models/line_entity_listing.rb +17 -17
  192. data/lib/purecloud/models/local_encryption_configuration_listing.rb +17 -17
  193. data/lib/purecloud/models/location_search_criteria.rb +1 -1
  194. data/lib/purecloud/models/logical_interface_entity_listing.rb +17 -17
  195. data/lib/purecloud/models/o_auth_client_entity_listing.rb +18 -18
  196. data/lib/purecloud/models/o_auth_client_listing.rb +246 -0
  197. data/lib/purecloud/models/o_auth_provider_entity_listing.rb +17 -17
  198. data/lib/purecloud/models/organization_presence_entity_listing.rb +17 -17
  199. data/lib/purecloud/models/organization_role_entity_listing.rb +17 -17
  200. data/lib/purecloud/models/orphan_recording.rb +21 -1
  201. data/lib/purecloud/models/orphan_recording_listing.rb +17 -17
  202. data/lib/purecloud/models/orphan_update_request.rb +188 -0
  203. data/lib/purecloud/models/outbound_route_entity_listing.rb +17 -17
  204. data/lib/purecloud/models/permission_collection_entity_listing.rb +17 -17
  205. data/lib/purecloud/models/phone_base_entity_listing.rb +17 -17
  206. data/lib/purecloud/models/phone_entity_listing.rb +17 -17
  207. data/lib/purecloud/models/phone_meta_base_entity_listing.rb +17 -17
  208. data/lib/purecloud/models/physical_interface_entity_listing.rb +17 -17
  209. data/lib/purecloud/models/policy_entity_listing.rb +17 -17
  210. data/lib/purecloud/models/quality_audit_page.rb +17 -17
  211. data/lib/purecloud/models/queue_entity_listing.rb +17 -17
  212. data/lib/purecloud/models/queue_member_entity_listing.rb +17 -17
  213. data/lib/purecloud/models/report_meta_data_entity_listing.rb +17 -17
  214. data/lib/purecloud/models/report_run_entry_entity_domain_listing.rb +17 -17
  215. data/lib/purecloud/models/report_schedule_entity_listing.rb +17 -17
  216. data/lib/purecloud/models/response_entity_list.rb +17 -17
  217. data/lib/purecloud/models/response_entity_listing.rb +17 -17
  218. data/lib/purecloud/models/response_set_entity_listing.rb +17 -17
  219. data/lib/purecloud/models/routing_status_alert.rb +289 -0
  220. data/lib/purecloud/models/routing_status_alert_container.rb +257 -0
  221. data/lib/purecloud/models/routing_status_rule.rb +282 -0
  222. data/lib/purecloud/models/routing_status_rule_container.rb +257 -0
  223. data/lib/purecloud/models/rule_set_entity_listing.rb +17 -17
  224. data/lib/purecloud/models/schema_category_entity_listing.rb +17 -17
  225. data/lib/purecloud/models/schema_reference_entity_listing.rb +17 -17
  226. data/lib/purecloud/models/screen_recording_session_listing.rb +17 -17
  227. data/lib/purecloud/models/script_entity_listing.rb +17 -17
  228. data/lib/purecloud/models/security_profile_entity_listing.rb +17 -17
  229. data/lib/purecloud/models/share_entity_listing.rb +17 -17
  230. data/lib/purecloud/models/site_entity_listing.rb +17 -17
  231. data/lib/purecloud/models/skill_entity_listing.rb +17 -17
  232. data/lib/purecloud/models/station_entity_listing.rb +17 -17
  233. data/lib/purecloud/models/street_address.rb +2 -0
  234. data/lib/purecloud/models/tag_value_entity_listing.rb +17 -17
  235. data/lib/purecloud/models/time_zone_entity_listing.rb +17 -17
  236. data/lib/purecloud/models/trunk_base_entity_listing.rb +17 -17
  237. data/lib/purecloud/models/trunk_entity_listing.rb +17 -17
  238. data/lib/purecloud/models/trunk_metabase_entity_listing.rb +17 -17
  239. data/lib/purecloud/models/user_entity_listing.rb +17 -17
  240. data/lib/purecloud/models/user_presence_alert.rb +310 -0
  241. data/lib/purecloud/models/user_presence_alert_container.rb +257 -0
  242. data/lib/purecloud/models/user_presence_rule.rb +293 -0
  243. data/lib/purecloud/models/{users_entity_listing.rb → user_presence_rule_container.rb} +19 -19
  244. data/lib/purecloud/models/user_queue_entity_listing.rb +17 -17
  245. data/lib/purecloud/models/user_recording_entity_listing.rb +17 -17
  246. data/lib/purecloud/models/user_schedule_adherence.rb +3 -3
  247. data/lib/purecloud/models/user_search_criteria.rb +1 -1
  248. data/lib/purecloud/models/user_skill_entity_listing.rb +17 -17
  249. data/lib/purecloud/models/workspace_entity_listing.rb +17 -17
  250. data/lib/purecloud/models/workspace_member_entity_listing.rb +17 -17
  251. data/lib/purecloud/models/wrapup_code_entity_listing.rb +17 -17
  252. data/lib/purecloud/version.rb +1 -1
  253. data/newVersion.md +1 -1
  254. data/swagger.json +1 -1
  255. data/version.json +1 -1
  256. metadata +22 -4
@@ -26,16 +26,16 @@ module PureCloud
26
26
 
27
27
  attr_accessor :total
28
28
 
29
+ attr_accessor :first_uri
30
+
29
31
  attr_accessor :self_uri
30
32
 
31
- attr_accessor :first_uri
33
+ attr_accessor :previous_uri
32
34
 
33
35
  attr_accessor :next_uri
34
36
 
35
37
  attr_accessor :last_uri
36
38
 
37
- attr_accessor :previous_uri
38
-
39
39
  attr_accessor :page_count
40
40
 
41
41
  # Attribute mapping from ruby-style variable name to JSON key.
@@ -50,16 +50,16 @@ module PureCloud
50
50
 
51
51
  :'total' => :'total',
52
52
 
53
+ :'first_uri' => :'firstUri',
54
+
53
55
  :'self_uri' => :'selfUri',
54
56
 
55
- :'first_uri' => :'firstUri',
57
+ :'previous_uri' => :'previousUri',
56
58
 
57
59
  :'next_uri' => :'nextUri',
58
60
 
59
61
  :'last_uri' => :'lastUri',
60
62
 
61
- :'previous_uri' => :'previousUri',
62
-
63
63
  :'page_count' => :'pageCount'
64
64
 
65
65
  }
@@ -72,11 +72,11 @@ module PureCloud
72
72
  :'page_size' => :'Integer',
73
73
  :'page_number' => :'Integer',
74
74
  :'total' => :'Integer',
75
- :'self_uri' => :'String',
76
75
  :'first_uri' => :'String',
76
+ :'self_uri' => :'String',
77
+ :'previous_uri' => :'String',
77
78
  :'next_uri' => :'String',
78
79
  :'last_uri' => :'String',
79
- :'previous_uri' => :'String',
80
80
  :'page_count' => :'Integer'
81
81
 
82
82
  }
@@ -107,12 +107,16 @@ module PureCloud
107
107
  self.total = attributes[:'total']
108
108
  end
109
109
 
110
+ if attributes[:'firstUri']
111
+ self.first_uri = attributes[:'firstUri']
112
+ end
113
+
110
114
  if attributes[:'selfUri']
111
115
  self.self_uri = attributes[:'selfUri']
112
116
  end
113
117
 
114
- if attributes[:'firstUri']
115
- self.first_uri = attributes[:'firstUri']
118
+ if attributes[:'previousUri']
119
+ self.previous_uri = attributes[:'previousUri']
116
120
  end
117
121
 
118
122
  if attributes[:'nextUri']
@@ -123,10 +127,6 @@ module PureCloud
123
127
  self.last_uri = attributes[:'lastUri']
124
128
  end
125
129
 
126
- if attributes[:'previousUri']
127
- self.previous_uri = attributes[:'previousUri']
128
- end
129
-
130
130
  if attributes[:'pageCount']
131
131
  self.page_count = attributes[:'pageCount']
132
132
  end
@@ -141,11 +141,11 @@ module PureCloud
141
141
  page_size == o.page_size &&
142
142
  page_number == o.page_number &&
143
143
  total == o.total &&
144
- self_uri == o.self_uri &&
145
144
  first_uri == o.first_uri &&
145
+ self_uri == o.self_uri &&
146
+ previous_uri == o.previous_uri &&
146
147
  next_uri == o.next_uri &&
147
148
  last_uri == o.last_uri &&
148
- previous_uri == o.previous_uri &&
149
149
  page_count == o.page_count
150
150
  end
151
151
 
@@ -156,7 +156,7 @@ module PureCloud
156
156
 
157
157
  # Calculate hash code according to all attributes.
158
158
  def hash
159
- [entities, page_size, page_number, total, self_uri, first_uri, next_uri, last_uri, previous_uri, page_count].hash
159
+ [entities, page_size, page_number, total, first_uri, self_uri, previous_uri, next_uri, last_uri, page_count].hash
160
160
  end
161
161
 
162
162
  # build the object from hash
@@ -0,0 +1,310 @@
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@inin.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 UserPresenceAlert
21
+ # The globally unique identifier for the object.
22
+ attr_accessor :id
23
+
24
+ # Name of the rule
25
+ attr_accessor :name
26
+
27
+ # The user whose presence will be watched.
28
+ attr_accessor :presence_user
29
+
30
+ # Indicates to which presence type the presence value belongs.
31
+ attr_accessor :presence_type
32
+
33
+ # The Org's UUID or Systems enum constance indicating the presence of concern.
34
+ attr_accessor :presence_value
35
+
36
+ # The number of seconds to wait before alerting based upon the user's presence.
37
+ attr_accessor :presence_limit_in_seconds
38
+
39
+ # The id of the rule.
40
+ attr_accessor :rule_id
41
+
42
+ # The date/time the alert was created. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ
43
+ attr_accessor :start_date
44
+
45
+ # The date/time the owning rule exiting in alarm status. Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ
46
+ attr_accessor :end_date
47
+
48
+ # The ids of users who were notified of alarm state change.
49
+ attr_accessor :notification_users
50
+
51
+ # A collection of notification methods.
52
+ attr_accessor :alert_types
53
+
54
+ attr_accessor :rule_uri
55
+
56
+ # The URI for this object
57
+ attr_accessor :self_uri
58
+
59
+ # Attribute mapping from ruby-style variable name to JSON key.
60
+ def self.attribute_map
61
+ {
62
+
63
+ :'id' => :'id',
64
+
65
+ :'name' => :'name',
66
+
67
+ :'presence_user' => :'presenceUser',
68
+
69
+ :'presence_type' => :'presenceType',
70
+
71
+ :'presence_value' => :'presenceValue',
72
+
73
+ :'presence_limit_in_seconds' => :'presenceLimitInSeconds',
74
+
75
+ :'rule_id' => :'ruleId',
76
+
77
+ :'start_date' => :'startDate',
78
+
79
+ :'end_date' => :'endDate',
80
+
81
+ :'notification_users' => :'notificationUsers',
82
+
83
+ :'alert_types' => :'alertTypes',
84
+
85
+ :'rule_uri' => :'ruleUri',
86
+
87
+ :'self_uri' => :'selfUri'
88
+
89
+ }
90
+ end
91
+
92
+ # Attribute type mapping.
93
+ def self.swagger_types
94
+ {
95
+ :'id' => :'String',
96
+ :'name' => :'String',
97
+ :'presence_user' => :'User',
98
+ :'presence_type' => :'String',
99
+ :'presence_value' => :'String',
100
+ :'presence_limit_in_seconds' => :'Integer',
101
+ :'rule_id' => :'String',
102
+ :'start_date' => :'DateTime',
103
+ :'end_date' => :'DateTime',
104
+ :'notification_users' => :'Array<User>',
105
+ :'alert_types' => :'Array<String>',
106
+ :'rule_uri' => :'String',
107
+ :'self_uri' => :'String'
108
+
109
+ }
110
+ end
111
+
112
+ def initialize(attributes = {})
113
+ return unless attributes.is_a?(Hash)
114
+
115
+ # convert string to symbol for hash key
116
+ attributes = attributes.inject({}){|memo,(k,v)| memo[k.to_sym] = v; memo}
117
+
118
+
119
+ if attributes[:'id']
120
+ self.id = attributes[:'id']
121
+ end
122
+
123
+ if attributes[:'name']
124
+ self.name = attributes[:'name']
125
+ end
126
+
127
+ if attributes[:'presenceUser']
128
+ self.presence_user = attributes[:'presenceUser']
129
+ end
130
+
131
+ if attributes[:'presenceType']
132
+ self.presence_type = attributes[:'presenceType']
133
+ end
134
+
135
+ if attributes[:'presenceValue']
136
+ self.presence_value = attributes[:'presenceValue']
137
+ end
138
+
139
+ if attributes[:'presenceLimitInSeconds']
140
+ self.presence_limit_in_seconds = attributes[:'presenceLimitInSeconds']
141
+ end
142
+
143
+ if attributes[:'ruleId']
144
+ self.rule_id = attributes[:'ruleId']
145
+ end
146
+
147
+ if attributes[:'startDate']
148
+ self.start_date = attributes[:'startDate']
149
+ end
150
+
151
+ if attributes[:'endDate']
152
+ self.end_date = attributes[:'endDate']
153
+ end
154
+
155
+ if attributes[:'notificationUsers']
156
+ if (value = attributes[:'notificationUsers']).is_a?(Array)
157
+ self.notification_users = value
158
+ end
159
+ end
160
+
161
+ if attributes[:'alertTypes']
162
+ if (value = attributes[:'alertTypes']).is_a?(Array)
163
+ self.alert_types = value
164
+ end
165
+ end
166
+
167
+ if attributes[:'ruleUri']
168
+ self.rule_uri = attributes[:'ruleUri']
169
+ end
170
+
171
+ if attributes[:'selfUri']
172
+ self.self_uri = attributes[:'selfUri']
173
+ end
174
+
175
+ end
176
+
177
+ # Custom attribute writer method checking allowed values (enum).
178
+ def presence_type=(presence_type)
179
+ allowed_values = ["SYSTEM", "ORGANIZATION"]
180
+ if presence_type && !allowed_values.include?(presence_type)
181
+ fail "invalid value for 'presence_type', must be one of #{allowed_values}"
182
+ end
183
+ @presence_type = presence_type
184
+ end
185
+
186
+ # Check equality by comparing each attribute.
187
+ def ==(o)
188
+ return true if self.equal?(o)
189
+ self.class == o.class &&
190
+ id == o.id &&
191
+ name == o.name &&
192
+ presence_user == o.presence_user &&
193
+ presence_type == o.presence_type &&
194
+ presence_value == o.presence_value &&
195
+ presence_limit_in_seconds == o.presence_limit_in_seconds &&
196
+ rule_id == o.rule_id &&
197
+ start_date == o.start_date &&
198
+ end_date == o.end_date &&
199
+ notification_users == o.notification_users &&
200
+ alert_types == o.alert_types &&
201
+ rule_uri == o.rule_uri &&
202
+ self_uri == o.self_uri
203
+ end
204
+
205
+ # @see the `==` method
206
+ def eql?(o)
207
+ self == o
208
+ end
209
+
210
+ # Calculate hash code according to all attributes.
211
+ def hash
212
+ [id, name, presence_user, presence_type, presence_value, presence_limit_in_seconds, rule_id, start_date, end_date, notification_users, alert_types, rule_uri, self_uri].hash
213
+ end
214
+
215
+ # build the object from hash
216
+ def build_from_hash(attributes)
217
+ return nil unless attributes.is_a?(Hash)
218
+ self.class.swagger_types.each_pair do |key, type|
219
+ if type =~ /^Array<(.*)>/i
220
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
221
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
222
+ else
223
+ #TODO show warning in debug mode
224
+ end
225
+ elsif !attributes[self.class.attribute_map[key]].nil?
226
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
227
+ else
228
+ # data not found in attributes(hash), not an issue as the data can be optional
229
+ end
230
+ end
231
+
232
+ self
233
+ end
234
+
235
+ def _deserialize(type, value)
236
+ case type.to_sym
237
+ when :DateTime
238
+ DateTime.parse(value)
239
+ when :Date
240
+ Date.parse(value)
241
+ when :String
242
+ value.to_s
243
+ when :Integer
244
+ value.to_i
245
+ when :Float
246
+ value.to_f
247
+ when :BOOLEAN
248
+ if value.to_s =~ /^(true|t|yes|y|1)$/i
249
+ true
250
+ else
251
+ false
252
+ end
253
+ when :Object
254
+ # generic object (usually a Hash), return directly
255
+ value
256
+ when /\AArray<(?<inner_type>.+)>\z/
257
+ inner_type = Regexp.last_match[:inner_type]
258
+ value.map { |v| _deserialize(inner_type, v) }
259
+ when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
260
+ k_type = Regexp.last_match[:k_type]
261
+ v_type = Regexp.last_match[:v_type]
262
+ {}.tap do |hash|
263
+ value.each do |k, v|
264
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
265
+ end
266
+ end
267
+ else # model
268
+ _model = Object.const_get("PureCloud").const_get(type).new
269
+ _model.build_from_hash(value)
270
+ end
271
+ end
272
+
273
+ def to_s
274
+ to_hash.to_s
275
+ end
276
+
277
+ # to_body is an alias to to_body (backward compatibility))
278
+ def to_body
279
+ to_hash
280
+ end
281
+
282
+ # return the object in the form of hash
283
+ def to_hash
284
+ hash = {}
285
+ self.class.attribute_map.each_pair do |attr, param|
286
+ value = self.send(attr)
287
+ next if value.nil?
288
+ hash[param] = _to_hash(value)
289
+ end
290
+ hash
291
+ end
292
+
293
+ # Method to output non-array value in the form of hash
294
+ # For object, use to_hash. Otherwise, just return the value
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
+ end
@@ -0,0 +1,257 @@
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@inin.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 UserPresenceAlertContainer
21
+ attr_accessor :entities
22
+
23
+ attr_accessor :page_size
24
+
25
+ attr_accessor :page_number
26
+
27
+ attr_accessor :total
28
+
29
+ attr_accessor :first_uri
30
+
31
+ attr_accessor :self_uri
32
+
33
+ attr_accessor :previous_uri
34
+
35
+ attr_accessor :next_uri
36
+
37
+ attr_accessor :last_uri
38
+
39
+ attr_accessor :page_count
40
+
41
+ # Attribute mapping from ruby-style variable name to JSON key.
42
+ def self.attribute_map
43
+ {
44
+
45
+ :'entities' => :'entities',
46
+
47
+ :'page_size' => :'pageSize',
48
+
49
+ :'page_number' => :'pageNumber',
50
+
51
+ :'total' => :'total',
52
+
53
+ :'first_uri' => :'firstUri',
54
+
55
+ :'self_uri' => :'selfUri',
56
+
57
+ :'previous_uri' => :'previousUri',
58
+
59
+ :'next_uri' => :'nextUri',
60
+
61
+ :'last_uri' => :'lastUri',
62
+
63
+ :'page_count' => :'pageCount'
64
+
65
+ }
66
+ end
67
+
68
+ # Attribute type mapping.
69
+ def self.swagger_types
70
+ {
71
+ :'entities' => :'Array<UserPresenceAlert>',
72
+ :'page_size' => :'Integer',
73
+ :'page_number' => :'Integer',
74
+ :'total' => :'Integer',
75
+ :'first_uri' => :'String',
76
+ :'self_uri' => :'String',
77
+ :'previous_uri' => :'String',
78
+ :'next_uri' => :'String',
79
+ :'last_uri' => :'String',
80
+ :'page_count' => :'Integer'
81
+
82
+ }
83
+ end
84
+
85
+ def initialize(attributes = {})
86
+ return unless attributes.is_a?(Hash)
87
+
88
+ # convert string to symbol for hash key
89
+ attributes = attributes.inject({}){|memo,(k,v)| memo[k.to_sym] = v; memo}
90
+
91
+
92
+ if attributes[:'entities']
93
+ if (value = attributes[:'entities']).is_a?(Array)
94
+ self.entities = value
95
+ end
96
+ end
97
+
98
+ if attributes[:'pageSize']
99
+ self.page_size = attributes[:'pageSize']
100
+ end
101
+
102
+ if attributes[:'pageNumber']
103
+ self.page_number = attributes[:'pageNumber']
104
+ end
105
+
106
+ if attributes[:'total']
107
+ self.total = attributes[:'total']
108
+ end
109
+
110
+ if attributes[:'firstUri']
111
+ self.first_uri = attributes[:'firstUri']
112
+ end
113
+
114
+ if attributes[:'selfUri']
115
+ self.self_uri = attributes[:'selfUri']
116
+ end
117
+
118
+ if attributes[:'previousUri']
119
+ self.previous_uri = attributes[:'previousUri']
120
+ end
121
+
122
+ if attributes[:'nextUri']
123
+ self.next_uri = attributes[:'nextUri']
124
+ end
125
+
126
+ if attributes[:'lastUri']
127
+ self.last_uri = attributes[:'lastUri']
128
+ end
129
+
130
+ if attributes[:'pageCount']
131
+ self.page_count = attributes[:'pageCount']
132
+ end
133
+
134
+ end
135
+
136
+ # Check equality by comparing each attribute.
137
+ def ==(o)
138
+ return true if self.equal?(o)
139
+ self.class == o.class &&
140
+ entities == o.entities &&
141
+ page_size == o.page_size &&
142
+ page_number == o.page_number &&
143
+ total == o.total &&
144
+ first_uri == o.first_uri &&
145
+ self_uri == o.self_uri &&
146
+ previous_uri == o.previous_uri &&
147
+ next_uri == o.next_uri &&
148
+ last_uri == o.last_uri &&
149
+ page_count == o.page_count
150
+ end
151
+
152
+ # @see the `==` method
153
+ def eql?(o)
154
+ self == o
155
+ end
156
+
157
+ # Calculate hash code according to all attributes.
158
+ def hash
159
+ [entities, page_size, page_number, total, first_uri, self_uri, previous_uri, next_uri, last_uri, page_count].hash
160
+ end
161
+
162
+ # build the object from hash
163
+ def build_from_hash(attributes)
164
+ return nil unless attributes.is_a?(Hash)
165
+ self.class.swagger_types.each_pair do |key, type|
166
+ if type =~ /^Array<(.*)>/i
167
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
168
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
169
+ else
170
+ #TODO show warning in debug mode
171
+ end
172
+ elsif !attributes[self.class.attribute_map[key]].nil?
173
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
174
+ else
175
+ # data not found in attributes(hash), not an issue as the data can be optional
176
+ end
177
+ end
178
+
179
+ self
180
+ end
181
+
182
+ def _deserialize(type, value)
183
+ case type.to_sym
184
+ when :DateTime
185
+ DateTime.parse(value)
186
+ when :Date
187
+ Date.parse(value)
188
+ when :String
189
+ value.to_s
190
+ when :Integer
191
+ value.to_i
192
+ when :Float
193
+ value.to_f
194
+ when :BOOLEAN
195
+ if value.to_s =~ /^(true|t|yes|y|1)$/i
196
+ true
197
+ else
198
+ false
199
+ end
200
+ when :Object
201
+ # generic object (usually a Hash), return directly
202
+ value
203
+ when /\AArray<(?<inner_type>.+)>\z/
204
+ inner_type = Regexp.last_match[:inner_type]
205
+ value.map { |v| _deserialize(inner_type, v) }
206
+ when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
207
+ k_type = Regexp.last_match[:k_type]
208
+ v_type = Regexp.last_match[:v_type]
209
+ {}.tap do |hash|
210
+ value.each do |k, v|
211
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
212
+ end
213
+ end
214
+ else # model
215
+ _model = Object.const_get("PureCloud").const_get(type).new
216
+ _model.build_from_hash(value)
217
+ end
218
+ end
219
+
220
+ def to_s
221
+ to_hash.to_s
222
+ end
223
+
224
+ # to_body is an alias to to_body (backward compatibility))
225
+ def to_body
226
+ to_hash
227
+ end
228
+
229
+ # return the object in the form of hash
230
+ def to_hash
231
+ hash = {}
232
+ self.class.attribute_map.each_pair do |attr, param|
233
+ value = self.send(attr)
234
+ next if value.nil?
235
+ hash[param] = _to_hash(value)
236
+ end
237
+ hash
238
+ end
239
+
240
+ # Method to output non-array value in the form of hash
241
+ # For object, use to_hash. Otherwise, just return the value
242
+ def _to_hash(value)
243
+ if value.is_a?(Array)
244
+ value.compact.map{ |v| _to_hash(v) }
245
+ elsif value.is_a?(Hash)
246
+ {}.tap do |hash|
247
+ value.each { |k, v| hash[k] = _to_hash(v) }
248
+ end
249
+ elsif value.respond_to? :to_hash
250
+ value.to_hash
251
+ else
252
+ value
253
+ end
254
+ end
255
+
256
+ end
257
+ end