mailslurp_client 15.17.4 → 15.17.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +13 -13
- data/lib/mailslurp_client/api/domain_controller_api.rb +59 -0
- data/lib/mailslurp_client/api/phone_controller_api.rb +1 -1
- data/lib/mailslurp_client/models/attachment_projection.rb +30 -30
- data/lib/mailslurp_client/models/create_emergency_address_options.rb +2 -2
- data/lib/mailslurp_client/models/domain_dto.rb +27 -1
- data/lib/mailslurp_client/models/domain_issues_dto.rb +211 -0
- data/lib/mailslurp_client/models/domain_preview.rb +18 -4
- data/lib/mailslurp_client/models/email_projection.rb +10 -10
- data/lib/mailslurp_client/models/emergency_address.rb +2 -2
- data/lib/mailslurp_client/models/emergency_address_dto.rb +2 -2
- data/lib/mailslurp_client/models/inbox_replier_event_projection.rb +11 -11
- data/lib/mailslurp_client/models/missed_email_projection.rb +11 -11
- data/lib/mailslurp_client/models/page_alias.rb +19 -19
- data/lib/mailslurp_client/models/page_attachment_entity.rb +19 -19
- data/lib/mailslurp_client/models/page_bounced_email.rb +19 -19
- data/lib/mailslurp_client/models/page_bounced_recipients.rb +19 -19
- data/lib/mailslurp_client/models/page_complaint.rb +19 -19
- data/lib/mailslurp_client/models/page_contact_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_delivery_status.rb +19 -19
- data/lib/mailslurp_client/models/page_email_preview.rb +19 -19
- data/lib/mailslurp_client/models/page_email_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_email_validation_request.rb +19 -19
- data/lib/mailslurp_client/models/page_expired_inbox_record_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_group_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_inbox_forwarder_dto.rb +19 -19
- data/lib/mailslurp_client/models/page_inbox_forwarder_events.rb +19 -19
- data/lib/mailslurp_client/models/page_inbox_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_inbox_replier_dto.rb +19 -19
- data/lib/mailslurp_client/models/page_inbox_replier_events.rb +19 -19
- data/lib/mailslurp_client/models/page_inbox_ruleset_dto.rb +19 -19
- data/lib/mailslurp_client/models/page_list_unsubscribe_recipients.rb +19 -19
- data/lib/mailslurp_client/models/page_missed_email_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_organization_inbox_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_phone_number_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_scheduled_jobs.rb +19 -19
- data/lib/mailslurp_client/models/page_sms_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_template_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_thread_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_tracking_pixel_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_unknown_missed_email_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_webhook_projection.rb +19 -19
- data/lib/mailslurp_client/models/page_webhook_result.rb +19 -19
- data/lib/mailslurp_client/models/phone_number_dto.rb +2 -2
- data/lib/mailslurp_client/models/phone_number_projection.rb +21 -21
- data/lib/mailslurp_client/models/phone_plan_dto.rb +2 -2
- data/lib/mailslurp_client/models/sent_email_projection.rb +15 -15
- data/lib/mailslurp_client/models/thread_projection.rb +11 -11
- data/lib/mailslurp_client/models/tracking_pixel_projection.rb +10 -10
- data/lib/mailslurp_client/version.rb +1 -1
- data/lib/mailslurp_client.rb +1 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 149f2c5c5313e83e2d76af88446e613e1962f04813c8d90c6bf2d498bc518391
|
4
|
+
data.tar.gz: a92a1a75bd63c89e776571f2e957ab7bb8f413164940c48c924a2eb430f3b5d7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e5bc422e3bd1f4725d398a7cdc336e3bd67411ee767a3ecac88dc8aa97295da6991d525fa692aaf94f55c52740ada934440b219b1e9aa33b17d1ed7951c4380d
|
7
|
+
data.tar.gz: 5ecd707e8995424f22bd521088ae3d93d767e4d55ec58ba7c81c1c8dd83b15af9b6d0a3389a6183d1bb4e89932baca1b81cb55b94d08b323e7dfb795b7d1c452
|
data/README.md
CHANGED
@@ -6,7 +6,7 @@ MailSlurp is an email API service that lets you create real email addresses in c
|
|
6
6
|
|
7
7
|
## Quick links
|
8
8
|
|
9
|
-
- [Method Documentation](https://mailslurp.
|
9
|
+
- [Method Documentation](https://ruby.mailslurp.com/)
|
10
10
|
- [Gem Package](https://rubygems.org/gems/mailslurp_client)
|
11
11
|
- [Github Source](https://github.com/mailslurp/mailslurp-client-ruby)
|
12
12
|
- [SMTP access details](https://www.mailslurp.com/guides/smtp-imap/)
|
@@ -14,9 +14,9 @@ MailSlurp is an email API service that lets you create real email addresses in c
|
|
14
14
|
|
15
15
|
### Common controllers
|
16
16
|
|
17
|
-
- [Email controller](https://mailslurp.
|
18
|
-
- [Inbox controller](https://mailslurp.
|
19
|
-
- [WaitFor controller](https://mailslurp.
|
17
|
+
- [Email controller](https://ruby.mailslurp.com/MailSlurpClient/EmailControllerApi.html) send and receive emails
|
18
|
+
- [Inbox controller](https://ruby.mailslurp.com/MailSlurpClient/InboxControllerApi.html) create and manage email addresses
|
19
|
+
- [WaitFor controller](https://ruby.mailslurp.com/MailSlurpClient/WaitForControllerApi.html) wait for expected emails to arrive
|
20
20
|
|
21
21
|
|
22
22
|
### Example tutorials
|
@@ -27,7 +27,7 @@ This section describes how to get up and running with the Ruby client.
|
|
27
27
|
|
28
28
|
See the [examples page](https://www.mailslurp.com/examples/) for more examples and use with common frameworks such as Rails and RSpec.
|
29
29
|
|
30
|
-
See the method documentation for a [list of all functions](https://mailslurp.
|
30
|
+
See the method documentation for a [list of all functions](https://ruby.mailslurp.com/)
|
31
31
|
|
32
32
|
### Create API Key
|
33
33
|
|
@@ -82,7 +82,7 @@ Here are some common uses:
|
|
82
82
|
|
83
83
|
### Create inboxes
|
84
84
|
|
85
|
-
To use MailSlurp you need to create inboxes. These are email accounts that have an ID and a real email address. See methods on the [inbox controller](https://mailslurp.
|
85
|
+
To use MailSlurp you need to create inboxes. These are email accounts that have an ID and a real email address. See methods on the [inbox controller](https://ruby.mailslurp.com/MailSlurpClient/InboxControllerApi.html) for more information.
|
86
86
|
|
87
87
|
```ruby
|
88
88
|
inbox_controller = MailSlurpClient::InboxControllerApi.new
|
@@ -177,7 +177,7 @@ end
|
|
177
177
|
|
178
178
|
### List inboxes
|
179
179
|
|
180
|
-
Inboxes you create can be listed in a paginated way using the [InboxController](https://mailslurp.
|
180
|
+
Inboxes you create can be listed in a paginated way using the [InboxController](https://ruby.mailslurp.com/MailSlurpClient/InboxControllerApi.html)).
|
181
181
|
|
182
182
|
```ruby
|
183
183
|
it 'can list inboxes' do
|
@@ -198,7 +198,7 @@ end
|
|
198
198
|
### Send emails
|
199
199
|
|
200
200
|
You can send HTML emails easily with the inbox controller. First create an inbox then use its ID with the `send_email` method.
|
201
|
-
To send attachments see the [Method Documentation](https://mailslurp.
|
201
|
+
To send attachments see the [Method Documentation](https://ruby.mailslurp.com/).
|
202
202
|
|
203
203
|
```ruby
|
204
204
|
# create an inbox
|
@@ -219,7 +219,7 @@ inbox_controller.send_email(inbox.id, {
|
|
219
219
|
})
|
220
220
|
```
|
221
221
|
|
222
|
-
You can also use objects for most [method options](https://mailslurp.
|
222
|
+
You can also use objects for most [method options](https://ruby.mailslurp.com/MailSlurpClient/SendEmailOptions.html):
|
223
223
|
|
224
224
|
```ruby
|
225
225
|
opts = {
|
@@ -239,7 +239,7 @@ inbox_controller.send_email(inbox_1.id, opts)
|
|
239
239
|
|
240
240
|
### Receive emails
|
241
241
|
|
242
|
-
To read already existing emails use the [Email Controller](https://mailslurp.
|
242
|
+
To read already existing emails use the [Email Controller](https://ruby.mailslurp.com/MailSlurpClient/EmailControllerApi.html). To wait for expected emails to arrive use the [WaitFor Controller](https://ruby.mailslurp.com/MailSlurpClient/WaitForControllerApi.html).
|
243
243
|
You can use MailSlurp to wait for at least 1 unread email in an inbox and return it.
|
244
244
|
If a timeout is exceeded it will throw an error instead:
|
245
245
|
|
@@ -273,7 +273,7 @@ code, * = match.captures
|
|
273
273
|
|
274
274
|
### Attachments
|
275
275
|
|
276
|
-
You can send attachments by first uploading files with the [AttachmentControllerApi](https://mailslurp.
|
276
|
+
You can send attachments by first uploading files with the [AttachmentControllerApi](https://ruby.mailslurp.com/MailSlurpClient/AttachmentControllerApi.html) then using the returned attachment IDs in the send email method.
|
277
277
|
|
278
278
|
MailSlurp endpoints use base64 string encoding for upload and download files. To encode or decode strings in Ruby make sure you use the **strict** variables that avoid added newlines.
|
279
279
|
|
@@ -389,7 +389,7 @@ describe 'use MailSlurp ruby sdk to create email addresses then send and receive
|
|
389
389
|
inbox_2 = inbox_controller.create_inbox
|
390
390
|
|
391
391
|
# send email from inbox 1 to inbox 2 (you can send emails to any address)
|
392
|
-
# for send options see https://mailslurp.
|
392
|
+
# for send options see https://ruby.mailslurp.com/MailSlurpClient/SendEmailOptions.html
|
393
393
|
opts = {
|
394
394
|
send_email_options: MailSlurpClient::SendEmailOptions.new(
|
395
395
|
{
|
@@ -419,4 +419,4 @@ end
|
|
419
419
|
|
420
420
|
## SDK Documentation
|
421
421
|
|
422
|
-
See the [examples page](https://www.mailslurp.com/examples/) or the full [Method Documentation](https://mailslurp.
|
422
|
+
See the [examples page](https://www.mailslurp.com/examples/) or the full [Method Documentation](https://ruby.mailslurp.com/) on Github.
|
@@ -211,6 +211,7 @@ module MailSlurpClient
|
|
211
211
|
# Returns domain verification status and tokens for a given domain
|
212
212
|
# @param id [String]
|
213
213
|
# @param [Hash] opts the optional parameters
|
214
|
+
# @option opts [Boolean] :check_for_errors
|
214
215
|
# @return [DomainDto]
|
215
216
|
def get_domain(id, opts = {})
|
216
217
|
data, _status_code, _headers = get_domain_with_http_info(id, opts)
|
@@ -221,6 +222,7 @@ module MailSlurpClient
|
|
221
222
|
# Returns domain verification status and tokens for a given domain
|
222
223
|
# @param id [String]
|
223
224
|
# @param [Hash] opts the optional parameters
|
225
|
+
# @option opts [Boolean] :check_for_errors
|
224
226
|
# @return [Array<(DomainDto, Integer, Hash)>] DomainDto data, response status code and response headers
|
225
227
|
def get_domain_with_http_info(id, opts = {})
|
226
228
|
if @api_client.config.debugging
|
@@ -235,6 +237,7 @@ module MailSlurpClient
|
|
235
237
|
|
236
238
|
# query parameters
|
237
239
|
query_params = opts[:query_params] || {}
|
240
|
+
query_params[:'checkForErrors'] = opts[:'check_for_errors'] if !opts[:'check_for_errors'].nil?
|
238
241
|
|
239
242
|
# header parameters
|
240
243
|
header_params = opts[:header_params] || {}
|
@@ -269,6 +272,62 @@ module MailSlurpClient
|
|
269
272
|
return data, status_code, headers
|
270
273
|
end
|
271
274
|
|
275
|
+
# Get domain issues
|
276
|
+
# List domain issues for domains you have created
|
277
|
+
# @param [Hash] opts the optional parameters
|
278
|
+
# @return [DomainIssuesDto]
|
279
|
+
def get_domain_issues(opts = {})
|
280
|
+
data, _status_code, _headers = get_domain_issues_with_http_info(opts)
|
281
|
+
data
|
282
|
+
end
|
283
|
+
|
284
|
+
# Get domain issues
|
285
|
+
# List domain issues for domains you have created
|
286
|
+
# @param [Hash] opts the optional parameters
|
287
|
+
# @return [Array<(DomainIssuesDto, Integer, Hash)>] DomainIssuesDto data, response status code and response headers
|
288
|
+
def get_domain_issues_with_http_info(opts = {})
|
289
|
+
if @api_client.config.debugging
|
290
|
+
@api_client.config.logger.debug 'Calling API: DomainControllerApi.get_domain_issues ...'
|
291
|
+
end
|
292
|
+
# resource path
|
293
|
+
local_var_path = '/domains/issues'
|
294
|
+
|
295
|
+
# query parameters
|
296
|
+
query_params = opts[:query_params] || {}
|
297
|
+
|
298
|
+
# header parameters
|
299
|
+
header_params = opts[:header_params] || {}
|
300
|
+
# HTTP header 'Accept' (if needed)
|
301
|
+
header_params['Accept'] = @api_client.select_header_accept(['*/*'])
|
302
|
+
|
303
|
+
# form parameters
|
304
|
+
form_params = opts[:form_params] || {}
|
305
|
+
|
306
|
+
# http body (model)
|
307
|
+
post_body = opts[:body]
|
308
|
+
|
309
|
+
# return_type
|
310
|
+
return_type = opts[:return_type] || 'DomainIssuesDto'
|
311
|
+
|
312
|
+
# auth_names
|
313
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
314
|
+
|
315
|
+
new_options = opts.merge(
|
316
|
+
:header_params => header_params,
|
317
|
+
:query_params => query_params,
|
318
|
+
:form_params => form_params,
|
319
|
+
:body => post_body,
|
320
|
+
:auth_names => auth_names,
|
321
|
+
:return_type => return_type
|
322
|
+
)
|
323
|
+
|
324
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
325
|
+
if @api_client.config.debugging
|
326
|
+
@api_client.config.logger.debug "API called: DomainControllerApi#get_domain_issues\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
327
|
+
end
|
328
|
+
return data, status_code, headers
|
329
|
+
end
|
330
|
+
|
272
331
|
# Get catch all wild card inbox for domain
|
273
332
|
# Get the catch all inbox for a domain for missed emails
|
274
333
|
# @param id [String]
|
@@ -386,7 +386,7 @@ module MailSlurpClient
|
|
386
386
|
if @api_client.config.debugging
|
387
387
|
@api_client.config.logger.debug 'Calling API: PhoneControllerApi.get_phone_numbers ...'
|
388
388
|
end
|
389
|
-
allowable_values = ["US", "GB"]
|
389
|
+
allowable_values = ["US", "GB", "AU"]
|
390
390
|
if @api_client.config.client_side_validation && opts[:'phone_country'] && !allowable_values.include?(opts[:'phone_country'])
|
391
391
|
fail ArgumentError, "invalid value for \"phone_country\", must be one of #{allowable_values}"
|
392
392
|
end
|
@@ -20,28 +20,28 @@ module MailSlurpClient
|
|
20
20
|
# Content length of attachment in bytes
|
21
21
|
attr_accessor :content_length
|
22
22
|
|
23
|
-
# Content type of attachment.
|
24
|
-
attr_accessor :content_type
|
25
|
-
|
26
23
|
attr_accessor :user_id
|
27
24
|
|
28
|
-
# Attachment ID
|
29
|
-
attr_accessor :attachment_id
|
30
|
-
|
31
25
|
attr_accessor :created_at
|
32
26
|
|
33
27
|
attr_accessor :updated_at
|
34
28
|
|
29
|
+
# Attachment ID
|
30
|
+
attr_accessor :attachment_id
|
31
|
+
|
32
|
+
# Content type of attachment.
|
33
|
+
attr_accessor :content_type
|
34
|
+
|
35
35
|
# Attribute mapping from ruby-style variable name to JSON key.
|
36
36
|
def self.attribute_map
|
37
37
|
{
|
38
38
|
:'name' => :'name',
|
39
39
|
:'content_length' => :'contentLength',
|
40
|
-
:'content_type' => :'contentType',
|
41
40
|
:'user_id' => :'userId',
|
42
|
-
:'attachment_id' => :'attachmentId',
|
43
41
|
:'created_at' => :'createdAt',
|
44
|
-
:'updated_at' => :'updatedAt'
|
42
|
+
:'updated_at' => :'updatedAt',
|
43
|
+
:'attachment_id' => :'attachmentId',
|
44
|
+
:'content_type' => :'contentType'
|
45
45
|
}
|
46
46
|
end
|
47
47
|
|
@@ -50,11 +50,11 @@ module MailSlurpClient
|
|
50
50
|
{
|
51
51
|
:'name' => :'String',
|
52
52
|
:'content_length' => :'Integer',
|
53
|
-
:'content_type' => :'String',
|
54
53
|
:'user_id' => :'String',
|
55
|
-
:'attachment_id' => :'String',
|
56
54
|
:'created_at' => :'DateTime',
|
57
|
-
:'updated_at' => :'DateTime'
|
55
|
+
:'updated_at' => :'DateTime',
|
56
|
+
:'attachment_id' => :'String',
|
57
|
+
:'content_type' => :'String'
|
58
58
|
}
|
59
59
|
end
|
60
60
|
|
@@ -63,7 +63,7 @@ module MailSlurpClient
|
|
63
63
|
Set.new([
|
64
64
|
:'name',
|
65
65
|
:'content_length',
|
66
|
-
:'content_type'
|
66
|
+
:'content_type'
|
67
67
|
])
|
68
68
|
end
|
69
69
|
|
@@ -90,18 +90,10 @@ module MailSlurpClient
|
|
90
90
|
self.content_length = attributes[:'content_length']
|
91
91
|
end
|
92
92
|
|
93
|
-
if attributes.key?(:'content_type')
|
94
|
-
self.content_type = attributes[:'content_type']
|
95
|
-
end
|
96
|
-
|
97
93
|
if attributes.key?(:'user_id')
|
98
94
|
self.user_id = attributes[:'user_id']
|
99
95
|
end
|
100
96
|
|
101
|
-
if attributes.key?(:'attachment_id')
|
102
|
-
self.attachment_id = attributes[:'attachment_id']
|
103
|
-
end
|
104
|
-
|
105
97
|
if attributes.key?(:'created_at')
|
106
98
|
self.created_at = attributes[:'created_at']
|
107
99
|
end
|
@@ -109,6 +101,14 @@ module MailSlurpClient
|
|
109
101
|
if attributes.key?(:'updated_at')
|
110
102
|
self.updated_at = attributes[:'updated_at']
|
111
103
|
end
|
104
|
+
|
105
|
+
if attributes.key?(:'attachment_id')
|
106
|
+
self.attachment_id = attributes[:'attachment_id']
|
107
|
+
end
|
108
|
+
|
109
|
+
if attributes.key?(:'content_type')
|
110
|
+
self.content_type = attributes[:'content_type']
|
111
|
+
end
|
112
112
|
end
|
113
113
|
|
114
114
|
# Show invalid properties with the reasons. Usually used together with valid?
|
@@ -119,10 +119,6 @@ module MailSlurpClient
|
|
119
119
|
invalid_properties.push('invalid value for "user_id", user_id cannot be nil.')
|
120
120
|
end
|
121
121
|
|
122
|
-
if @attachment_id.nil?
|
123
|
-
invalid_properties.push('invalid value for "attachment_id", attachment_id cannot be nil.')
|
124
|
-
end
|
125
|
-
|
126
122
|
if @created_at.nil?
|
127
123
|
invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
|
128
124
|
end
|
@@ -131,6 +127,10 @@ module MailSlurpClient
|
|
131
127
|
invalid_properties.push('invalid value for "updated_at", updated_at cannot be nil.')
|
132
128
|
end
|
133
129
|
|
130
|
+
if @attachment_id.nil?
|
131
|
+
invalid_properties.push('invalid value for "attachment_id", attachment_id cannot be nil.')
|
132
|
+
end
|
133
|
+
|
134
134
|
invalid_properties
|
135
135
|
end
|
136
136
|
|
@@ -138,9 +138,9 @@ module MailSlurpClient
|
|
138
138
|
# @return true if the model is valid
|
139
139
|
def valid?
|
140
140
|
return false if @user_id.nil?
|
141
|
-
return false if @attachment_id.nil?
|
142
141
|
return false if @created_at.nil?
|
143
142
|
return false if @updated_at.nil?
|
143
|
+
return false if @attachment_id.nil?
|
144
144
|
true
|
145
145
|
end
|
146
146
|
|
@@ -151,11 +151,11 @@ module MailSlurpClient
|
|
151
151
|
self.class == o.class &&
|
152
152
|
name == o.name &&
|
153
153
|
content_length == o.content_length &&
|
154
|
-
content_type == o.content_type &&
|
155
154
|
user_id == o.user_id &&
|
156
|
-
attachment_id == o.attachment_id &&
|
157
155
|
created_at == o.created_at &&
|
158
|
-
updated_at == o.updated_at
|
156
|
+
updated_at == o.updated_at &&
|
157
|
+
attachment_id == o.attachment_id &&
|
158
|
+
content_type == o.content_type
|
159
159
|
end
|
160
160
|
|
161
161
|
# @see the `==` method
|
@@ -167,7 +167,7 @@ module MailSlurpClient
|
|
167
167
|
# Calculates hash code according to all attributes.
|
168
168
|
# @return [Integer] Hash code
|
169
169
|
def hash
|
170
|
-
[name, content_length,
|
170
|
+
[name, content_length, user_id, created_at, updated_at, attachment_id, content_type].hash
|
171
171
|
end
|
172
172
|
|
173
173
|
# Builds the object from hash
|
@@ -166,7 +166,7 @@ module MailSlurpClient
|
|
166
166
|
return false if @region.nil?
|
167
167
|
return false if @postal_code.nil?
|
168
168
|
return false if @iso_country_code.nil?
|
169
|
-
iso_country_code_validator = EnumAttributeValidator.new('String', ["US", "GB"])
|
169
|
+
iso_country_code_validator = EnumAttributeValidator.new('String', ["US", "GB", "AU"])
|
170
170
|
return false unless iso_country_code_validator.valid?(@iso_country_code)
|
171
171
|
true
|
172
172
|
end
|
@@ -174,7 +174,7 @@ module MailSlurpClient
|
|
174
174
|
# Custom attribute writer method checking allowed values (enum).
|
175
175
|
# @param [Object] iso_country_code Object to be assigned
|
176
176
|
def iso_country_code=(iso_country_code)
|
177
|
-
validator = EnumAttributeValidator.new('String', ["US", "GB"])
|
177
|
+
validator = EnumAttributeValidator.new('String', ["US", "GB", "AU"])
|
178
178
|
unless validator.valid?(iso_country_code)
|
179
179
|
fail ArgumentError, "invalid value for \"iso_country_code\", must be one of #{validator.allowable_values}."
|
180
180
|
end
|
@@ -28,6 +28,12 @@ module MailSlurpClient
|
|
28
28
|
# Unique token DKIM tokens
|
29
29
|
attr_accessor :dkim_tokens
|
30
30
|
|
31
|
+
# If the domain is missing records then show which pairs are missing.
|
32
|
+
attr_accessor :missing_records_message
|
33
|
+
|
34
|
+
# Whether the domain has missing required records. If true then see the domain in the dashboard app.
|
35
|
+
attr_accessor :has_missing_records
|
36
|
+
|
31
37
|
# Whether domain has been verified or not. If the domain is not verified after 72 hours there is most likely an issue with the domains DNS records.
|
32
38
|
attr_accessor :is_verified
|
33
39
|
|
@@ -74,6 +80,8 @@ module MailSlurpClient
|
|
74
80
|
:'domain' => :'domain',
|
75
81
|
:'verification_token' => :'verificationToken',
|
76
82
|
:'dkim_tokens' => :'dkimTokens',
|
83
|
+
:'missing_records_message' => :'missingRecordsMessage',
|
84
|
+
:'has_missing_records' => :'hasMissingRecords',
|
77
85
|
:'is_verified' => :'isVerified',
|
78
86
|
:'domain_name_records' => :'domainNameRecords',
|
79
87
|
:'catch_all_inbox_id' => :'catchAllInboxId',
|
@@ -91,6 +99,8 @@ module MailSlurpClient
|
|
91
99
|
:'domain' => :'String',
|
92
100
|
:'verification_token' => :'String',
|
93
101
|
:'dkim_tokens' => :'Array<String>',
|
102
|
+
:'missing_records_message' => :'String',
|
103
|
+
:'has_missing_records' => :'Boolean',
|
94
104
|
:'is_verified' => :'Boolean',
|
95
105
|
:'domain_name_records' => :'Array<DomainNameRecord>',
|
96
106
|
:'catch_all_inbox_id' => :'String',
|
@@ -103,6 +113,7 @@ module MailSlurpClient
|
|
103
113
|
# List of attributes with nullable: true
|
104
114
|
def self.openapi_nullable
|
105
115
|
Set.new([
|
116
|
+
:'missing_records_message',
|
106
117
|
:'catch_all_inbox_id',
|
107
118
|
])
|
108
119
|
end
|
@@ -144,6 +155,14 @@ module MailSlurpClient
|
|
144
155
|
end
|
145
156
|
end
|
146
157
|
|
158
|
+
if attributes.key?(:'missing_records_message')
|
159
|
+
self.missing_records_message = attributes[:'missing_records_message']
|
160
|
+
end
|
161
|
+
|
162
|
+
if attributes.key?(:'has_missing_records')
|
163
|
+
self.has_missing_records = attributes[:'has_missing_records']
|
164
|
+
end
|
165
|
+
|
147
166
|
if attributes.key?(:'is_verified')
|
148
167
|
self.is_verified = attributes[:'is_verified']
|
149
168
|
end
|
@@ -195,6 +214,10 @@ module MailSlurpClient
|
|
195
214
|
invalid_properties.push('invalid value for "dkim_tokens", dkim_tokens cannot be nil.')
|
196
215
|
end
|
197
216
|
|
217
|
+
if @has_missing_records.nil?
|
218
|
+
invalid_properties.push('invalid value for "has_missing_records", has_missing_records cannot be nil.')
|
219
|
+
end
|
220
|
+
|
198
221
|
if @is_verified.nil?
|
199
222
|
invalid_properties.push('invalid value for "is_verified", is_verified cannot be nil.')
|
200
223
|
end
|
@@ -226,6 +249,7 @@ module MailSlurpClient
|
|
226
249
|
return false if @domain.nil?
|
227
250
|
return false if @verification_token.nil?
|
228
251
|
return false if @dkim_tokens.nil?
|
252
|
+
return false if @has_missing_records.nil?
|
229
253
|
return false if @is_verified.nil?
|
230
254
|
return false if @domain_name_records.nil?
|
231
255
|
return false if @created_at.nil?
|
@@ -256,6 +280,8 @@ module MailSlurpClient
|
|
256
280
|
domain == o.domain &&
|
257
281
|
verification_token == o.verification_token &&
|
258
282
|
dkim_tokens == o.dkim_tokens &&
|
283
|
+
missing_records_message == o.missing_records_message &&
|
284
|
+
has_missing_records == o.has_missing_records &&
|
259
285
|
is_verified == o.is_verified &&
|
260
286
|
domain_name_records == o.domain_name_records &&
|
261
287
|
catch_all_inbox_id == o.catch_all_inbox_id &&
|
@@ -273,7 +299,7 @@ module MailSlurpClient
|
|
273
299
|
# Calculates hash code according to all attributes.
|
274
300
|
# @return [Integer] Hash code
|
275
301
|
def hash
|
276
|
-
[id, user_id, domain, verification_token, dkim_tokens, is_verified, domain_name_records, catch_all_inbox_id, created_at, updated_at, domain_type].hash
|
302
|
+
[id, user_id, domain, verification_token, dkim_tokens, missing_records_message, has_missing_records, is_verified, domain_name_records, catch_all_inbox_id, created_at, updated_at, domain_type].hash
|
277
303
|
end
|
278
304
|
|
279
305
|
# Builds the object from hash
|
@@ -0,0 +1,211 @@
|
|
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://docs.mailslurp.com/) - [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 DomainIssuesDto
|
17
|
+
attr_accessor :has_issues
|
18
|
+
|
19
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
20
|
+
def self.attribute_map
|
21
|
+
{
|
22
|
+
:'has_issues' => :'hasIssues'
|
23
|
+
}
|
24
|
+
end
|
25
|
+
|
26
|
+
# Attribute type mapping.
|
27
|
+
def self.openapi_types
|
28
|
+
{
|
29
|
+
:'has_issues' => :'Boolean'
|
30
|
+
}
|
31
|
+
end
|
32
|
+
|
33
|
+
# List of attributes with nullable: true
|
34
|
+
def self.openapi_nullable
|
35
|
+
Set.new([
|
36
|
+
])
|
37
|
+
end
|
38
|
+
|
39
|
+
# Initializes the object
|
40
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
41
|
+
def initialize(attributes = {})
|
42
|
+
if (!attributes.is_a?(Hash))
|
43
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `MailSlurpClient::DomainIssuesDto` initialize method"
|
44
|
+
end
|
45
|
+
|
46
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
47
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
48
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
49
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `MailSlurpClient::DomainIssuesDto`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
50
|
+
end
|
51
|
+
h[k.to_sym] = v
|
52
|
+
}
|
53
|
+
|
54
|
+
if attributes.key?(:'has_issues')
|
55
|
+
self.has_issues = attributes[:'has_issues']
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
60
|
+
# @return Array for valid properties with the reasons
|
61
|
+
def list_invalid_properties
|
62
|
+
invalid_properties = Array.new
|
63
|
+
if @has_issues.nil?
|
64
|
+
invalid_properties.push('invalid value for "has_issues", has_issues cannot be nil.')
|
65
|
+
end
|
66
|
+
|
67
|
+
invalid_properties
|
68
|
+
end
|
69
|
+
|
70
|
+
# Check to see if the all the properties in the model are valid
|
71
|
+
# @return true if the model is valid
|
72
|
+
def valid?
|
73
|
+
return false if @has_issues.nil?
|
74
|
+
true
|
75
|
+
end
|
76
|
+
|
77
|
+
# Checks equality by comparing each attribute.
|
78
|
+
# @param [Object] Object to be compared
|
79
|
+
def ==(o)
|
80
|
+
return true if self.equal?(o)
|
81
|
+
self.class == o.class &&
|
82
|
+
has_issues == o.has_issues
|
83
|
+
end
|
84
|
+
|
85
|
+
# @see the `==` method
|
86
|
+
# @param [Object] Object to be compared
|
87
|
+
def eql?(o)
|
88
|
+
self == o
|
89
|
+
end
|
90
|
+
|
91
|
+
# Calculates hash code according to all attributes.
|
92
|
+
# @return [Integer] Hash code
|
93
|
+
def hash
|
94
|
+
[has_issues].hash
|
95
|
+
end
|
96
|
+
|
97
|
+
# Builds the object from hash
|
98
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
99
|
+
# @return [Object] Returns the model itself
|
100
|
+
def self.build_from_hash(attributes)
|
101
|
+
new.build_from_hash(attributes)
|
102
|
+
end
|
103
|
+
|
104
|
+
# Builds the object from hash
|
105
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
106
|
+
# @return [Object] Returns the model itself
|
107
|
+
def build_from_hash(attributes)
|
108
|
+
return nil unless attributes.is_a?(Hash)
|
109
|
+
self.class.openapi_types.each_pair do |key, type|
|
110
|
+
if type =~ /\AArray<(.*)>/i
|
111
|
+
# check to ensure the input is an array given that the attribute
|
112
|
+
# is documented as an array but the input is not
|
113
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
114
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
115
|
+
end
|
116
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
117
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
118
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
119
|
+
end
|
120
|
+
|
121
|
+
self
|
122
|
+
end
|
123
|
+
|
124
|
+
# Deserializes the data based on type
|
125
|
+
# @param string type Data type
|
126
|
+
# @param string value Value to be deserialized
|
127
|
+
# @return [Object] Deserialized data
|
128
|
+
def _deserialize(type, value)
|
129
|
+
case type.to_sym
|
130
|
+
when :DateTime
|
131
|
+
DateTime.parse(value)
|
132
|
+
when :Date
|
133
|
+
Date.parse(value)
|
134
|
+
when :String
|
135
|
+
value.to_s
|
136
|
+
when :Integer
|
137
|
+
value.to_i
|
138
|
+
when :Float
|
139
|
+
value.to_f
|
140
|
+
when :Boolean
|
141
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
142
|
+
true
|
143
|
+
else
|
144
|
+
false
|
145
|
+
end
|
146
|
+
when :Object
|
147
|
+
# generic object (usually a Hash), return directly
|
148
|
+
value
|
149
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
150
|
+
inner_type = Regexp.last_match[:inner_type]
|
151
|
+
value.map { |v| _deserialize(inner_type, v) }
|
152
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
153
|
+
k_type = Regexp.last_match[:k_type]
|
154
|
+
v_type = Regexp.last_match[:v_type]
|
155
|
+
{}.tap do |hash|
|
156
|
+
value.each do |k, v|
|
157
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
158
|
+
end
|
159
|
+
end
|
160
|
+
else # model
|
161
|
+
MailSlurpClient.const_get(type).build_from_hash(value)
|
162
|
+
end
|
163
|
+
end
|
164
|
+
|
165
|
+
# Returns the string representation of the object
|
166
|
+
# @return [String] String presentation of the object
|
167
|
+
def to_s
|
168
|
+
to_hash.to_s
|
169
|
+
end
|
170
|
+
|
171
|
+
# to_body is an alias to to_hash (backward compatibility)
|
172
|
+
# @return [Hash] Returns the object in the form of hash
|
173
|
+
def to_body
|
174
|
+
to_hash
|
175
|
+
end
|
176
|
+
|
177
|
+
# Returns the object in the form of hash
|
178
|
+
# @return [Hash] Returns the object in the form of hash
|
179
|
+
def to_hash
|
180
|
+
hash = {}
|
181
|
+
self.class.attribute_map.each_pair do |attr, param|
|
182
|
+
value = self.send(attr)
|
183
|
+
if value.nil?
|
184
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
185
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
186
|
+
end
|
187
|
+
|
188
|
+
hash[param] = _to_hash(value)
|
189
|
+
end
|
190
|
+
hash
|
191
|
+
end
|
192
|
+
|
193
|
+
# Outputs non-array value in the form of hash
|
194
|
+
# For object, use to_hash. Otherwise, just return the value
|
195
|
+
# @param [Object] value Any valid value
|
196
|
+
# @return [Hash] Returns the value in the form of hash
|
197
|
+
def _to_hash(value)
|
198
|
+
if value.is_a?(Array)
|
199
|
+
value.compact.map { |v| _to_hash(v) }
|
200
|
+
elsif value.is_a?(Hash)
|
201
|
+
{}.tap do |hash|
|
202
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
203
|
+
end
|
204
|
+
elsif value.respond_to? :to_hash
|
205
|
+
value.to_hash
|
206
|
+
else
|
207
|
+
value
|
208
|
+
end
|
209
|
+
end
|
210
|
+
end
|
211
|
+
end
|