purecloud 0.18.0 → 0.25.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +2 -2
- data/Gemfile.lock +2 -2
- data/README.md +1 -7
- data/config-ruby.json +1 -1
- data/extensions/auth.rb +2 -2
- data/lib/purecloud.rb +110 -75
- data/lib/purecloud/api/architect_api.rb +3127 -74
- data/lib/purecloud/api/attributes_api.rb +33 -33
- data/lib/purecloud/api/authorization_api.rb +83 -83
- data/lib/purecloud/api/compliance_api.rb +5 -5
- data/lib/purecloud/api/configuration_api.rb +594 -397
- data/lib/purecloud/api/content_management_api.rb +183 -183
- data/lib/purecloud/api/conversations_api.rb +289 -159
- data/lib/purecloud/api/downloads_api.rb +6 -6
- data/lib/purecloud/api/external_contacts_api.rb +1693 -0
- data/lib/purecloud/api/fax_api.rb +24 -24
- data/lib/purecloud/api/geolocation_api.rb +14 -14
- data/lib/purecloud/api/greetings_api.rb +68 -68
- data/lib/purecloud/api/groups_api.rb +31 -20
- data/lib/purecloud/api/languages_api.rb +18 -11
- data/lib/purecloud/api/licensing_api.rb +5 -5
- data/lib/purecloud/api/locations_api.rb +11 -11
- data/lib/purecloud/api/notifications_api.rb +41 -41
- data/lib/purecloud/api/o_auth_api.rb +69 -69
- data/lib/purecloud/api/outbound_api.rb +505 -325
- data/lib/purecloud/api/presence_api.rb +65 -65
- data/lib/purecloud/api/quality_api.rb +66 -639
- data/lib/purecloud/api/recording_api.rb +1343 -0
- data/lib/purecloud/api/response_management_api.rb +687 -0
- data/lib/purecloud/api/routing_api.rb +224 -170
- data/lib/purecloud/api/scripts_api.rb +52 -52
- data/lib/purecloud/api/search_api.rb +5 -5
- data/lib/purecloud/api/stations_api.rb +8 -8
- data/lib/purecloud/api/telephony_providers_edge_api.rb +138 -138
- data/lib/purecloud/api/user_recordings_api.rb +29 -29
- data/lib/purecloud/api/users_api.rb +123 -123
- data/lib/purecloud/api/utilities_api.rb +71 -15
- data/lib/purecloud/api/voicemail_api.rb +42 -42
- data/lib/purecloud/api_client.rb +1 -1
- data/lib/purecloud/models/address.rb +49 -51
- data/lib/purecloud/models/attribute_filter_item.rb +177 -0
- data/lib/purecloud/models/automate_queue_member_entity_listing.rb +238 -0
- data/lib/purecloud/models/available_additional_service.rb +40 -1
- data/lib/purecloud/models/{topic_entity_listing.rb → available_topic_entity_listing.rb} +1 -1
- data/lib/purecloud/models/call.rb +36 -5
- data/lib/purecloud/models/{line_properties.rb → call_command.rb} +13 -3
- data/lib/purecloud/models/callback.rb +15 -4
- data/lib/purecloud/models/campaign.rb +219 -17
- data/lib/purecloud/models/campaign_progress.rb +186 -0
- data/lib/purecloud/models/channel_topic_entity_listing.rb +238 -0
- data/lib/purecloud/models/charge.rb +14 -4
- data/lib/purecloud/models/{attribute_value.rb → client_text_table_transform.rb} +52 -82
- data/lib/purecloud/models/contact.rb +1 -1
- data/lib/purecloud/models/contact_list.rb +111 -1
- data/lib/purecloud/models/contact_listing.rb +238 -0
- data/lib/purecloud/models/content_attribute_filter_item.rb +177 -0
- data/lib/purecloud/models/content_facet_filter_item.rb +1 -1
- data/lib/purecloud/models/content_query_request.rb +16 -4
- data/lib/purecloud/models/control.rb +221 -0
- data/lib/purecloud/models/{flow_activate_request.rb → control_options.rb} +18 -12
- data/lib/purecloud/models/create_callback_command.rb +200 -0
- data/lib/purecloud/models/discount.rb +220 -0
- data/lib/purecloud/models/document.rb +13 -1
- data/lib/purecloud/models/document_attribute.rb +158 -0
- data/lib/purecloud/models/document_update.rb +28 -16
- data/lib/purecloud/models/document_upload.rb +4 -16
- data/lib/purecloud/models/domain_voice_rate_extended_response_item_entity_listing.rb +238 -0
- data/lib/purecloud/models/domain_voice_rate_international_response_item_entity_listing.rb +238 -0
- data/lib/purecloud/models/domain_voice_rate_response_item_entity_listing.rb +1 -1
- data/lib/purecloud/models/edge_line.rb +1 -1
- data/lib/purecloud/models/edge_logs_job.rb +181 -0
- data/lib/purecloud/models/edge_logs_job_file.rb +243 -0
- data/lib/purecloud/models/edge_logs_job_request.rb +168 -0
- data/lib/purecloud/models/{backend_work_item_data_element.rb → edge_logs_job_response.rb} +16 -24
- data/lib/purecloud/models/{flow_lock_request.rb → edge_logs_job_upload_request.rb} +10 -12
- data/lib/purecloud/models/email.rb +15 -4
- data/lib/purecloud/models/endpoint.rb +1 -1
- data/lib/purecloud/models/{flow_associate_workspaces_request.rb → estimated_wait_time_predictions.rb} +10 -11
- data/lib/purecloud/models/external_contact.rb +320 -0
- data/lib/purecloud/models/external_organization.rb +306 -0
- data/lib/purecloud/models/external_organization_listing.rb +238 -0
- data/lib/purecloud/models/facet_filter_item.rb +1 -1
- data/lib/purecloud/models/flow_body.rb +1 -1
- data/lib/purecloud/models/flow_body_format.rb +10 -20
- data/lib/purecloud/models/flow_terminate_request.rb +3 -16
- data/lib/purecloud/models/form.rb +148 -0
- data/lib/purecloud/models/group.rb +11 -1
- data/lib/purecloud/models/health_check_info.rb +268 -0
- data/lib/purecloud/models/{body_2.rb → inline_response_200.rb} +1 -1
- data/lib/purecloud/models/integration_type.rb +209 -0
- data/lib/purecloud/models/integration_type_entity_listing.rb +238 -0
- data/lib/purecloud/models/key_rotation_schedule.rb +1 -0
- data/lib/purecloud/models/language.rb +41 -1
- data/lib/purecloud/models/line.rb +1 -1
- data/lib/purecloud/models/line_base.rb +1 -1
- data/lib/purecloud/models/media_policies.rb +169 -0
- data/lib/purecloud/models/media_policy.rb +171 -0
- data/lib/purecloud/models/note.rb +200 -0
- data/lib/purecloud/models/{user_station_resource.rb → note_listing.rb} +68 -58
- data/lib/purecloud/models/o_auth_client.rb +1 -1
- data/lib/purecloud/models/page.rb +2 -2
- data/lib/purecloud/models/{byte_buffer.rb → payment_method.rb} +48 -61
- data/lib/purecloud/models/payment_method_listing.rb +238 -0
- data/lib/purecloud/models/payment_token_provider.rb +180 -0
- data/lib/purecloud/models/phone.rb +1 -1
- data/lib/purecloud/models/phone_base.rb +1 -1
- data/lib/purecloud/models/phone_number.rb +198 -0
- data/lib/purecloud/models/phones_reboot.rb +14 -4
- data/lib/purecloud/models/policy.rb +14 -1
- data/lib/purecloud/models/prediction_results.rb +167 -0
- data/lib/purecloud/models/query_request.rb +16 -4
- data/lib/purecloud/models/queue_member_entity_listing.rb +1 -1
- data/lib/purecloud/models/quote.rb +13 -1
- data/lib/purecloud/models/recording_settings.rb +146 -0
- data/lib/purecloud/models/relationship.rb +201 -0
- data/lib/purecloud/models/relationship_listing.rb +238 -0
- data/lib/purecloud/models/report_schedule.rb +3 -2
- data/lib/purecloud/models/service_type.rb +12 -1
- data/lib/purecloud/models/social_expression.rb +25 -4
- data/lib/purecloud/models/spreadsheet_transform_entity_listing.rb +1 -1
- data/lib/purecloud/models/template.rb +1 -1
- data/lib/purecloud/models/text_table_transform_entity_listing.rb +1 -1
- data/lib/purecloud/models/ticker.rb +158 -0
- data/lib/purecloud/models/time_slot.rb +1 -0
- data/lib/purecloud/models/trunk_base.rb +1 -1
- data/lib/purecloud/models/vendor_connection_request.rb +166 -0
- data/lib/purecloud/models/video.rb +15 -4
- data/lib/purecloud/models/work_item_definition.rb +8 -10
- data/lib/purecloud/version.rb +1 -1
- data/ossindex.json +17 -0
- data/purecloud.gemspec +4 -3
- data/rakefile +3 -15
- data/spec/test.rb +6 -3
- data/swagger.json +1 -1
- data/swagger_template/api_client.mustache +304 -0
- data/swagger_template/base_object.mustache +90 -0
- data/{PureCloud.gemspec → swagger_template/gemspec.mustache} +12 -11
- data/version.json +1 -1
- metadata +76 -25
- data/lib/purecloud/api/analytics_api.rb +0 -1554
- data/lib/purecloud/api/orphaned_recordings_api.rb +0 -205
- data/newVersion.md +0 -1
@@ -0,0 +1,168 @@
|
|
1
|
+
require 'date'
|
2
|
+
|
3
|
+
module PureCloud
|
4
|
+
class EdgeLogsJobRequest
|
5
|
+
attr_accessor :_path
|
6
|
+
|
7
|
+
attr_accessor :query
|
8
|
+
|
9
|
+
attr_accessor :recurse
|
10
|
+
|
11
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
12
|
+
def self.attribute_map
|
13
|
+
{
|
14
|
+
|
15
|
+
:'_path' => :'path',
|
16
|
+
|
17
|
+
:'query' => :'query',
|
18
|
+
|
19
|
+
:'recurse' => :'recurse'
|
20
|
+
|
21
|
+
}
|
22
|
+
end
|
23
|
+
|
24
|
+
# Attribute type mapping.
|
25
|
+
def self.swagger_types
|
26
|
+
{
|
27
|
+
:'_path' => :'String',
|
28
|
+
:'query' => :'String',
|
29
|
+
:'recurse' => :'BOOLEAN'
|
30
|
+
|
31
|
+
}
|
32
|
+
end
|
33
|
+
|
34
|
+
def initialize(attributes = {})
|
35
|
+
return unless attributes.is_a?(Hash)
|
36
|
+
|
37
|
+
# convert string to symbol for hash key
|
38
|
+
attributes = attributes.inject({}){|memo,(k,v)| memo[k.to_sym] = v; memo}
|
39
|
+
|
40
|
+
|
41
|
+
if attributes[:'path']
|
42
|
+
self._path = attributes[:'path']
|
43
|
+
end
|
44
|
+
|
45
|
+
if attributes[:'query']
|
46
|
+
self.query = attributes[:'query']
|
47
|
+
end
|
48
|
+
|
49
|
+
if attributes[:'recurse']
|
50
|
+
self.recurse = attributes[:'recurse']
|
51
|
+
else
|
52
|
+
self.recurse = false
|
53
|
+
end
|
54
|
+
|
55
|
+
end
|
56
|
+
|
57
|
+
# Check equality by comparing each attribute.
|
58
|
+
def ==(o)
|
59
|
+
return true if self.equal?(o)
|
60
|
+
self.class == o.class &&
|
61
|
+
_path == o._path &&
|
62
|
+
query == o.query &&
|
63
|
+
recurse == o.recurse
|
64
|
+
end
|
65
|
+
|
66
|
+
# @see the `==` method
|
67
|
+
def eql?(o)
|
68
|
+
self == o
|
69
|
+
end
|
70
|
+
|
71
|
+
# Calculate hash code according to all attributes.
|
72
|
+
def hash
|
73
|
+
[_path, query, recurse].hash
|
74
|
+
end
|
75
|
+
|
76
|
+
# build the object from hash
|
77
|
+
def build_from_hash(attributes)
|
78
|
+
return nil unless attributes.is_a?(Hash)
|
79
|
+
self.class.swagger_types.each_pair do |key, type|
|
80
|
+
if type =~ /^Array<(.*)>/i
|
81
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
82
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
83
|
+
else
|
84
|
+
#TODO show warning in debug mode
|
85
|
+
end
|
86
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
87
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
88
|
+
else
|
89
|
+
# data not found in attributes(hash), not an issue as the data can be optional
|
90
|
+
end
|
91
|
+
end
|
92
|
+
|
93
|
+
self
|
94
|
+
end
|
95
|
+
|
96
|
+
def _deserialize(type, value)
|
97
|
+
case type.to_sym
|
98
|
+
when :DateTime
|
99
|
+
DateTime.parse(value)
|
100
|
+
when :Date
|
101
|
+
Date.parse(value)
|
102
|
+
when :String
|
103
|
+
value.to_s
|
104
|
+
when :Integer
|
105
|
+
value.to_i
|
106
|
+
when :Float
|
107
|
+
value.to_f
|
108
|
+
when :BOOLEAN
|
109
|
+
if value =~ /^(true|t|yes|y|1)$/i
|
110
|
+
true
|
111
|
+
else
|
112
|
+
false
|
113
|
+
end
|
114
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
115
|
+
inner_type = Regexp.last_match[:inner_type]
|
116
|
+
value.map { |v| _deserialize(inner_type, v) }
|
117
|
+
when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
|
118
|
+
k_type = Regexp.last_match[:k_type]
|
119
|
+
v_type = Regexp.last_match[:v_type]
|
120
|
+
{}.tap do |hash|
|
121
|
+
value.each do |k, v|
|
122
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
123
|
+
end
|
124
|
+
end
|
125
|
+
else # model
|
126
|
+
_model = Object.const_get("PureCloud").const_get(type).new
|
127
|
+
_model.build_from_hash(value)
|
128
|
+
end
|
129
|
+
end
|
130
|
+
|
131
|
+
def to_s
|
132
|
+
to_hash.to_s
|
133
|
+
end
|
134
|
+
|
135
|
+
# to_body is an alias to to_body (backward compatibility))
|
136
|
+
def to_body
|
137
|
+
to_hash
|
138
|
+
end
|
139
|
+
|
140
|
+
# return the object in the form of hash
|
141
|
+
def to_hash
|
142
|
+
hash = {}
|
143
|
+
self.class.attribute_map.each_pair do |attr, param|
|
144
|
+
value = self.send(attr)
|
145
|
+
next if value.nil?
|
146
|
+
hash[param] = _to_hash(value)
|
147
|
+
end
|
148
|
+
hash
|
149
|
+
end
|
150
|
+
|
151
|
+
# Method to output non-array value in the form of hash
|
152
|
+
# For object, use to_hash. Otherwise, just return the value
|
153
|
+
def _to_hash(value)
|
154
|
+
if value.is_a?(Array)
|
155
|
+
value.compact.map{ |v| _to_hash(v) }
|
156
|
+
elsif value.is_a?(Hash)
|
157
|
+
{}.tap do |hash|
|
158
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
159
|
+
end
|
160
|
+
elsif value.respond_to? :to_hash
|
161
|
+
value.to_hash
|
162
|
+
else
|
163
|
+
value
|
164
|
+
end
|
165
|
+
end
|
166
|
+
|
167
|
+
end
|
168
|
+
end
|
@@ -1,14 +1,14 @@
|
|
1
1
|
require 'date'
|
2
2
|
|
3
3
|
module PureCloud
|
4
|
-
class
|
4
|
+
class EdgeLogsJobResponse
|
5
|
+
# The created job id.
|
5
6
|
attr_accessor :id
|
6
7
|
|
7
|
-
attr_accessor :
|
8
|
+
attr_accessor :name
|
8
9
|
|
9
|
-
|
10
|
-
|
11
|
-
attr_accessor :control_type
|
10
|
+
# The URI for this object
|
11
|
+
attr_accessor :self_uri
|
12
12
|
|
13
13
|
# Attribute mapping from ruby-style variable name to JSON key.
|
14
14
|
def self.attribute_map
|
@@ -16,11 +16,9 @@ module PureCloud
|
|
16
16
|
|
17
17
|
:'id' => :'id',
|
18
18
|
|
19
|
-
:'
|
20
|
-
|
21
|
-
:'data_item_id' => :'dataItemId',
|
19
|
+
:'name' => :'name',
|
22
20
|
|
23
|
-
:'
|
21
|
+
:'self_uri' => :'selfUri'
|
24
22
|
|
25
23
|
}
|
26
24
|
end
|
@@ -29,9 +27,8 @@ module PureCloud
|
|
29
27
|
def self.swagger_types
|
30
28
|
{
|
31
29
|
:'id' => :'String',
|
32
|
-
:'
|
33
|
-
:'
|
34
|
-
:'control_type' => :'String'
|
30
|
+
:'name' => :'String',
|
31
|
+
:'self_uri' => :'String'
|
35
32
|
|
36
33
|
}
|
37
34
|
end
|
@@ -47,16 +44,12 @@ module PureCloud
|
|
47
44
|
self.id = attributes[:'id']
|
48
45
|
end
|
49
46
|
|
50
|
-
if attributes[:'
|
51
|
-
self.
|
52
|
-
end
|
53
|
-
|
54
|
-
if attributes[:'dataItemId']
|
55
|
-
self.data_item_id = attributes[:'dataItemId']
|
47
|
+
if attributes[:'name']
|
48
|
+
self.name = attributes[:'name']
|
56
49
|
end
|
57
50
|
|
58
|
-
if attributes[:'
|
59
|
-
self.
|
51
|
+
if attributes[:'selfUri']
|
52
|
+
self.self_uri = attributes[:'selfUri']
|
60
53
|
end
|
61
54
|
|
62
55
|
end
|
@@ -66,9 +59,8 @@ module PureCloud
|
|
66
59
|
return true if self.equal?(o)
|
67
60
|
self.class == o.class &&
|
68
61
|
id == o.id &&
|
69
|
-
|
70
|
-
|
71
|
-
control_type == o.control_type
|
62
|
+
name == o.name &&
|
63
|
+
self_uri == o.self_uri
|
72
64
|
end
|
73
65
|
|
74
66
|
# @see the `==` method
|
@@ -78,7 +70,7 @@ module PureCloud
|
|
78
70
|
|
79
71
|
# Calculate hash code according to all attributes.
|
80
72
|
def hash
|
81
|
-
[id,
|
73
|
+
[id, name, self_uri].hash
|
82
74
|
end
|
83
75
|
|
84
76
|
# build the object from hash
|
@@ -1,16 +1,14 @@
|
|
1
1
|
require 'date'
|
2
2
|
|
3
3
|
module PureCloud
|
4
|
-
|
5
|
-
|
6
|
-
# Change the locked state of the flow definition. True to attempt to lock for modification, false to release the lock.
|
7
|
-
attr_accessor :locked
|
4
|
+
class EdgeLogsJobUploadRequest
|
5
|
+
attr_accessor :file_ids
|
8
6
|
|
9
7
|
# Attribute mapping from ruby-style variable name to JSON key.
|
10
8
|
def self.attribute_map
|
11
9
|
{
|
12
10
|
|
13
|
-
:'
|
11
|
+
:'file_ids' => :'fileIds'
|
14
12
|
|
15
13
|
}
|
16
14
|
end
|
@@ -18,7 +16,7 @@ module PureCloud
|
|
18
16
|
# Attribute type mapping.
|
19
17
|
def self.swagger_types
|
20
18
|
{
|
21
|
-
:'
|
19
|
+
:'file_ids' => :'Array<String>'
|
22
20
|
|
23
21
|
}
|
24
22
|
end
|
@@ -30,10 +28,10 @@ module PureCloud
|
|
30
28
|
attributes = attributes.inject({}){|memo,(k,v)| memo[k.to_sym] = v; memo}
|
31
29
|
|
32
30
|
|
33
|
-
if attributes[:'
|
34
|
-
|
35
|
-
|
36
|
-
|
31
|
+
if attributes[:'fileIds']
|
32
|
+
if (value = attributes[:'fileIds']).is_a?(Array)
|
33
|
+
self.file_ids = value
|
34
|
+
end
|
37
35
|
end
|
38
36
|
|
39
37
|
end
|
@@ -42,7 +40,7 @@ module PureCloud
|
|
42
40
|
def ==(o)
|
43
41
|
return true if self.equal?(o)
|
44
42
|
self.class == o.class &&
|
45
|
-
|
43
|
+
file_ids == o.file_ids
|
46
44
|
end
|
47
45
|
|
48
46
|
# @see the `==` method
|
@@ -52,7 +50,7 @@ module PureCloud
|
|
52
50
|
|
53
51
|
# Calculate hash code according to all attributes.
|
54
52
|
def hash
|
55
|
-
[
|
53
|
+
[file_ids].hash
|
56
54
|
end
|
57
55
|
|
58
56
|
# build the object from hash
|
@@ -25,6 +25,9 @@ module PureCloud
|
|
25
25
|
# Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ
|
26
26
|
attr_accessor :start_hold_time
|
27
27
|
|
28
|
+
# Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ
|
29
|
+
attr_accessor :connected_time
|
30
|
+
|
28
31
|
# Attribute mapping from ruby-style variable name to JSON key.
|
29
32
|
def self.attribute_map
|
30
33
|
{
|
@@ -49,7 +52,9 @@ module PureCloud
|
|
49
52
|
|
50
53
|
:'disconnect_type' => :'disconnectType',
|
51
54
|
|
52
|
-
:'start_hold_time' => :'startHoldTime'
|
55
|
+
:'start_hold_time' => :'startHoldTime',
|
56
|
+
|
57
|
+
:'connected_time' => :'connectedTime'
|
53
58
|
|
54
59
|
}
|
55
60
|
end
|
@@ -67,7 +72,8 @@ module PureCloud
|
|
67
72
|
:'recording_id' => :'String',
|
68
73
|
:'error_info' => :'ErrorBody',
|
69
74
|
:'disconnect_type' => :'String',
|
70
|
-
:'start_hold_time' => :'DateTime'
|
75
|
+
:'start_hold_time' => :'DateTime',
|
76
|
+
:'connected_time' => :'DateTime'
|
71
77
|
|
72
78
|
}
|
73
79
|
end
|
@@ -127,6 +133,10 @@ module PureCloud
|
|
127
133
|
self.start_hold_time = attributes[:'startHoldTime']
|
128
134
|
end
|
129
135
|
|
136
|
+
if attributes[:'connectedTime']
|
137
|
+
self.connected_time = attributes[:'connectedTime']
|
138
|
+
end
|
139
|
+
|
130
140
|
end
|
131
141
|
|
132
142
|
# Custom attribute writer method checking allowed values (enum).
|
@@ -170,7 +180,8 @@ module PureCloud
|
|
170
180
|
recording_id == o.recording_id &&
|
171
181
|
error_info == o.error_info &&
|
172
182
|
disconnect_type == o.disconnect_type &&
|
173
|
-
start_hold_time == o.start_hold_time
|
183
|
+
start_hold_time == o.start_hold_time &&
|
184
|
+
connected_time == o.connected_time
|
174
185
|
end
|
175
186
|
|
176
187
|
# @see the `==` method
|
@@ -180,7 +191,7 @@ module PureCloud
|
|
180
191
|
|
181
192
|
# Calculate hash code according to all attributes.
|
182
193
|
def hash
|
183
|
-
[state, id, held, subject, messages_sent, segments, direction, recording_id, error_info, disconnect_type, start_hold_time].hash
|
194
|
+
[state, id, held, subject, messages_sent, segments, direction, recording_id, error_info, disconnect_type, start_hold_time, connected_time].hash
|
184
195
|
end
|
185
196
|
|
186
197
|
# build the object from hash
|
@@ -100,7 +100,7 @@ module PureCloud
|
|
100
100
|
:'modified_by_app' => :'String',
|
101
101
|
:'created_by_app' => :'String',
|
102
102
|
:'count' => :'Integer',
|
103
|
-
:'properties' => :'Hash<String,
|
103
|
+
:'properties' => :'Hash<String, inline_response_200>',
|
104
104
|
:'schema' => :'UriReference',
|
105
105
|
:'enabled' => :'BOOLEAN',
|
106
106
|
:'site' => :'UriReference',
|
@@ -1,16 +1,15 @@
|
|
1
1
|
require 'date'
|
2
2
|
|
3
3
|
module PureCloud
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
attr_accessor :workspaces
|
4
|
+
class EstimatedWaitTimePredictions
|
5
|
+
# Returned upon a successful estimated wait time request.
|
6
|
+
attr_accessor :results
|
8
7
|
|
9
8
|
# Attribute mapping from ruby-style variable name to JSON key.
|
10
9
|
def self.attribute_map
|
11
10
|
{
|
12
11
|
|
13
|
-
:'
|
12
|
+
:'results' => :'results'
|
14
13
|
|
15
14
|
}
|
16
15
|
end
|
@@ -18,7 +17,7 @@ module PureCloud
|
|
18
17
|
# Attribute type mapping.
|
19
18
|
def self.swagger_types
|
20
19
|
{
|
21
|
-
:'
|
20
|
+
:'results' => :'Array<PredictionResults>'
|
22
21
|
|
23
22
|
}
|
24
23
|
end
|
@@ -30,9 +29,9 @@ module PureCloud
|
|
30
29
|
attributes = attributes.inject({}){|memo,(k,v)| memo[k.to_sym] = v; memo}
|
31
30
|
|
32
31
|
|
33
|
-
if attributes[:'
|
34
|
-
if (value = attributes[:'
|
35
|
-
self.
|
32
|
+
if attributes[:'results']
|
33
|
+
if (value = attributes[:'results']).is_a?(Array)
|
34
|
+
self.results = value
|
36
35
|
end
|
37
36
|
end
|
38
37
|
|
@@ -42,7 +41,7 @@ module PureCloud
|
|
42
41
|
def ==(o)
|
43
42
|
return true if self.equal?(o)
|
44
43
|
self.class == o.class &&
|
45
|
-
|
44
|
+
results == o.results
|
46
45
|
end
|
47
46
|
|
48
47
|
# @see the `==` method
|
@@ -52,7 +51,7 @@ module PureCloud
|
|
52
51
|
|
53
52
|
# Calculate hash code according to all attributes.
|
54
53
|
def hash
|
55
|
-
[
|
54
|
+
[results].hash
|
56
55
|
end
|
57
56
|
|
58
57
|
# build the object from hash
|
@@ -0,0 +1,320 @@
|
|
1
|
+
require 'date'
|
2
|
+
|
3
|
+
module PureCloud
|
4
|
+
class ExternalContact
|
5
|
+
# The globally unique identifier for the object.
|
6
|
+
attr_accessor :id
|
7
|
+
|
8
|
+
attr_accessor :first_name
|
9
|
+
|
10
|
+
attr_accessor :middle_name
|
11
|
+
|
12
|
+
attr_accessor :last_name
|
13
|
+
|
14
|
+
attr_accessor :salutation
|
15
|
+
|
16
|
+
attr_accessor :title
|
17
|
+
|
18
|
+
attr_accessor :work_phone
|
19
|
+
|
20
|
+
attr_accessor :cell_phone
|
21
|
+
|
22
|
+
attr_accessor :home_phone
|
23
|
+
|
24
|
+
attr_accessor :other_phone
|
25
|
+
|
26
|
+
attr_accessor :work_email
|
27
|
+
|
28
|
+
attr_accessor :personal_email
|
29
|
+
|
30
|
+
attr_accessor :other_email
|
31
|
+
|
32
|
+
attr_accessor :address
|
33
|
+
|
34
|
+
# Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ
|
35
|
+
attr_accessor :modify_date
|
36
|
+
|
37
|
+
# Date time is represented as an ISO-8601 string. For example: yyyy-MM-ddTHH:mm:ss.SSSZ
|
38
|
+
attr_accessor :create_date
|
39
|
+
|
40
|
+
attr_accessor :external_organization
|
41
|
+
|
42
|
+
# The URI for this object
|
43
|
+
attr_accessor :self_uri
|
44
|
+
|
45
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
46
|
+
def self.attribute_map
|
47
|
+
{
|
48
|
+
|
49
|
+
:'id' => :'id',
|
50
|
+
|
51
|
+
:'first_name' => :'firstName',
|
52
|
+
|
53
|
+
:'middle_name' => :'middleName',
|
54
|
+
|
55
|
+
:'last_name' => :'lastName',
|
56
|
+
|
57
|
+
:'salutation' => :'salutation',
|
58
|
+
|
59
|
+
:'title' => :'title',
|
60
|
+
|
61
|
+
:'work_phone' => :'workPhone',
|
62
|
+
|
63
|
+
:'cell_phone' => :'cellPhone',
|
64
|
+
|
65
|
+
:'home_phone' => :'homePhone',
|
66
|
+
|
67
|
+
:'other_phone' => :'otherPhone',
|
68
|
+
|
69
|
+
:'work_email' => :'workEmail',
|
70
|
+
|
71
|
+
:'personal_email' => :'personalEmail',
|
72
|
+
|
73
|
+
:'other_email' => :'otherEmail',
|
74
|
+
|
75
|
+
:'address' => :'address',
|
76
|
+
|
77
|
+
:'modify_date' => :'modifyDate',
|
78
|
+
|
79
|
+
:'create_date' => :'createDate',
|
80
|
+
|
81
|
+
:'external_organization' => :'externalOrganization',
|
82
|
+
|
83
|
+
:'self_uri' => :'selfUri'
|
84
|
+
|
85
|
+
}
|
86
|
+
end
|
87
|
+
|
88
|
+
# Attribute type mapping.
|
89
|
+
def self.swagger_types
|
90
|
+
{
|
91
|
+
:'id' => :'String',
|
92
|
+
:'first_name' => :'String',
|
93
|
+
:'middle_name' => :'String',
|
94
|
+
:'last_name' => :'String',
|
95
|
+
:'salutation' => :'String',
|
96
|
+
:'title' => :'String',
|
97
|
+
:'work_phone' => :'PhoneNumber',
|
98
|
+
:'cell_phone' => :'PhoneNumber',
|
99
|
+
:'home_phone' => :'PhoneNumber',
|
100
|
+
:'other_phone' => :'PhoneNumber',
|
101
|
+
:'work_email' => :'String',
|
102
|
+
:'personal_email' => :'String',
|
103
|
+
:'other_email' => :'String',
|
104
|
+
:'address' => :'Address',
|
105
|
+
:'modify_date' => :'DateTime',
|
106
|
+
:'create_date' => :'DateTime',
|
107
|
+
:'external_organization' => :'ExternalOrganization',
|
108
|
+
:'self_uri' => :'String'
|
109
|
+
|
110
|
+
}
|
111
|
+
end
|
112
|
+
|
113
|
+
def initialize(attributes = {})
|
114
|
+
return unless attributes.is_a?(Hash)
|
115
|
+
|
116
|
+
# convert string to symbol for hash key
|
117
|
+
attributes = attributes.inject({}){|memo,(k,v)| memo[k.to_sym] = v; memo}
|
118
|
+
|
119
|
+
|
120
|
+
if attributes[:'id']
|
121
|
+
self.id = attributes[:'id']
|
122
|
+
end
|
123
|
+
|
124
|
+
if attributes[:'firstName']
|
125
|
+
self.first_name = attributes[:'firstName']
|
126
|
+
end
|
127
|
+
|
128
|
+
if attributes[:'middleName']
|
129
|
+
self.middle_name = attributes[:'middleName']
|
130
|
+
end
|
131
|
+
|
132
|
+
if attributes[:'lastName']
|
133
|
+
self.last_name = attributes[:'lastName']
|
134
|
+
end
|
135
|
+
|
136
|
+
if attributes[:'salutation']
|
137
|
+
self.salutation = attributes[:'salutation']
|
138
|
+
end
|
139
|
+
|
140
|
+
if attributes[:'title']
|
141
|
+
self.title = attributes[:'title']
|
142
|
+
end
|
143
|
+
|
144
|
+
if attributes[:'workPhone']
|
145
|
+
self.work_phone = attributes[:'workPhone']
|
146
|
+
end
|
147
|
+
|
148
|
+
if attributes[:'cellPhone']
|
149
|
+
self.cell_phone = attributes[:'cellPhone']
|
150
|
+
end
|
151
|
+
|
152
|
+
if attributes[:'homePhone']
|
153
|
+
self.home_phone = attributes[:'homePhone']
|
154
|
+
end
|
155
|
+
|
156
|
+
if attributes[:'otherPhone']
|
157
|
+
self.other_phone = attributes[:'otherPhone']
|
158
|
+
end
|
159
|
+
|
160
|
+
if attributes[:'workEmail']
|
161
|
+
self.work_email = attributes[:'workEmail']
|
162
|
+
end
|
163
|
+
|
164
|
+
if attributes[:'personalEmail']
|
165
|
+
self.personal_email = attributes[:'personalEmail']
|
166
|
+
end
|
167
|
+
|
168
|
+
if attributes[:'otherEmail']
|
169
|
+
self.other_email = attributes[:'otherEmail']
|
170
|
+
end
|
171
|
+
|
172
|
+
if attributes[:'address']
|
173
|
+
self.address = attributes[:'address']
|
174
|
+
end
|
175
|
+
|
176
|
+
if attributes[:'modifyDate']
|
177
|
+
self.modify_date = attributes[:'modifyDate']
|
178
|
+
end
|
179
|
+
|
180
|
+
if attributes[:'createDate']
|
181
|
+
self.create_date = attributes[:'createDate']
|
182
|
+
end
|
183
|
+
|
184
|
+
if attributes[:'externalOrganization']
|
185
|
+
self.external_organization = attributes[:'externalOrganization']
|
186
|
+
end
|
187
|
+
|
188
|
+
if attributes[:'selfUri']
|
189
|
+
self.self_uri = attributes[:'selfUri']
|
190
|
+
end
|
191
|
+
|
192
|
+
end
|
193
|
+
|
194
|
+
# Check equality by comparing each attribute.
|
195
|
+
def ==(o)
|
196
|
+
return true if self.equal?(o)
|
197
|
+
self.class == o.class &&
|
198
|
+
id == o.id &&
|
199
|
+
first_name == o.first_name &&
|
200
|
+
middle_name == o.middle_name &&
|
201
|
+
last_name == o.last_name &&
|
202
|
+
salutation == o.salutation &&
|
203
|
+
title == o.title &&
|
204
|
+
work_phone == o.work_phone &&
|
205
|
+
cell_phone == o.cell_phone &&
|
206
|
+
home_phone == o.home_phone &&
|
207
|
+
other_phone == o.other_phone &&
|
208
|
+
work_email == o.work_email &&
|
209
|
+
personal_email == o.personal_email &&
|
210
|
+
other_email == o.other_email &&
|
211
|
+
address == o.address &&
|
212
|
+
modify_date == o.modify_date &&
|
213
|
+
create_date == o.create_date &&
|
214
|
+
external_organization == o.external_organization &&
|
215
|
+
self_uri == o.self_uri
|
216
|
+
end
|
217
|
+
|
218
|
+
# @see the `==` method
|
219
|
+
def eql?(o)
|
220
|
+
self == o
|
221
|
+
end
|
222
|
+
|
223
|
+
# Calculate hash code according to all attributes.
|
224
|
+
def hash
|
225
|
+
[id, first_name, middle_name, last_name, salutation, title, work_phone, cell_phone, home_phone, other_phone, work_email, personal_email, other_email, address, modify_date, create_date, external_organization, self_uri].hash
|
226
|
+
end
|
227
|
+
|
228
|
+
# build the object from hash
|
229
|
+
def build_from_hash(attributes)
|
230
|
+
return nil unless attributes.is_a?(Hash)
|
231
|
+
self.class.swagger_types.each_pair do |key, type|
|
232
|
+
if type =~ /^Array<(.*)>/i
|
233
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
234
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
235
|
+
else
|
236
|
+
#TODO show warning in debug mode
|
237
|
+
end
|
238
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
239
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
240
|
+
else
|
241
|
+
# data not found in attributes(hash), not an issue as the data can be optional
|
242
|
+
end
|
243
|
+
end
|
244
|
+
|
245
|
+
self
|
246
|
+
end
|
247
|
+
|
248
|
+
def _deserialize(type, value)
|
249
|
+
case type.to_sym
|
250
|
+
when :DateTime
|
251
|
+
DateTime.parse(value)
|
252
|
+
when :Date
|
253
|
+
Date.parse(value)
|
254
|
+
when :String
|
255
|
+
value.to_s
|
256
|
+
when :Integer
|
257
|
+
value.to_i
|
258
|
+
when :Float
|
259
|
+
value.to_f
|
260
|
+
when :BOOLEAN
|
261
|
+
if value =~ /^(true|t|yes|y|1)$/i
|
262
|
+
true
|
263
|
+
else
|
264
|
+
false
|
265
|
+
end
|
266
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
267
|
+
inner_type = Regexp.last_match[:inner_type]
|
268
|
+
value.map { |v| _deserialize(inner_type, v) }
|
269
|
+
when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
|
270
|
+
k_type = Regexp.last_match[:k_type]
|
271
|
+
v_type = Regexp.last_match[:v_type]
|
272
|
+
{}.tap do |hash|
|
273
|
+
value.each do |k, v|
|
274
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
275
|
+
end
|
276
|
+
end
|
277
|
+
else # model
|
278
|
+
_model = Object.const_get("PureCloud").const_get(type).new
|
279
|
+
_model.build_from_hash(value)
|
280
|
+
end
|
281
|
+
end
|
282
|
+
|
283
|
+
def to_s
|
284
|
+
to_hash.to_s
|
285
|
+
end
|
286
|
+
|
287
|
+
# to_body is an alias to to_body (backward compatibility))
|
288
|
+
def to_body
|
289
|
+
to_hash
|
290
|
+
end
|
291
|
+
|
292
|
+
# return the object in the form of hash
|
293
|
+
def to_hash
|
294
|
+
hash = {}
|
295
|
+
self.class.attribute_map.each_pair do |attr, param|
|
296
|
+
value = self.send(attr)
|
297
|
+
next if value.nil?
|
298
|
+
hash[param] = _to_hash(value)
|
299
|
+
end
|
300
|
+
hash
|
301
|
+
end
|
302
|
+
|
303
|
+
# Method to output non-array value in the form of hash
|
304
|
+
# For object, use to_hash. Otherwise, just return the value
|
305
|
+
def _to_hash(value)
|
306
|
+
if value.is_a?(Array)
|
307
|
+
value.compact.map{ |v| _to_hash(v) }
|
308
|
+
elsif value.is_a?(Hash)
|
309
|
+
{}.tap do |hash|
|
310
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
311
|
+
end
|
312
|
+
elsif value.respond_to? :to_hash
|
313
|
+
value.to_hash
|
314
|
+
else
|
315
|
+
value
|
316
|
+
end
|
317
|
+
end
|
318
|
+
|
319
|
+
end
|
320
|
+
end
|