mailslurp_client 15.3.1 → 15.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mailslurp_client/api/email_controller_api.rb +70 -0
- data/lib/mailslurp_client/api/inbox_controller_api.rb +190 -0
- data/lib/mailslurp_client/models/alias_projection.rb +13 -13
- data/lib/mailslurp_client/models/attachment_projection.rb +15 -15
- data/lib/mailslurp_client/models/contact_projection.rb +13 -13
- data/lib/mailslurp_client/models/create_inbox_dto.rb +1 -1
- data/lib/mailslurp_client/models/email_projection.rb +10 -10
- data/lib/mailslurp_client/models/imap_flag_operation_options.rb +261 -0
- data/lib/mailslurp_client/models/imap_smtp_access_details.rb +309 -0
- data/lib/mailslurp_client/models/inbox_by_email_address_result.rb +220 -0
- data/lib/mailslurp_client/models/send_smtp_envelope_options.rb +242 -0
- data/lib/mailslurp_client/models/sent_email_projection.rb +15 -15
- data/lib/mailslurp_client/models/template_projection.rb +15 -15
- data/lib/mailslurp_client/models/thread_projection.rb +10 -10
- data/lib/mailslurp_client/version.rb +1 -1
- data/lib/mailslurp_client.rb +4 -0
- metadata +6 -2
@@ -0,0 +1,220 @@
|
|
1
|
+
=begin
|
2
|
+
#MailSlurp API
|
3
|
+
|
4
|
+
#MailSlurp is an API for sending and receiving emails from dynamically allocated email addresses. It's designed for developers and QA teams to test applications, process inbound emails, send templated notifications, attachments, and more. ## Resources - [Homepage](https://www.mailslurp.com) - Get an [API KEY](https://app.mailslurp.com/sign-up/) - Generated [SDK Clients](https://www.mailslurp.com/docs/) - [Examples](https://github.com/mailslurp/examples) repository
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 6.5.2
|
7
|
+
Contact: contact@mailslurp.dev
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module MailSlurpClient
|
16
|
+
class InboxByEmailAddressResult
|
17
|
+
attr_accessor :inbox_id
|
18
|
+
|
19
|
+
attr_accessor :exists
|
20
|
+
|
21
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
22
|
+
def self.attribute_map
|
23
|
+
{
|
24
|
+
:'inbox_id' => :'inboxId',
|
25
|
+
:'exists' => :'exists'
|
26
|
+
}
|
27
|
+
end
|
28
|
+
|
29
|
+
# Attribute type mapping.
|
30
|
+
def self.openapi_types
|
31
|
+
{
|
32
|
+
:'inbox_id' => :'String',
|
33
|
+
:'exists' => :'Boolean'
|
34
|
+
}
|
35
|
+
end
|
36
|
+
|
37
|
+
# List of attributes with nullable: true
|
38
|
+
def self.openapi_nullable
|
39
|
+
Set.new([
|
40
|
+
])
|
41
|
+
end
|
42
|
+
|
43
|
+
# Initializes the object
|
44
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
45
|
+
def initialize(attributes = {})
|
46
|
+
if (!attributes.is_a?(Hash))
|
47
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `MailSlurpClient::InboxByEmailAddressResult` initialize method"
|
48
|
+
end
|
49
|
+
|
50
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
51
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
52
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
53
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `MailSlurpClient::InboxByEmailAddressResult`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
54
|
+
end
|
55
|
+
h[k.to_sym] = v
|
56
|
+
}
|
57
|
+
|
58
|
+
if attributes.key?(:'inbox_id')
|
59
|
+
self.inbox_id = attributes[:'inbox_id']
|
60
|
+
end
|
61
|
+
|
62
|
+
if attributes.key?(:'exists')
|
63
|
+
self.exists = attributes[:'exists']
|
64
|
+
end
|
65
|
+
end
|
66
|
+
|
67
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
68
|
+
# @return Array for valid properties with the reasons
|
69
|
+
def list_invalid_properties
|
70
|
+
invalid_properties = Array.new
|
71
|
+
if @exists.nil?
|
72
|
+
invalid_properties.push('invalid value for "exists", exists cannot be nil.')
|
73
|
+
end
|
74
|
+
|
75
|
+
invalid_properties
|
76
|
+
end
|
77
|
+
|
78
|
+
# Check to see if the all the properties in the model are valid
|
79
|
+
# @return true if the model is valid
|
80
|
+
def valid?
|
81
|
+
return false if @exists.nil?
|
82
|
+
true
|
83
|
+
end
|
84
|
+
|
85
|
+
# Checks equality by comparing each attribute.
|
86
|
+
# @param [Object] Object to be compared
|
87
|
+
def ==(o)
|
88
|
+
return true if self.equal?(o)
|
89
|
+
self.class == o.class &&
|
90
|
+
inbox_id == o.inbox_id &&
|
91
|
+
exists == o.exists
|
92
|
+
end
|
93
|
+
|
94
|
+
# @see the `==` method
|
95
|
+
# @param [Object] Object to be compared
|
96
|
+
def eql?(o)
|
97
|
+
self == o
|
98
|
+
end
|
99
|
+
|
100
|
+
# Calculates hash code according to all attributes.
|
101
|
+
# @return [Integer] Hash code
|
102
|
+
def hash
|
103
|
+
[inbox_id, exists].hash
|
104
|
+
end
|
105
|
+
|
106
|
+
# Builds the object from hash
|
107
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
108
|
+
# @return [Object] Returns the model itself
|
109
|
+
def self.build_from_hash(attributes)
|
110
|
+
new.build_from_hash(attributes)
|
111
|
+
end
|
112
|
+
|
113
|
+
# Builds the object from hash
|
114
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
115
|
+
# @return [Object] Returns the model itself
|
116
|
+
def build_from_hash(attributes)
|
117
|
+
return nil unless attributes.is_a?(Hash)
|
118
|
+
self.class.openapi_types.each_pair do |key, type|
|
119
|
+
if type =~ /\AArray<(.*)>/i
|
120
|
+
# check to ensure the input is an array given that the attribute
|
121
|
+
# is documented as an array but the input is not
|
122
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
123
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
124
|
+
end
|
125
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
126
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
127
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
128
|
+
end
|
129
|
+
|
130
|
+
self
|
131
|
+
end
|
132
|
+
|
133
|
+
# Deserializes the data based on type
|
134
|
+
# @param string type Data type
|
135
|
+
# @param string value Value to be deserialized
|
136
|
+
# @return [Object] Deserialized data
|
137
|
+
def _deserialize(type, value)
|
138
|
+
case type.to_sym
|
139
|
+
when :DateTime
|
140
|
+
DateTime.parse(value)
|
141
|
+
when :Date
|
142
|
+
Date.parse(value)
|
143
|
+
when :String
|
144
|
+
value.to_s
|
145
|
+
when :Integer
|
146
|
+
value.to_i
|
147
|
+
when :Float
|
148
|
+
value.to_f
|
149
|
+
when :Boolean
|
150
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
151
|
+
true
|
152
|
+
else
|
153
|
+
false
|
154
|
+
end
|
155
|
+
when :Object
|
156
|
+
# generic object (usually a Hash), return directly
|
157
|
+
value
|
158
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
159
|
+
inner_type = Regexp.last_match[:inner_type]
|
160
|
+
value.map { |v| _deserialize(inner_type, v) }
|
161
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
162
|
+
k_type = Regexp.last_match[:k_type]
|
163
|
+
v_type = Regexp.last_match[:v_type]
|
164
|
+
{}.tap do |hash|
|
165
|
+
value.each do |k, v|
|
166
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
167
|
+
end
|
168
|
+
end
|
169
|
+
else # model
|
170
|
+
MailSlurpClient.const_get(type).build_from_hash(value)
|
171
|
+
end
|
172
|
+
end
|
173
|
+
|
174
|
+
# Returns the string representation of the object
|
175
|
+
# @return [String] String presentation of the object
|
176
|
+
def to_s
|
177
|
+
to_hash.to_s
|
178
|
+
end
|
179
|
+
|
180
|
+
# to_body is an alias to to_hash (backward compatibility)
|
181
|
+
# @return [Hash] Returns the object in the form of hash
|
182
|
+
def to_body
|
183
|
+
to_hash
|
184
|
+
end
|
185
|
+
|
186
|
+
# Returns the object in the form of hash
|
187
|
+
# @return [Hash] Returns the object in the form of hash
|
188
|
+
def to_hash
|
189
|
+
hash = {}
|
190
|
+
self.class.attribute_map.each_pair do |attr, param|
|
191
|
+
value = self.send(attr)
|
192
|
+
if value.nil?
|
193
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
194
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
195
|
+
end
|
196
|
+
|
197
|
+
hash[param] = _to_hash(value)
|
198
|
+
end
|
199
|
+
hash
|
200
|
+
end
|
201
|
+
|
202
|
+
# Outputs non-array value in the form of hash
|
203
|
+
# For object, use to_hash. Otherwise, just return the value
|
204
|
+
# @param [Object] value Any valid value
|
205
|
+
# @return [Hash] Returns the value in the form of hash
|
206
|
+
def _to_hash(value)
|
207
|
+
if value.is_a?(Array)
|
208
|
+
value.compact.map { |v| _to_hash(v) }
|
209
|
+
elsif value.is_a?(Hash)
|
210
|
+
{}.tap do |hash|
|
211
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
212
|
+
end
|
213
|
+
elsif value.respond_to? :to_hash
|
214
|
+
value.to_hash
|
215
|
+
else
|
216
|
+
value
|
217
|
+
end
|
218
|
+
end
|
219
|
+
end
|
220
|
+
end
|
@@ -0,0 +1,242 @@
|
|
1
|
+
=begin
|
2
|
+
#MailSlurp API
|
3
|
+
|
4
|
+
#MailSlurp is an API for sending and receiving emails from dynamically allocated email addresses. It's designed for developers and QA teams to test applications, process inbound emails, send templated notifications, attachments, and more. ## Resources - [Homepage](https://www.mailslurp.com) - Get an [API KEY](https://app.mailslurp.com/sign-up/) - Generated [SDK Clients](https://www.mailslurp.com/docs/) - [Examples](https://github.com/mailslurp/examples) repository
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 6.5.2
|
7
|
+
Contact: contact@mailslurp.dev
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module MailSlurpClient
|
16
|
+
# Options for the email envelope
|
17
|
+
class SendSMTPEnvelopeOptions
|
18
|
+
attr_accessor :rcpt_to
|
19
|
+
|
20
|
+
attr_accessor :mail_from
|
21
|
+
|
22
|
+
attr_accessor :data
|
23
|
+
|
24
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
25
|
+
def self.attribute_map
|
26
|
+
{
|
27
|
+
:'rcpt_to' => :'rcptTo',
|
28
|
+
:'mail_from' => :'mailFrom',
|
29
|
+
:'data' => :'data'
|
30
|
+
}
|
31
|
+
end
|
32
|
+
|
33
|
+
# Attribute type mapping.
|
34
|
+
def self.openapi_types
|
35
|
+
{
|
36
|
+
:'rcpt_to' => :'Array<String>',
|
37
|
+
:'mail_from' => :'String',
|
38
|
+
:'data' => :'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 `MailSlurpClient::SendSMTPEnvelopeOptions` 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 `MailSlurpClient::SendSMTPEnvelopeOptions`. 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?(:'rcpt_to')
|
64
|
+
if (value = attributes[:'rcpt_to']).is_a?(Array)
|
65
|
+
self.rcpt_to = value
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
if attributes.key?(:'mail_from')
|
70
|
+
self.mail_from = attributes[:'mail_from']
|
71
|
+
end
|
72
|
+
|
73
|
+
if attributes.key?(:'data')
|
74
|
+
self.data = attributes[:'data']
|
75
|
+
end
|
76
|
+
end
|
77
|
+
|
78
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
79
|
+
# @return Array for valid properties with the reasons
|
80
|
+
def list_invalid_properties
|
81
|
+
invalid_properties = Array.new
|
82
|
+
if @rcpt_to.nil?
|
83
|
+
invalid_properties.push('invalid value for "rcpt_to", rcpt_to cannot be nil.')
|
84
|
+
end
|
85
|
+
|
86
|
+
if @mail_from.nil?
|
87
|
+
invalid_properties.push('invalid value for "mail_from", mail_from cannot be nil.')
|
88
|
+
end
|
89
|
+
|
90
|
+
if @data.nil?
|
91
|
+
invalid_properties.push('invalid value for "data", data cannot be nil.')
|
92
|
+
end
|
93
|
+
|
94
|
+
invalid_properties
|
95
|
+
end
|
96
|
+
|
97
|
+
# Check to see if the all the properties in the model are valid
|
98
|
+
# @return true if the model is valid
|
99
|
+
def valid?
|
100
|
+
return false if @rcpt_to.nil?
|
101
|
+
return false if @mail_from.nil?
|
102
|
+
return false if @data.nil?
|
103
|
+
true
|
104
|
+
end
|
105
|
+
|
106
|
+
# Checks equality by comparing each attribute.
|
107
|
+
# @param [Object] Object to be compared
|
108
|
+
def ==(o)
|
109
|
+
return true if self.equal?(o)
|
110
|
+
self.class == o.class &&
|
111
|
+
rcpt_to == o.rcpt_to &&
|
112
|
+
mail_from == o.mail_from &&
|
113
|
+
data == o.data
|
114
|
+
end
|
115
|
+
|
116
|
+
# @see the `==` method
|
117
|
+
# @param [Object] Object to be compared
|
118
|
+
def eql?(o)
|
119
|
+
self == o
|
120
|
+
end
|
121
|
+
|
122
|
+
# Calculates hash code according to all attributes.
|
123
|
+
# @return [Integer] Hash code
|
124
|
+
def hash
|
125
|
+
[rcpt_to, mail_from, data].hash
|
126
|
+
end
|
127
|
+
|
128
|
+
# Builds the object from hash
|
129
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
130
|
+
# @return [Object] Returns the model itself
|
131
|
+
def self.build_from_hash(attributes)
|
132
|
+
new.build_from_hash(attributes)
|
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 build_from_hash(attributes)
|
139
|
+
return nil unless attributes.is_a?(Hash)
|
140
|
+
self.class.openapi_types.each_pair do |key, type|
|
141
|
+
if type =~ /\AArray<(.*)>/i
|
142
|
+
# check to ensure the input is an array given that the attribute
|
143
|
+
# is documented as an array but the input is not
|
144
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
145
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
146
|
+
end
|
147
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
148
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
149
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
150
|
+
end
|
151
|
+
|
152
|
+
self
|
153
|
+
end
|
154
|
+
|
155
|
+
# Deserializes the data based on type
|
156
|
+
# @param string type Data type
|
157
|
+
# @param string value Value to be deserialized
|
158
|
+
# @return [Object] Deserialized data
|
159
|
+
def _deserialize(type, value)
|
160
|
+
case type.to_sym
|
161
|
+
when :DateTime
|
162
|
+
DateTime.parse(value)
|
163
|
+
when :Date
|
164
|
+
Date.parse(value)
|
165
|
+
when :String
|
166
|
+
value.to_s
|
167
|
+
when :Integer
|
168
|
+
value.to_i
|
169
|
+
when :Float
|
170
|
+
value.to_f
|
171
|
+
when :Boolean
|
172
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
173
|
+
true
|
174
|
+
else
|
175
|
+
false
|
176
|
+
end
|
177
|
+
when :Object
|
178
|
+
# generic object (usually a Hash), return directly
|
179
|
+
value
|
180
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
181
|
+
inner_type = Regexp.last_match[:inner_type]
|
182
|
+
value.map { |v| _deserialize(inner_type, v) }
|
183
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
184
|
+
k_type = Regexp.last_match[:k_type]
|
185
|
+
v_type = Regexp.last_match[:v_type]
|
186
|
+
{}.tap do |hash|
|
187
|
+
value.each do |k, v|
|
188
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
189
|
+
end
|
190
|
+
end
|
191
|
+
else # model
|
192
|
+
MailSlurpClient.const_get(type).build_from_hash(value)
|
193
|
+
end
|
194
|
+
end
|
195
|
+
|
196
|
+
# Returns the string representation of the object
|
197
|
+
# @return [String] String presentation of the object
|
198
|
+
def to_s
|
199
|
+
to_hash.to_s
|
200
|
+
end
|
201
|
+
|
202
|
+
# to_body is an alias to to_hash (backward compatibility)
|
203
|
+
# @return [Hash] Returns the object in the form of hash
|
204
|
+
def to_body
|
205
|
+
to_hash
|
206
|
+
end
|
207
|
+
|
208
|
+
# Returns the object in the form of hash
|
209
|
+
# @return [Hash] Returns the object in the form of hash
|
210
|
+
def to_hash
|
211
|
+
hash = {}
|
212
|
+
self.class.attribute_map.each_pair do |attr, param|
|
213
|
+
value = self.send(attr)
|
214
|
+
if value.nil?
|
215
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
216
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
217
|
+
end
|
218
|
+
|
219
|
+
hash[param] = _to_hash(value)
|
220
|
+
end
|
221
|
+
hash
|
222
|
+
end
|
223
|
+
|
224
|
+
# Outputs non-array value in the form of hash
|
225
|
+
# For object, use to_hash. Otherwise, just return the value
|
226
|
+
# @param [Object] value Any valid value
|
227
|
+
# @return [Hash] Returns the value in the form of hash
|
228
|
+
def _to_hash(value)
|
229
|
+
if value.is_a?(Array)
|
230
|
+
value.compact.map { |v| _to_hash(v) }
|
231
|
+
elsif value.is_a?(Hash)
|
232
|
+
{}.tap do |hash|
|
233
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
234
|
+
end
|
235
|
+
elsif value.respond_to? :to_hash
|
236
|
+
value.to_hash
|
237
|
+
else
|
238
|
+
value
|
239
|
+
end
|
240
|
+
end
|
241
|
+
end
|
242
|
+
end
|
@@ -29,12 +29,12 @@ module MailSlurpClient
|
|
29
29
|
|
30
30
|
attr_accessor :attachments
|
31
31
|
|
32
|
-
attr_accessor :created_at
|
33
|
-
|
34
32
|
attr_accessor :bcc
|
35
33
|
|
36
34
|
attr_accessor :cc
|
37
35
|
|
36
|
+
attr_accessor :created_at
|
37
|
+
|
38
38
|
attr_accessor :body_md5_hash
|
39
39
|
|
40
40
|
# Attribute mapping from ruby-style variable name to JSON key.
|
@@ -47,9 +47,9 @@ module MailSlurpClient
|
|
47
47
|
:'inbox_id' => :'inboxId',
|
48
48
|
:'to' => :'to',
|
49
49
|
:'attachments' => :'attachments',
|
50
|
-
:'created_at' => :'createdAt',
|
51
50
|
:'bcc' => :'bcc',
|
52
51
|
:'cc' => :'cc',
|
52
|
+
:'created_at' => :'createdAt',
|
53
53
|
:'body_md5_hash' => :'bodyMD5Hash'
|
54
54
|
}
|
55
55
|
end
|
@@ -64,9 +64,9 @@ module MailSlurpClient
|
|
64
64
|
:'inbox_id' => :'String',
|
65
65
|
:'to' => :'Array<String>',
|
66
66
|
:'attachments' => :'Array<String>',
|
67
|
-
:'created_at' => :'DateTime',
|
68
67
|
:'bcc' => :'Array<String>',
|
69
68
|
:'cc' => :'Array<String>',
|
69
|
+
:'created_at' => :'DateTime',
|
70
70
|
:'body_md5_hash' => :'String'
|
71
71
|
}
|
72
72
|
end
|
@@ -124,10 +124,6 @@ module MailSlurpClient
|
|
124
124
|
end
|
125
125
|
end
|
126
126
|
|
127
|
-
if attributes.key?(:'created_at')
|
128
|
-
self.created_at = attributes[:'created_at']
|
129
|
-
end
|
130
|
-
|
131
127
|
if attributes.key?(:'bcc')
|
132
128
|
if (value = attributes[:'bcc']).is_a?(Array)
|
133
129
|
self.bcc = value
|
@@ -140,6 +136,10 @@ module MailSlurpClient
|
|
140
136
|
end
|
141
137
|
end
|
142
138
|
|
139
|
+
if attributes.key?(:'created_at')
|
140
|
+
self.created_at = attributes[:'created_at']
|
141
|
+
end
|
142
|
+
|
143
143
|
if attributes.key?(:'body_md5_hash')
|
144
144
|
self.body_md5_hash = attributes[:'body_md5_hash']
|
145
145
|
end
|
@@ -169,10 +169,6 @@ module MailSlurpClient
|
|
169
169
|
invalid_properties.push('invalid value for "attachments", attachments cannot be nil.')
|
170
170
|
end
|
171
171
|
|
172
|
-
if @created_at.nil?
|
173
|
-
invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
|
174
|
-
end
|
175
|
-
|
176
172
|
if @bcc.nil?
|
177
173
|
invalid_properties.push('invalid value for "bcc", bcc cannot be nil.')
|
178
174
|
end
|
@@ -181,6 +177,10 @@ module MailSlurpClient
|
|
181
177
|
invalid_properties.push('invalid value for "cc", cc cannot be nil.')
|
182
178
|
end
|
183
179
|
|
180
|
+
if @created_at.nil?
|
181
|
+
invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
|
182
|
+
end
|
183
|
+
|
184
184
|
invalid_properties
|
185
185
|
end
|
186
186
|
|
@@ -192,9 +192,9 @@ module MailSlurpClient
|
|
192
192
|
return false if @inbox_id.nil?
|
193
193
|
return false if @to.nil?
|
194
194
|
return false if @attachments.nil?
|
195
|
-
return false if @created_at.nil?
|
196
195
|
return false if @bcc.nil?
|
197
196
|
return false if @cc.nil?
|
197
|
+
return false if @created_at.nil?
|
198
198
|
true
|
199
199
|
end
|
200
200
|
|
@@ -210,9 +210,9 @@ module MailSlurpClient
|
|
210
210
|
inbox_id == o.inbox_id &&
|
211
211
|
to == o.to &&
|
212
212
|
attachments == o.attachments &&
|
213
|
-
created_at == o.created_at &&
|
214
213
|
bcc == o.bcc &&
|
215
214
|
cc == o.cc &&
|
215
|
+
created_at == o.created_at &&
|
216
216
|
body_md5_hash == o.body_md5_hash
|
217
217
|
end
|
218
218
|
|
@@ -225,7 +225,7 @@ module MailSlurpClient
|
|
225
225
|
# Calculates hash code according to all attributes.
|
226
226
|
# @return [Integer] Hash code
|
227
227
|
def hash
|
228
|
-
[id, from, user_id, subject, inbox_id, to, attachments,
|
228
|
+
[id, from, user_id, subject, inbox_id, to, attachments, bcc, cc, created_at, body_md5_hash].hash
|
229
229
|
end
|
230
230
|
|
231
231
|
# Builds the object from hash
|
@@ -18,10 +18,10 @@ module MailSlurpClient
|
|
18
18
|
|
19
19
|
attr_accessor :id
|
20
20
|
|
21
|
-
attr_accessor :created_at
|
22
|
-
|
23
21
|
attr_accessor :variables
|
24
22
|
|
23
|
+
attr_accessor :created_at
|
24
|
+
|
25
25
|
attr_accessor :updated_at
|
26
26
|
|
27
27
|
# Attribute mapping from ruby-style variable name to JSON key.
|
@@ -29,8 +29,8 @@ module MailSlurpClient
|
|
29
29
|
{
|
30
30
|
:'name' => :'name',
|
31
31
|
:'id' => :'id',
|
32
|
-
:'created_at' => :'createdAt',
|
33
32
|
:'variables' => :'variables',
|
33
|
+
:'created_at' => :'createdAt',
|
34
34
|
:'updated_at' => :'updatedAt'
|
35
35
|
}
|
36
36
|
end
|
@@ -40,8 +40,8 @@ module MailSlurpClient
|
|
40
40
|
{
|
41
41
|
:'name' => :'String',
|
42
42
|
:'id' => :'String',
|
43
|
-
:'created_at' => :'DateTime',
|
44
43
|
:'variables' => :'Array<String>',
|
44
|
+
:'created_at' => :'DateTime',
|
45
45
|
:'updated_at' => :'DateTime'
|
46
46
|
}
|
47
47
|
end
|
@@ -75,16 +75,16 @@ module MailSlurpClient
|
|
75
75
|
self.id = attributes[:'id']
|
76
76
|
end
|
77
77
|
|
78
|
-
if attributes.key?(:'created_at')
|
79
|
-
self.created_at = attributes[:'created_at']
|
80
|
-
end
|
81
|
-
|
82
78
|
if attributes.key?(:'variables')
|
83
79
|
if (value = attributes[:'variables']).is_a?(Array)
|
84
80
|
self.variables = value
|
85
81
|
end
|
86
82
|
end
|
87
83
|
|
84
|
+
if attributes.key?(:'created_at')
|
85
|
+
self.created_at = attributes[:'created_at']
|
86
|
+
end
|
87
|
+
|
88
88
|
if attributes.key?(:'updated_at')
|
89
89
|
self.updated_at = attributes[:'updated_at']
|
90
90
|
end
|
@@ -102,14 +102,14 @@ module MailSlurpClient
|
|
102
102
|
invalid_properties.push('invalid value for "id", id cannot be nil.')
|
103
103
|
end
|
104
104
|
|
105
|
-
if @created_at.nil?
|
106
|
-
invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
|
107
|
-
end
|
108
|
-
|
109
105
|
if @variables.nil?
|
110
106
|
invalid_properties.push('invalid value for "variables", variables cannot be nil.')
|
111
107
|
end
|
112
108
|
|
109
|
+
if @created_at.nil?
|
110
|
+
invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
|
111
|
+
end
|
112
|
+
|
113
113
|
if @updated_at.nil?
|
114
114
|
invalid_properties.push('invalid value for "updated_at", updated_at cannot be nil.')
|
115
115
|
end
|
@@ -122,8 +122,8 @@ module MailSlurpClient
|
|
122
122
|
def valid?
|
123
123
|
return false if @name.nil?
|
124
124
|
return false if @id.nil?
|
125
|
-
return false if @created_at.nil?
|
126
125
|
return false if @variables.nil?
|
126
|
+
return false if @created_at.nil?
|
127
127
|
return false if @updated_at.nil?
|
128
128
|
true
|
129
129
|
end
|
@@ -135,8 +135,8 @@ module MailSlurpClient
|
|
135
135
|
self.class == o.class &&
|
136
136
|
name == o.name &&
|
137
137
|
id == o.id &&
|
138
|
-
created_at == o.created_at &&
|
139
138
|
variables == o.variables &&
|
139
|
+
created_at == o.created_at &&
|
140
140
|
updated_at == o.updated_at
|
141
141
|
end
|
142
142
|
|
@@ -149,7 +149,7 @@ module MailSlurpClient
|
|
149
149
|
# Calculates hash code according to all attributes.
|
150
150
|
# @return [Integer] Hash code
|
151
151
|
def hash
|
152
|
-
[name, id,
|
152
|
+
[name, id, variables, created_at, updated_at].hash
|
153
153
|
end
|
154
154
|
|
155
155
|
# Builds the object from hash
|