mailslurp_client 11.16666.0 → 12.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/mailslurp_client.rb +1 -1
- data/lib/mailslurp_client/api/attachment_controller_api.rb +3 -0
- data/lib/mailslurp_client/api/email_controller_api.rb +10 -10
- data/lib/mailslurp_client/models/{attachment_entity.rb → attachment_projection.rb} +7 -18
- data/lib/mailslurp_client/models/forward_email_options.rb +11 -1
- data/lib/mailslurp_client/models/page_attachment_entity.rb +1 -1
- data/lib/mailslurp_client/models/page_sent_email_projection.rb +6 -0
- data/lib/mailslurp_client/models/upload_attachment_options.rb +5 -0
- data/lib/mailslurp_client/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 60f577d6063320652418dd98cc34b8c5eac1520c9de0502b5618b15074eb174a
|
4
|
+
data.tar.gz: 8c5f529426d03525054f96133e15c367aa2eb05c9aa5035f30d9bd6870c183b9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ec20b6535a6cbc97d2d2de3d2e841a639a12a1a77a9707249f833a587e7c33bb0d988ca42697e7e81c9f22f7a055094679adf8f1bef79e07c270dddf4db16137
|
7
|
+
data.tar.gz: aea00c01340e7b541c2b512c9e9850413844bcba73542ed688eec20bbbfe1a6051cac661f1adfe769c2e08916c2bc7f52eb815c37096dac94d4dc1f63faa1607
|
data/lib/mailslurp_client.rb
CHANGED
@@ -20,8 +20,8 @@ require 'mailslurp_client/configuration'
|
|
20
20
|
require 'mailslurp_client/models/abstract_webhook_payload'
|
21
21
|
require 'mailslurp_client/models/alias_dto'
|
22
22
|
require 'mailslurp_client/models/alias_projection'
|
23
|
-
require 'mailslurp_client/models/attachment_entity'
|
24
23
|
require 'mailslurp_client/models/attachment_meta_data'
|
24
|
+
require 'mailslurp_client/models/attachment_projection'
|
25
25
|
require 'mailslurp_client/models/basic_auth_options'
|
26
26
|
require 'mailslurp_client/models/bulk_send_email_options'
|
27
27
|
require 'mailslurp_client/models/contact_dto'
|
@@ -268,6 +268,7 @@ module MailSlurpClient
|
|
268
268
|
# Get email attachments
|
269
269
|
# Get all attachments in paginated response. Each entity contains meta data for the attachment such as `name` and `content-type`. Use the `attachmentId` and the download endpoints to get the file contents.
|
270
270
|
# @param [Hash] opts the optional parameters
|
271
|
+
# @option opts [String] :file_name_filter Optional file name and content type search filter
|
271
272
|
# @option opts [Integer] :page Optional page index event list pagination (default to 0)
|
272
273
|
# @option opts [Integer] :size Optional page size event list pagination (default to 20)
|
273
274
|
# @option opts [String] :sort Optional createdAt sort direction ASC or DESC (default to 'ASC')
|
@@ -280,6 +281,7 @@ module MailSlurpClient
|
|
280
281
|
# Get email attachments
|
281
282
|
# Get all attachments in paginated response. Each entity contains meta data for the attachment such as `name` and `content-type`. Use the `attachmentId` and the download endpoints to get the file contents.
|
282
283
|
# @param [Hash] opts the optional parameters
|
284
|
+
# @option opts [String] :file_name_filter Optional file name and content type search filter
|
283
285
|
# @option opts [Integer] :page Optional page index event list pagination
|
284
286
|
# @option opts [Integer] :size Optional page size event list pagination
|
285
287
|
# @option opts [String] :sort Optional createdAt sort direction ASC or DESC
|
@@ -297,6 +299,7 @@ module MailSlurpClient
|
|
297
299
|
|
298
300
|
# query parameters
|
299
301
|
query_params = opts[:query_params] || {}
|
302
|
+
query_params[:'fileNameFilter'] = opts[:'file_name_filter'] if !opts[:'file_name_filter'].nil?
|
300
303
|
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
301
304
|
query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil?
|
302
305
|
query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
|
@@ -204,7 +204,7 @@ module MailSlurpClient
|
|
204
204
|
return data, status_code, headers
|
205
205
|
end
|
206
206
|
|
207
|
-
# Get email attachment as base64 encoded string alternative to binary responses. Decode the `base64FileContents` as a `utf-8` encoded string or array of bytes depending on the `contentType`.
|
207
|
+
# Get email attachment as base64 encoded string as an alternative to binary responses. Decode the `base64FileContents` as a `utf-8` encoded string or array of bytes depending on the `contentType`.
|
208
208
|
# Returns the specified attachment for a given email as a base 64 encoded string. The response type is application/json. This method is similar to the `downloadAttachment` method but allows some clients to get around issues with binary responses.
|
209
209
|
# @param attachment_id [String] ID of attachment
|
210
210
|
# @param email_id [String] ID of email
|
@@ -215,7 +215,7 @@ module MailSlurpClient
|
|
215
215
|
data
|
216
216
|
end
|
217
217
|
|
218
|
-
# Get email attachment as base64 encoded string alternative to binary responses. Decode the `base64FileContents` as a `utf-8` encoded string or array of bytes depending on the `contentType`.
|
218
|
+
# Get email attachment as base64 encoded string as an alternative to binary responses. Decode the `base64FileContents` as a `utf-8` encoded string or array of bytes depending on the `contentType`.
|
219
219
|
# Returns the specified attachment for a given email as a base 64 encoded string. The response type is application/json. This method is similar to the `downloadAttachment` method but allows some clients to get around issues with binary responses.
|
220
220
|
# @param attachment_id [String] ID of attachment
|
221
221
|
# @param email_id [String] ID of email
|
@@ -397,7 +397,7 @@ module MailSlurpClient
|
|
397
397
|
end
|
398
398
|
|
399
399
|
# Forward email to recipients
|
400
|
-
# Forward an existing email to new recipients.
|
400
|
+
# Forward an existing email to new recipients. The sender of the email will be the inbox that received the email you are forwarding. You can override the sender with the `from` option. Note you must have access to the from address in MailSlurp to use the override. For more control consider fetching the email and sending it a new using the send email endpoints.
|
401
401
|
# @param email_id [String] ID of email
|
402
402
|
# @param forward_email_options [ForwardEmailOptions] forwardEmailOptions
|
403
403
|
# @param [Hash] opts the optional parameters
|
@@ -408,7 +408,7 @@ module MailSlurpClient
|
|
408
408
|
end
|
409
409
|
|
410
410
|
# Forward email to recipients
|
411
|
-
# Forward an existing email to new recipients.
|
411
|
+
# Forward an existing email to new recipients. The sender of the email will be the inbox that received the email you are forwarding. You can override the sender with the `from` option. Note you must have access to the from address in MailSlurp to use the override. For more control consider fetching the email and sending it a new using the send email endpoints.
|
412
412
|
# @param email_id [String] ID of email
|
413
413
|
# @param forward_email_options [ForwardEmailOptions] forwardEmailOptions
|
414
414
|
# @param [Hash] opts the optional parameters
|
@@ -532,7 +532,7 @@ module MailSlurpClient
|
|
532
532
|
return data, status_code, headers
|
533
533
|
end
|
534
534
|
|
535
|
-
# Get all email attachment metadata. Metadata includes name and
|
535
|
+
# Get all email attachment metadata. Metadata includes name and size of attachments.
|
536
536
|
# Returns an array of attachment metadata such as name and content-type for a given email if present.
|
537
537
|
# @param email_id [String] ID of email
|
538
538
|
# @param [Hash] opts the optional parameters
|
@@ -542,7 +542,7 @@ module MailSlurpClient
|
|
542
542
|
data
|
543
543
|
end
|
544
544
|
|
545
|
-
# Get all email attachment metadata. Metadata includes name and
|
545
|
+
# Get all email attachment metadata. Metadata includes name and size of attachments.
|
546
546
|
# Returns an array of attachment metadata such as name and content-type for a given email if present.
|
547
547
|
# @param email_id [String] ID of email
|
548
548
|
# @param [Hash] opts the optional parameters
|
@@ -927,7 +927,7 @@ module MailSlurpClient
|
|
927
927
|
return data, status_code, headers
|
928
928
|
end
|
929
929
|
|
930
|
-
# Get all emails in all inboxes. Email API list all.
|
930
|
+
# Get all emails in all inboxes in paginated form. Email API list all.
|
931
931
|
# By default returns all emails across all inboxes sorted by ascending created at date. Responses are paginated. You can restrict results to a list of inbox IDs. You can also filter out read messages
|
932
932
|
# @param [Hash] opts the optional parameters
|
933
933
|
# @option opts [Array<String>] :inbox_id Optional inbox ids to filter by. Can be repeated. By default will use all inboxes belonging to your account.
|
@@ -941,7 +941,7 @@ module MailSlurpClient
|
|
941
941
|
data
|
942
942
|
end
|
943
943
|
|
944
|
-
# Get all emails in all inboxes. Email API list all.
|
944
|
+
# Get all emails in all inboxes in paginated form. Email API list all.
|
945
945
|
# By default returns all emails across all inboxes sorted by ascending created at date. Responses are paginated. You can restrict results to a list of inbox IDs. You can also filter out read messages
|
946
946
|
# @param [Hash] opts the optional parameters
|
947
947
|
# @option opts [Array<String>] :inbox_id Optional inbox ids to filter by. Can be repeated. By default will use all inboxes belonging to your account.
|
@@ -1446,7 +1446,7 @@ module MailSlurpClient
|
|
1446
1446
|
end
|
1447
1447
|
|
1448
1448
|
# Validate email HTML contents
|
1449
|
-
# Validate the HTML content of email if HTML is found. Considered valid if no HTML.
|
1449
|
+
# Validate the HTML content of email if HTML is found. Considered valid if no HTML is present.
|
1450
1450
|
# @param email_id [String] ID of email
|
1451
1451
|
# @param [Hash] opts the optional parameters
|
1452
1452
|
# @return [ValidationDto]
|
@@ -1456,7 +1456,7 @@ module MailSlurpClient
|
|
1456
1456
|
end
|
1457
1457
|
|
1458
1458
|
# Validate email HTML contents
|
1459
|
-
# Validate the HTML content of email if HTML is found. Considered valid if no HTML.
|
1459
|
+
# Validate the HTML content of email if HTML is found. Considered valid if no HTML is present.
|
1460
1460
|
# @param email_id [String] ID of email
|
1461
1461
|
# @param [Hash] opts the optional parameters
|
1462
1462
|
# @return [Array<(ValidationDto, Integer, Hash)>] ValidationDto data, response status code and response headers
|
@@ -13,17 +13,18 @@ OpenAPI Generator version: 4.3.1
|
|
13
13
|
require 'date'
|
14
14
|
|
15
15
|
module MailSlurpClient
|
16
|
-
class
|
16
|
+
class AttachmentProjection
|
17
|
+
# Attachment ID
|
17
18
|
attr_accessor :attachment_id
|
18
19
|
|
20
|
+
# Content length of attachment in bytes
|
19
21
|
attr_accessor :content_length
|
20
22
|
|
23
|
+
# Content type of attachment.
|
21
24
|
attr_accessor :content_type
|
22
25
|
|
23
26
|
attr_accessor :created_at
|
24
27
|
|
25
|
-
attr_accessor :id
|
26
|
-
|
27
28
|
attr_accessor :name
|
28
29
|
|
29
30
|
attr_accessor :updated_at
|
@@ -37,7 +38,6 @@ module MailSlurpClient
|
|
37
38
|
:'content_length' => :'contentLength',
|
38
39
|
:'content_type' => :'contentType',
|
39
40
|
:'created_at' => :'createdAt',
|
40
|
-
:'id' => :'id',
|
41
41
|
:'name' => :'name',
|
42
42
|
:'updated_at' => :'updatedAt',
|
43
43
|
:'user_id' => :'userId'
|
@@ -51,7 +51,6 @@ module MailSlurpClient
|
|
51
51
|
:'content_length' => :'Integer',
|
52
52
|
:'content_type' => :'String',
|
53
53
|
:'created_at' => :'DateTime',
|
54
|
-
:'id' => :'String',
|
55
54
|
:'name' => :'String',
|
56
55
|
:'updated_at' => :'DateTime',
|
57
56
|
:'user_id' => :'String'
|
@@ -68,13 +67,13 @@ module MailSlurpClient
|
|
68
67
|
# @param [Hash] attributes Model attributes in the form of hash
|
69
68
|
def initialize(attributes = {})
|
70
69
|
if (!attributes.is_a?(Hash))
|
71
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `MailSlurpClient::
|
70
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `MailSlurpClient::AttachmentProjection` initialize method"
|
72
71
|
end
|
73
72
|
|
74
73
|
# check to see if the attribute exists and convert string to symbol for hash key
|
75
74
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
76
75
|
if (!self.class.attribute_map.key?(k.to_sym))
|
77
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `MailSlurpClient::
|
76
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `MailSlurpClient::AttachmentProjection`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
78
77
|
end
|
79
78
|
h[k.to_sym] = v
|
80
79
|
}
|
@@ -95,10 +94,6 @@ module MailSlurpClient
|
|
95
94
|
self.created_at = attributes[:'created_at']
|
96
95
|
end
|
97
96
|
|
98
|
-
if attributes.key?(:'id')
|
99
|
-
self.id = attributes[:'id']
|
100
|
-
end
|
101
|
-
|
102
97
|
if attributes.key?(:'name')
|
103
98
|
self.name = attributes[:'name']
|
104
99
|
end
|
@@ -116,10 +111,6 @@ module MailSlurpClient
|
|
116
111
|
# @return Array for valid properties with the reasons
|
117
112
|
def list_invalid_properties
|
118
113
|
invalid_properties = Array.new
|
119
|
-
if @attachment_id.nil?
|
120
|
-
invalid_properties.push('invalid value for "attachment_id", attachment_id cannot be nil.')
|
121
|
-
end
|
122
|
-
|
123
114
|
if @created_at.nil?
|
124
115
|
invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
|
125
116
|
end
|
@@ -138,7 +129,6 @@ module MailSlurpClient
|
|
138
129
|
# Check to see if the all the properties in the model are valid
|
139
130
|
# @return true if the model is valid
|
140
131
|
def valid?
|
141
|
-
return false if @attachment_id.nil?
|
142
132
|
return false if @created_at.nil?
|
143
133
|
return false if @updated_at.nil?
|
144
134
|
return false if @user_id.nil?
|
@@ -154,7 +144,6 @@ module MailSlurpClient
|
|
154
144
|
content_length == o.content_length &&
|
155
145
|
content_type == o.content_type &&
|
156
146
|
created_at == o.created_at &&
|
157
|
-
id == o.id &&
|
158
147
|
name == o.name &&
|
159
148
|
updated_at == o.updated_at &&
|
160
149
|
user_id == o.user_id
|
@@ -169,7 +158,7 @@ module MailSlurpClient
|
|
169
158
|
# Calculates hash code according to all attributes.
|
170
159
|
# @return [Integer] Hash code
|
171
160
|
def hash
|
172
|
-
[attachment_id, content_length, content_type, created_at,
|
161
|
+
[attachment_id, content_length, content_type, created_at, name, updated_at, user_id].hash
|
173
162
|
end
|
174
163
|
|
175
164
|
# Builds the object from hash
|
@@ -21,6 +21,9 @@ module MailSlurpClient
|
|
21
21
|
# Optional cc recipients
|
22
22
|
attr_accessor :cc
|
23
23
|
|
24
|
+
# Optional from override
|
25
|
+
attr_accessor :from
|
26
|
+
|
24
27
|
# Subject for forwarded email
|
25
28
|
attr_accessor :subject
|
26
29
|
|
@@ -32,6 +35,7 @@ module MailSlurpClient
|
|
32
35
|
{
|
33
36
|
:'bcc' => :'bcc',
|
34
37
|
:'cc' => :'cc',
|
38
|
+
:'from' => :'from',
|
35
39
|
:'subject' => :'subject',
|
36
40
|
:'to' => :'to'
|
37
41
|
}
|
@@ -42,6 +46,7 @@ module MailSlurpClient
|
|
42
46
|
{
|
43
47
|
:'bcc' => :'Array<String>',
|
44
48
|
:'cc' => :'Array<String>',
|
49
|
+
:'from' => :'String',
|
45
50
|
:'subject' => :'String',
|
46
51
|
:'to' => :'Array<String>'
|
47
52
|
}
|
@@ -80,6 +85,10 @@ module MailSlurpClient
|
|
80
85
|
end
|
81
86
|
end
|
82
87
|
|
88
|
+
if attributes.key?(:'from')
|
89
|
+
self.from = attributes[:'from']
|
90
|
+
end
|
91
|
+
|
83
92
|
if attributes.key?(:'subject')
|
84
93
|
self.subject = attributes[:'subject']
|
85
94
|
end
|
@@ -111,6 +120,7 @@ module MailSlurpClient
|
|
111
120
|
self.class == o.class &&
|
112
121
|
bcc == o.bcc &&
|
113
122
|
cc == o.cc &&
|
123
|
+
from == o.from &&
|
114
124
|
subject == o.subject &&
|
115
125
|
to == o.to
|
116
126
|
end
|
@@ -124,7 +134,7 @@ module MailSlurpClient
|
|
124
134
|
# Calculates hash code according to all attributes.
|
125
135
|
# @return [Integer] Hash code
|
126
136
|
def hash
|
127
|
-
[bcc, cc, subject, to].hash
|
137
|
+
[bcc, cc, from, subject, to].hash
|
128
138
|
end
|
129
139
|
|
130
140
|
# Builds the object from hash
|
@@ -15,6 +15,7 @@ require 'date'
|
|
15
15
|
module MailSlurpClient
|
16
16
|
# Paginated sent email results. Page index starts at zero. Projection results may omit larger entity fields. For fetching a full sent email entity use the projection ID with individual method calls.
|
17
17
|
class PageSentEmailProjection
|
18
|
+
# Collection of items
|
18
19
|
attr_accessor :content
|
19
20
|
|
20
21
|
attr_accessor :empty
|
@@ -23,18 +24,23 @@ module MailSlurpClient
|
|
23
24
|
|
24
25
|
attr_accessor :last
|
25
26
|
|
27
|
+
# Page number starting at 0
|
26
28
|
attr_accessor :number
|
27
29
|
|
30
|
+
# Number of items returned
|
28
31
|
attr_accessor :number_of_elements
|
29
32
|
|
30
33
|
attr_accessor :pageable
|
31
34
|
|
35
|
+
# Size of page requested
|
32
36
|
attr_accessor :size
|
33
37
|
|
34
38
|
attr_accessor :sort
|
35
39
|
|
40
|
+
# Total number of items available for querying
|
36
41
|
attr_accessor :total_elements
|
37
42
|
|
43
|
+
# Total number of pages available
|
38
44
|
attr_accessor :total_pages
|
39
45
|
|
40
46
|
# Attribute mapping from ruby-style variable name to JSON key.
|
@@ -80,12 +80,17 @@ module MailSlurpClient
|
|
80
80
|
# @return Array for valid properties with the reasons
|
81
81
|
def list_invalid_properties
|
82
82
|
invalid_properties = Array.new
|
83
|
+
if @base64_contents.nil?
|
84
|
+
invalid_properties.push('invalid value for "base64_contents", base64_contents cannot be nil.')
|
85
|
+
end
|
86
|
+
|
83
87
|
invalid_properties
|
84
88
|
end
|
85
89
|
|
86
90
|
# Check to see if the all the properties in the model are valid
|
87
91
|
# @return true if the model is valid
|
88
92
|
def valid?
|
93
|
+
return false if @base64_contents.nil?
|
89
94
|
true
|
90
95
|
end
|
91
96
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mailslurp_client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 12.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- mailslurp
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-05-
|
11
|
+
date: 2021-05-22 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Create emails addresses in Ruby then send and receive real emails and
|
14
14
|
attachments. See https://www.mailslurp.com/docs/ruby/ for full Ruby documentation.
|
@@ -46,8 +46,8 @@ files:
|
|
46
46
|
- lib/mailslurp_client/models/abstract_webhook_payload.rb
|
47
47
|
- lib/mailslurp_client/models/alias_dto.rb
|
48
48
|
- lib/mailslurp_client/models/alias_projection.rb
|
49
|
-
- lib/mailslurp_client/models/attachment_entity.rb
|
50
49
|
- lib/mailslurp_client/models/attachment_meta_data.rb
|
50
|
+
- lib/mailslurp_client/models/attachment_projection.rb
|
51
51
|
- lib/mailslurp_client/models/basic_auth_options.rb
|
52
52
|
- lib/mailslurp_client/models/bulk_send_email_options.rb
|
53
53
|
- lib/mailslurp_client/models/contact_dto.rb
|