sunshine-conversations-client 9.13.0 → 9.14.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 5cb0ebcda41a5659e4a3dc8b68724deea5548fc8
4
- data.tar.gz: bd4ce4079e45358d2b59573c622a008b52c9b93c
3
+ metadata.gz: 7d65b7494c171337f1633e14fd0b13b50b3c8839
4
+ data.tar.gz: cbcacc433aad44b98bfcf0df04ecfe56efc382be
5
5
  SHA512:
6
- metadata.gz: 431ea779fb02dec1c48de55ca54c5a0de3a7c829c497f66d39956c5545915f1e3d96386b63b8e0997b751b83fdd2ed0a03827f4884e9ad6a37278342ca50a1bf
7
- data.tar.gz: ea095ebfd0810596e3859703e68614c7cb6fd2d7192e2f0815ac97c5a653d1f14564e419c3e2f26f4b47793d168761e36d537c9db66189a03f540fab0dbc126c
6
+ metadata.gz: e99187f5f996bac41c2ffb3b442a076d5340d7e990e50b165ebcef1f533bda9df0b5c6138c775fef2b4a8b6440697d04d4d62e80f6be32024d832ccba5597f36
7
+ data.tar.gz: 61a642d8a50baa8f83fe9f908aadf491a102732c2173780a1c166b4b757a8e7d181223a19e6293e447aa03bada7e989fe82ca0342dddf7c024519439a05c3fe2
data/CHANGELOG_RB.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## [9.14.0] - 2023-04-10
4
+
5
+ ### Added
6
+
7
+ - Added a new `identities` read only property on the user object.
8
+
3
9
  ## [9.13.0] - 2023-03-30
4
10
 
5
11
  ### Added
data/README.md CHANGED
@@ -5,7 +5,7 @@ SunshineConversationsClient - the Ruby gem for the Sunshine Conversations API
5
5
  This SDK is automatically generated by the [OpenAPI Generator Codegen](https://github.com/OpenAPITools/openapi-generator) project using the [Sunshine Conversations API spec](https://github.com/zendesk/sunshine-conversations-api-spec).
6
6
 
7
7
  - API version: 9.12.0
8
- - Package version: 9.13.0
8
+ - Package version: 9.14.0
9
9
  - Build package: org.openapitools.codegen.languages.RubyClientCodegen
10
10
 
11
11
  ## Sunshine Conversations API Version
@@ -32,16 +32,16 @@ gem build sunshine-conversations-client.gemspec
32
32
  Then either install the gem locally:
33
33
 
34
34
  ```shell
35
- gem install ./sunshine-conversations-client-9.13.0.gem
35
+ gem install ./sunshine-conversations-client-9.14.0.gem
36
36
  ```
37
37
 
38
- (for development, run `gem install --dev ./sunshine-conversations-client-9.13.0.gem` to install the development dependencies)
38
+ (for development, run `gem install --dev ./sunshine-conversations-client-9.14.0.gem` to install the development dependencies)
39
39
 
40
40
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
41
41
 
42
42
  Finally add this to the Gemfile:
43
43
 
44
- gem 'sunshine-conversations-client', '~> 9.13.0'
44
+ gem 'sunshine-conversations-client', '~> 9.14.0'
45
45
 
46
46
  ### Install from Git
47
47
 
@@ -312,6 +312,7 @@ Class | Method | HTTP request | Description
312
312
  - [SunshineConversationsClient::FileMessage](docs/FileMessage.md)
313
313
  - [SunshineConversationsClient::FormMessage](docs/FormMessage.md)
314
314
  - [SunshineConversationsClient::FormResponseMessage](docs/FormResponseMessage.md)
315
+ - [SunshineConversationsClient::Identity](docs/Identity.md)
315
316
  - [SunshineConversationsClient::ImageMessage](docs/ImageMessage.md)
316
317
  - [SunshineConversationsClient::InlineObject](docs/InlineObject.md)
317
318
  - [SunshineConversationsClient::Instagram](docs/Instagram.md)
data/docs/Identity.md ADDED
@@ -0,0 +1,21 @@
1
+ # SunshineConversationsClient::Identity
2
+
3
+ ## Properties
4
+
5
+ Name | Type | Description | Notes
6
+ ------------ | ------------- | ------------- | -------------
7
+ **type** | **String** | The type of identity. | [optional]
8
+ **value** | **String** | The identity value. | [optional]
9
+ **verification** | **String** | The type of verification performed on the identity. | [optional]
10
+
11
+ ## Code Sample
12
+
13
+ ```ruby
14
+ require 'SunshineConversationsClient'
15
+
16
+ instance = SunshineConversationsClient::Identity.new(type: email,
17
+ value: jane.doe@gmail.com,
18
+ verification: embed)
19
+ ```
20
+
21
+
data/docs/User.md CHANGED
@@ -9,6 +9,7 @@ Name | Type | Description | Notes
9
9
  **signed_up_at** | **String** | | [optional]
10
10
  **profile** | [**Profile**](Profile.md) | | [optional]
11
11
  **metadata** | **Object** | | [optional]
12
+ **identities** | [**Array<Identity>**](Identity.md) | The user's connected identities. | [optional] [readonly]
12
13
 
13
14
  ## Code Sample
14
15
 
@@ -19,7 +20,8 @@ instance = SunshineConversationsClient::User.new(id: 7494535bff5cef41a15be74d,
19
20
  external_id: your-own-id,
20
21
  signed_up_at: null,
21
22
  profile: null,
22
- metadata: null)
23
+ metadata: null,
24
+ identities: null)
23
25
  ```
24
26
 
25
27
 
data/docs/UserAllOf.md CHANGED
@@ -7,6 +7,7 @@ Name | Type | Description | Notes
7
7
  **signed_up_at** | **String** | | [optional]
8
8
  **profile** | [**Profile**](Profile.md) | | [optional]
9
9
  **metadata** | **Object** | | [optional]
10
+ **identities** | [**Array<Identity>**](Identity.md) | The user's connected identities. | [optional] [readonly]
10
11
 
11
12
  ## Code Sample
12
13
 
@@ -15,7 +16,8 @@ require 'SunshineConversationsClient'
15
16
 
16
17
  instance = SunshineConversationsClient::UserAllOf.new(signed_up_at: null,
17
18
  profile: null,
18
- metadata: null)
19
+ metadata: null,
20
+ identities: null)
19
21
  ```
20
22
 
21
23
 
@@ -0,0 +1,249 @@
1
+ =begin
2
+ #Sunshine Conversations API
3
+
4
+ The version of the OpenAPI document: 9.12.0
5
+
6
+ Generated by: https://openapi-generator.tech
7
+ OpenAPI Generator version: 4.3.1
8
+ =end
9
+
10
+ require 'date'
11
+
12
+ module SunshineConversationsClient
13
+ # A connected user identity, such as an email.
14
+ class Identity
15
+ # The type of identity.
16
+ attr_accessor :type
17
+
18
+ # The identity value.
19
+ attr_accessor :value
20
+
21
+ # The type of verification performed on the identity.
22
+ attr_accessor :verification
23
+
24
+ # Attribute mapping from ruby-style variable name to JSON key.
25
+ def self.attribute_map
26
+ {
27
+ :'type' => :'type',
28
+ :'value' => :'value',
29
+ :'verification' => :'verification'
30
+ }
31
+ end
32
+
33
+ # Attribute type mapping.
34
+ def self.openapi_types
35
+ {
36
+ :'type' => :'String',
37
+ :'value' => :'String',
38
+ :'verification' => :'String'
39
+ }
40
+ end
41
+
42
+ # List of attributes with nullable: true
43
+ def self.openapi_nullable
44
+ Set.new([
45
+ ])
46
+ end
47
+
48
+ # Initializes the object
49
+ # @param [Hash] attributes Model attributes in the form of hash
50
+ def initialize(attributes = {})
51
+ if (!attributes.is_a?(Hash))
52
+ fail ArgumentError, "The input argument (attributes) must be a hash in `SunshineConversationsClient::Identity` initialize method"
53
+ end
54
+
55
+ # check to see if the attribute exists and convert string to symbol for hash key
56
+ attributes = attributes.each_with_object({}) { |(k, v), h|
57
+ if (!self.class.attribute_map.key?(k.to_sym))
58
+ fail ArgumentError, "`#{k}` is not a valid attribute in `SunshineConversationsClient::Identity`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
59
+ end
60
+ h[k.to_sym] = v
61
+ }
62
+
63
+ if attributes.key?(:'type')
64
+ self.type = attributes[:'type']
65
+ end
66
+
67
+ if attributes.key?(:'value')
68
+ self.value = attributes[:'value']
69
+ end
70
+
71
+ if attributes.key?(:'verification')
72
+ self.verification = attributes[:'verification']
73
+ end
74
+ end
75
+
76
+ # Show invalid properties with the reasons. Usually used together with valid?
77
+ # @return Array for valid properties with the reasons
78
+ def list_invalid_properties
79
+ invalid_properties = Array.new
80
+ if !@value.nil? && @value.to_s.length > 128
81
+ invalid_properties.push('invalid value for "value", the character length must be smaller than or equal to 128.')
82
+ end
83
+
84
+ if !@value.nil? && @value.to_s.length < 1
85
+ invalid_properties.push('invalid value for "value", the character length must be great than or equal to 1.')
86
+ end
87
+
88
+ invalid_properties
89
+ end
90
+
91
+ # Check to see if the all the properties in the model are valid
92
+ # @return true if the model is valid
93
+ def valid?
94
+ return false if !@value.nil? && @value.to_s.length > 128
95
+ return false if !@value.nil? && @value.to_s.length < 1
96
+ true
97
+ end
98
+
99
+ # Custom attribute writer method with validation
100
+ # @param [Object] value Value to be assigned
101
+ def value=(value)
102
+ if !value.nil? && value.to_s.length > 128
103
+ fail ArgumentError, 'invalid value for "value", the character length must be smaller than or equal to 128.'
104
+ end
105
+
106
+ if !value.nil? && value.to_s.length < 1
107
+ fail ArgumentError, 'invalid value for "value", the character length must be great than or equal to 1.'
108
+ end
109
+
110
+ @value = value
111
+ end
112
+
113
+ # Checks equality by comparing each attribute.
114
+ # @param [Object] Object to be compared
115
+ def ==(o)
116
+ return true if self.equal?(o)
117
+ self.class == o.class &&
118
+ type == o.type &&
119
+ value == o.value &&
120
+ verification == o.verification
121
+ end
122
+
123
+ # @see the `==` method
124
+ # @param [Object] Object to be compared
125
+ def eql?(o)
126
+ self == o
127
+ end
128
+
129
+ # Calculates hash code according to all attributes.
130
+ # @return [Integer] Hash code
131
+ def hash
132
+ [type, value, verification].hash
133
+ end
134
+
135
+ # Builds the object from hash
136
+ # @param [Hash] attributes Model attributes in the form of hash
137
+ # @return [Object] Returns the model itself
138
+ def self.build_from_hash(attributes)
139
+ new.build_from_hash(attributes)
140
+ end
141
+
142
+ # Builds the object from hash
143
+ # @param [Hash] attributes Model attributes in the form of hash
144
+ # @return [Object] Returns the model itself
145
+ def build_from_hash(attributes)
146
+ return nil unless attributes.is_a?(Hash)
147
+ self.class.openapi_types.each_pair do |key, type|
148
+ if type =~ /\AArray<(.*)>/i
149
+ # check to ensure the input is an array given that the attribute
150
+ # is documented as an array but the input is not
151
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
152
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
153
+ end
154
+ elsif !attributes[self.class.attribute_map[key]].nil?
155
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
156
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
157
+ end
158
+
159
+ self
160
+ end
161
+
162
+ # Deserializes the data based on type
163
+ # @param string type Data type
164
+ # @param string value Value to be deserialized
165
+ # @return [Object] Deserialized data
166
+ def _deserialize(type, value)
167
+ case type.to_sym
168
+ when :DateTime
169
+ DateTime.parse(value)
170
+ when :Date
171
+ Date.parse(value)
172
+ when :String
173
+ value.to_s
174
+ when :Integer
175
+ value.to_i
176
+ when :Float
177
+ value.to_f
178
+ when :Boolean
179
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
180
+ true
181
+ else
182
+ false
183
+ end
184
+ when :Object
185
+ # generic object (usually a Hash), return directly
186
+ value
187
+ when /\AArray<(?<inner_type>.+)>\z/
188
+ inner_type = Regexp.last_match[:inner_type]
189
+ value.map { |v| _deserialize(inner_type, v) }
190
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
191
+ k_type = Regexp.last_match[:k_type]
192
+ v_type = Regexp.last_match[:v_type]
193
+ {}.tap do |hash|
194
+ value.each do |k, v|
195
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
196
+ end
197
+ end
198
+ else # model
199
+ SunshineConversationsClient.const_get(type).build_from_hash(value)
200
+ end
201
+ end
202
+
203
+ # Returns the string representation of the object
204
+ # @return [String] String presentation of the object
205
+ def to_s
206
+ to_hash.to_s
207
+ end
208
+
209
+ # to_body is an alias to to_hash (backward compatibility)
210
+ # @return [Hash] Returns the object in the form of hash
211
+ def to_body
212
+ to_hash
213
+ end
214
+
215
+ # Returns the object in the form of hash
216
+ # @return [Hash] Returns the object in the form of hash
217
+ def to_hash
218
+ hash = {}
219
+ self.class.attribute_map.each_pair do |attr, param|
220
+ value = self.send(attr)
221
+ if value.nil?
222
+ is_nullable = self.class.openapi_nullable.include?(attr)
223
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
224
+ end
225
+
226
+ hash[param] = _to_hash(value)
227
+ end
228
+ hash
229
+ end
230
+
231
+ # Outputs non-array value in the form of hash
232
+ # For object, use to_hash. Otherwise, just return the value
233
+ # @param [Object] value Any valid value
234
+ # @return [Hash] Returns the value in the form of hash
235
+ def _to_hash(value)
236
+ if value.is_a?(Array)
237
+ value.compact.map { |v| _to_hash(v) }
238
+ elsif value.is_a?(Hash)
239
+ {}.tap do |hash|
240
+ value.each { |k, v| hash[k] = _to_hash(v) }
241
+ end
242
+ elsif value.respond_to? :to_hash
243
+ value.to_hash
244
+ else
245
+ value
246
+ end
247
+ end
248
+ end
249
+ end
@@ -23,6 +23,9 @@ module SunshineConversationsClient
23
23
 
24
24
  attr_accessor :metadata
25
25
 
26
+ # The user's connected identities.
27
+ attr_accessor :identities
28
+
26
29
  # Attribute mapping from ruby-style variable name to JSON key.
27
30
  def self.attribute_map
28
31
  {
@@ -30,7 +33,8 @@ module SunshineConversationsClient
30
33
  :'external_id' => :'externalId',
31
34
  :'signed_up_at' => :'signedUpAt',
32
35
  :'profile' => :'profile',
33
- :'metadata' => :'metadata'
36
+ :'metadata' => :'metadata',
37
+ :'identities' => :'identities'
34
38
  }
35
39
  end
36
40
 
@@ -41,7 +45,8 @@ module SunshineConversationsClient
41
45
  :'external_id' => :'String',
42
46
  :'signed_up_at' => :'String',
43
47
  :'profile' => :'Profile',
44
- :'metadata' => :'Object'
48
+ :'metadata' => :'Object',
49
+ :'identities' => :'Array<Identity>'
45
50
  }
46
51
  end
47
52
 
@@ -94,6 +99,9 @@ module SunshineConversationsClient
94
99
  if attributes.key?(:'metadata')
95
100
  self.metadata = attributes[:'metadata']
96
101
  end
102
+
103
+ if attributes.key?(:'identities')
104
+ end
97
105
  end
98
106
 
99
107
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -118,7 +126,8 @@ module SunshineConversationsClient
118
126
  external_id == o.external_id &&
119
127
  signed_up_at == o.signed_up_at &&
120
128
  profile == o.profile &&
121
- metadata == o.metadata
129
+ metadata == o.metadata &&
130
+ identities == o.identities
122
131
  end
123
132
 
124
133
  # @see the `==` method
@@ -130,7 +139,7 @@ module SunshineConversationsClient
130
139
  # Calculates hash code according to all attributes.
131
140
  # @return [Integer] Hash code
132
141
  def hash
133
- [id, external_id, signed_up_at, profile, metadata].hash
142
+ [id, external_id, signed_up_at, profile, metadata, identities].hash
134
143
  end
135
144
 
136
145
  # Builds the object from hash
@@ -17,12 +17,16 @@ module SunshineConversationsClient
17
17
 
18
18
  attr_accessor :metadata
19
19
 
20
+ # The user's connected identities.
21
+ attr_accessor :identities
22
+
20
23
  # Attribute mapping from ruby-style variable name to JSON key.
21
24
  def self.attribute_map
22
25
  {
23
26
  :'signed_up_at' => :'signedUpAt',
24
27
  :'profile' => :'profile',
25
- :'metadata' => :'metadata'
28
+ :'metadata' => :'metadata',
29
+ :'identities' => :'identities'
26
30
  }
27
31
  end
28
32
 
@@ -31,7 +35,8 @@ module SunshineConversationsClient
31
35
  {
32
36
  :'signed_up_at' => :'String',
33
37
  :'profile' => :'Profile',
34
- :'metadata' => :'Object'
38
+ :'metadata' => :'Object',
39
+ :'identities' => :'Array<Identity>'
35
40
  }
36
41
  end
37
42
 
@@ -67,6 +72,9 @@ module SunshineConversationsClient
67
72
  if attributes.key?(:'metadata')
68
73
  self.metadata = attributes[:'metadata']
69
74
  end
75
+
76
+ if attributes.key?(:'identities')
77
+ end
70
78
  end
71
79
 
72
80
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -89,7 +97,8 @@ module SunshineConversationsClient
89
97
  self.class == o.class &&
90
98
  signed_up_at == o.signed_up_at &&
91
99
  profile == o.profile &&
92
- metadata == o.metadata
100
+ metadata == o.metadata &&
101
+ identities == o.identities
93
102
  end
94
103
 
95
104
  # @see the `==` method
@@ -101,7 +110,7 @@ module SunshineConversationsClient
101
110
  # Calculates hash code according to all attributes.
102
111
  # @return [Integer] Hash code
103
112
  def hash
104
- [signed_up_at, profile, metadata].hash
113
+ [signed_up_at, profile, metadata, identities].hash
105
114
  end
106
115
 
107
116
  # Builds the object from hash
@@ -8,5 +8,5 @@ OpenAPI Generator version: 4.3.1
8
8
  =end
9
9
 
10
10
  module SunshineConversationsClient
11
- VERSION = '9.13.0'
11
+ VERSION = '9.14.0'
12
12
  end
@@ -138,6 +138,7 @@ require 'sunshine-conversations-client/models/field'
138
138
  require 'sunshine-conversations-client/models/file_message'
139
139
  require 'sunshine-conversations-client/models/form_message'
140
140
  require 'sunshine-conversations-client/models/form_response_message'
141
+ require 'sunshine-conversations-client/models/identity'
141
142
  require 'sunshine-conversations-client/models/image_message'
142
143
  require 'sunshine-conversations-client/models/inline_object'
143
144
  require 'sunshine-conversations-client/models/instagram'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sunshine-conversations-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 9.13.0
4
+ version: 9.14.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sunshine Conversations
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-03-30 00:00:00.000000000 Z
11
+ date: 2023-04-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -203,6 +203,7 @@ files:
203
203
  - docs/FileMessage.md
204
204
  - docs/FormMessage.md
205
205
  - docs/FormResponseMessage.md
206
+ - docs/Identity.md
206
207
  - docs/ImageMessage.md
207
208
  - docs/InlineObject.md
208
209
  - docs/Instagram.md
@@ -508,6 +509,7 @@ files:
508
509
  - lib/sunshine-conversations-client/models/file_message.rb
509
510
  - lib/sunshine-conversations-client/models/form_message.rb
510
511
  - lib/sunshine-conversations-client/models/form_response_message.rb
512
+ - lib/sunshine-conversations-client/models/identity.rb
511
513
  - lib/sunshine-conversations-client/models/image_message.rb
512
514
  - lib/sunshine-conversations-client/models/inline_object.rb
513
515
  - lib/sunshine-conversations-client/models/instagram.rb