mailslurp_client 15.2.7 → 15.4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (33) hide show
  1. checksums.yaml +4 -4
  2. data/lib/mailslurp_client/api/inbox_controller_api.rb +119 -0
  3. data/lib/mailslurp_client/models/alias_projection.rb +15 -15
  4. data/lib/mailslurp_client/models/attachment_projection.rb +14 -14
  5. data/lib/mailslurp_client/models/email_projection.rb +10 -10
  6. data/lib/mailslurp_client/models/expired_inbox_record_projection.rb +15 -15
  7. data/lib/mailslurp_client/models/inbox_by_email_address_result.rb +220 -0
  8. data/lib/mailslurp_client/models/inbox_id_item.rb +225 -0
  9. data/lib/mailslurp_client/models/inbox_ids_result.rb +213 -0
  10. data/lib/mailslurp_client/models/page_alias.rb +19 -19
  11. data/lib/mailslurp_client/models/page_attachment_entity.rb +19 -19
  12. data/lib/mailslurp_client/models/page_bounced_email.rb +19 -19
  13. data/lib/mailslurp_client/models/page_bounced_recipients.rb +19 -19
  14. data/lib/mailslurp_client/models/page_contact_projection.rb +19 -19
  15. data/lib/mailslurp_client/models/page_email_preview.rb +19 -19
  16. data/lib/mailslurp_client/models/page_email_projection.rb +19 -19
  17. data/lib/mailslurp_client/models/page_expired_inbox_record_projection.rb +19 -19
  18. data/lib/mailslurp_client/models/page_group_projection.rb +19 -19
  19. data/lib/mailslurp_client/models/page_inbox_forwarder_dto.rb +19 -19
  20. data/lib/mailslurp_client/models/page_inbox_projection.rb +19 -19
  21. data/lib/mailslurp_client/models/page_inbox_ruleset_dto.rb +19 -19
  22. data/lib/mailslurp_client/models/page_missed_email_projection.rb +19 -19
  23. data/lib/mailslurp_client/models/page_organization_inbox_projection.rb +19 -19
  24. data/lib/mailslurp_client/models/page_template_projection.rb +19 -19
  25. data/lib/mailslurp_client/models/page_thread_projection.rb +19 -19
  26. data/lib/mailslurp_client/models/page_tracking_pixel_projection.rb +19 -19
  27. data/lib/mailslurp_client/models/page_unknown_missed_email_projection.rb +19 -19
  28. data/lib/mailslurp_client/models/page_webhook_projection.rb +19 -19
  29. data/lib/mailslurp_client/models/page_webhook_result.rb +19 -19
  30. data/lib/mailslurp_client/models/thread_projection.rb +10 -10
  31. data/lib/mailslurp_client/version.rb +1 -1
  32. data/lib/mailslurp_client.rb +3 -0
  33. metadata +5 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 59b68d8bd3ad6e2654ba61e86f748d782b941c233856057865b485c31644f08d
4
- data.tar.gz: 0ee003c7a90a97c5c0800debb8667705f34fe96d7ec17f08fcacb6734f0fbfe4
3
+ metadata.gz: bf4a01971704062a8c0fc5c66e177cc1ff525f13010caa9676b35650e7a51763
4
+ data.tar.gz: 1d8c3eccf5f2950001ea6f4b2f35520703b8f630b2f3724428c03ea91ecf68c4
5
5
  SHA512:
6
- metadata.gz: b1b44c00dfc83ab3ee4948c0b3da5456ce1259013c1daac796460c7ac44077660932143bd87b3a087c78ef356ee3485196f5ec1772200125c36f0f7ef3582eaa
7
- data.tar.gz: b3229f57b1063c78ea93f28ccb046bae46faba70980a64baa84c5d09a1f0d983979c98c482bce3737108d2356f5e4227d21f8d3a971911e333c811660726f7ff
6
+ metadata.gz: df6322da1dcde97c72555421e1279aafaa70d374c3afbc3a8653debaae60f4c9b2e99c020d543acb355bf47a871dd917cae33b22db983bd2def73f6ebee32546
7
+ data.tar.gz: f13859837c4d6702a62e26f05123c64f19679a12a93a4caba4fd6d1180fe2021a7c6587145ca5282b2098df35ed041a976b62d953770a7d1bc69caafdeb95ab9
@@ -783,6 +783,69 @@ module MailSlurpClient
783
783
  return data, status_code, headers
784
784
  end
785
785
 
786
+ # Search for an inbox with the provided email address
787
+ # Get a inbox result by email address
788
+ # @param email_address [String]
789
+ # @param [Hash] opts the optional parameters
790
+ # @return [InboxByEmailAddressResult]
791
+ def get_inbox_by_email_address(email_address, opts = {})
792
+ data, _status_code, _headers = get_inbox_by_email_address_with_http_info(email_address, opts)
793
+ data
794
+ end
795
+
796
+ # Search for an inbox with the provided email address
797
+ # Get a inbox result by email address
798
+ # @param email_address [String]
799
+ # @param [Hash] opts the optional parameters
800
+ # @return [Array<(InboxByEmailAddressResult, Integer, Hash)>] InboxByEmailAddressResult data, response status code and response headers
801
+ def get_inbox_by_email_address_with_http_info(email_address, opts = {})
802
+ if @api_client.config.debugging
803
+ @api_client.config.logger.debug 'Calling API: InboxControllerApi.get_inbox_by_email_address ...'
804
+ end
805
+ # verify the required parameter 'email_address' is set
806
+ if @api_client.config.client_side_validation && email_address.nil?
807
+ fail ArgumentError, "Missing the required parameter 'email_address' when calling InboxControllerApi.get_inbox_by_email_address"
808
+ end
809
+ # resource path
810
+ local_var_path = '/inboxes/byEmailAddress'
811
+
812
+ # query parameters
813
+ query_params = opts[:query_params] || {}
814
+ query_params[:'emailAddress'] = email_address
815
+
816
+ # header parameters
817
+ header_params = opts[:header_params] || {}
818
+ # HTTP header 'Accept' (if needed)
819
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
820
+
821
+ # form parameters
822
+ form_params = opts[:form_params] || {}
823
+
824
+ # http body (model)
825
+ post_body = opts[:body]
826
+
827
+ # return_type
828
+ return_type = opts[:return_type] || 'InboxByEmailAddressResult'
829
+
830
+ # auth_names
831
+ auth_names = opts[:auth_names] || ['API_KEY']
832
+
833
+ new_options = opts.merge(
834
+ :header_params => header_params,
835
+ :query_params => query_params,
836
+ :form_params => form_params,
837
+ :body => post_body,
838
+ :auth_names => auth_names,
839
+ :return_type => return_type
840
+ )
841
+
842
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
843
+ if @api_client.config.debugging
844
+ @api_client.config.logger.debug "API called: InboxControllerApi#get_inbox_by_email_address\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
845
+ end
846
+ return data, status_code, headers
847
+ end
848
+
786
849
  # Get total inbox count
787
850
  # @param [Hash] opts the optional parameters
788
851
  # @return [CountDto]
@@ -978,6 +1041,62 @@ module MailSlurpClient
978
1041
  return data, status_code, headers
979
1042
  end
980
1043
 
1044
+ # Get all inbox IDs
1045
+ # Get list of inbox IDs
1046
+ # @param [Hash] opts the optional parameters
1047
+ # @return [InboxIdsResult]
1048
+ def get_inbox_ids(opts = {})
1049
+ data, _status_code, _headers = get_inbox_ids_with_http_info(opts)
1050
+ data
1051
+ end
1052
+
1053
+ # Get all inbox IDs
1054
+ # Get list of inbox IDs
1055
+ # @param [Hash] opts the optional parameters
1056
+ # @return [Array<(InboxIdsResult, Integer, Hash)>] InboxIdsResult data, response status code and response headers
1057
+ def get_inbox_ids_with_http_info(opts = {})
1058
+ if @api_client.config.debugging
1059
+ @api_client.config.logger.debug 'Calling API: InboxControllerApi.get_inbox_ids ...'
1060
+ end
1061
+ # resource path
1062
+ local_var_path = '/inboxes/ids'
1063
+
1064
+ # query parameters
1065
+ query_params = opts[:query_params] || {}
1066
+
1067
+ # header parameters
1068
+ header_params = opts[:header_params] || {}
1069
+ # HTTP header 'Accept' (if needed)
1070
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
1071
+
1072
+ # form parameters
1073
+ form_params = opts[:form_params] || {}
1074
+
1075
+ # http body (model)
1076
+ post_body = opts[:body]
1077
+
1078
+ # return_type
1079
+ return_type = opts[:return_type] || 'InboxIdsResult'
1080
+
1081
+ # auth_names
1082
+ auth_names = opts[:auth_names] || ['API_KEY']
1083
+
1084
+ new_options = opts.merge(
1085
+ :header_params => header_params,
1086
+ :query_params => query_params,
1087
+ :form_params => form_params,
1088
+ :body => post_body,
1089
+ :auth_names => auth_names,
1090
+ :return_type => return_type
1091
+ )
1092
+
1093
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1094
+ if @api_client.config.debugging
1095
+ @api_client.config.logger.debug "API called: InboxControllerApi#get_inbox_ids\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1096
+ end
1097
+ return data, status_code, headers
1098
+ end
1099
+
981
1100
  # Get Inbox Sent Emails
982
1101
  # Returns an inbox's sent email receipts. Call individual sent email endpoints for more details. Note for privacy reasons the full body of sent emails is never stored. An MD5 hash hex is available for comparison instead.
983
1102
  # @param inbox_id [String]
@@ -19,12 +19,12 @@ module MailSlurpClient
19
19
 
20
20
  attr_accessor :id
21
21
 
22
- attr_accessor :email_address
23
-
24
22
  attr_accessor :inbox_id
25
23
 
26
24
  attr_accessor :user_id
27
25
 
26
+ attr_accessor :email_address
27
+
28
28
  attr_accessor :created_at
29
29
 
30
30
  attr_accessor :use_threads
@@ -36,9 +36,9 @@ module MailSlurpClient
36
36
  {
37
37
  :'name' => :'name',
38
38
  :'id' => :'id',
39
- :'email_address' => :'emailAddress',
40
39
  :'inbox_id' => :'inboxId',
41
40
  :'user_id' => :'userId',
41
+ :'email_address' => :'emailAddress',
42
42
  :'created_at' => :'createdAt',
43
43
  :'use_threads' => :'useThreads',
44
44
  :'updated_at' => :'updatedAt'
@@ -50,9 +50,9 @@ module MailSlurpClient
50
50
  {
51
51
  :'name' => :'String',
52
52
  :'id' => :'String',
53
- :'email_address' => :'String',
54
53
  :'inbox_id' => :'String',
55
54
  :'user_id' => :'String',
55
+ :'email_address' => :'String',
56
56
  :'created_at' => :'DateTime',
57
57
  :'use_threads' => :'Boolean',
58
58
  :'updated_at' => :'DateTime'
@@ -88,10 +88,6 @@ module MailSlurpClient
88
88
  self.id = attributes[:'id']
89
89
  end
90
90
 
91
- if attributes.key?(:'email_address')
92
- self.email_address = attributes[:'email_address']
93
- end
94
-
95
91
  if attributes.key?(:'inbox_id')
96
92
  self.inbox_id = attributes[:'inbox_id']
97
93
  end
@@ -100,6 +96,10 @@ module MailSlurpClient
100
96
  self.user_id = attributes[:'user_id']
101
97
  end
102
98
 
99
+ if attributes.key?(:'email_address')
100
+ self.email_address = attributes[:'email_address']
101
+ end
102
+
103
103
  if attributes.key?(:'created_at')
104
104
  self.created_at = attributes[:'created_at']
105
105
  end
@@ -121,10 +121,6 @@ module MailSlurpClient
121
121
  invalid_properties.push('invalid value for "id", id cannot be nil.')
122
122
  end
123
123
 
124
- if @email_address.nil?
125
- invalid_properties.push('invalid value for "email_address", email_address cannot be nil.')
126
- end
127
-
128
124
  if @inbox_id.nil?
129
125
  invalid_properties.push('invalid value for "inbox_id", inbox_id cannot be nil.')
130
126
  end
@@ -133,6 +129,10 @@ module MailSlurpClient
133
129
  invalid_properties.push('invalid value for "user_id", user_id cannot be nil.')
134
130
  end
135
131
 
132
+ if @email_address.nil?
133
+ invalid_properties.push('invalid value for "email_address", email_address cannot be nil.')
134
+ end
135
+
136
136
  if @created_at.nil?
137
137
  invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
138
138
  end
@@ -148,9 +148,9 @@ module MailSlurpClient
148
148
  # @return true if the model is valid
149
149
  def valid?
150
150
  return false if @id.nil?
151
- return false if @email_address.nil?
152
151
  return false if @inbox_id.nil?
153
152
  return false if @user_id.nil?
153
+ return false if @email_address.nil?
154
154
  return false if @created_at.nil?
155
155
  return false if @updated_at.nil?
156
156
  true
@@ -163,9 +163,9 @@ module MailSlurpClient
163
163
  self.class == o.class &&
164
164
  name == o.name &&
165
165
  id == o.id &&
166
- email_address == o.email_address &&
167
166
  inbox_id == o.inbox_id &&
168
167
  user_id == o.user_id &&
168
+ email_address == o.email_address &&
169
169
  created_at == o.created_at &&
170
170
  use_threads == o.use_threads &&
171
171
  updated_at == o.updated_at
@@ -180,7 +180,7 @@ module MailSlurpClient
180
180
  # Calculates hash code according to all attributes.
181
181
  # @return [Integer] Hash code
182
182
  def hash
183
- [name, id, email_address, inbox_id, user_id, created_at, use_threads, updated_at].hash
183
+ [name, id, inbox_id, user_id, email_address, created_at, use_threads, updated_at].hash
184
184
  end
185
185
 
186
186
  # Builds the object from hash
@@ -19,9 +19,6 @@ module MailSlurpClient
19
19
  # Content length of attachment in bytes
20
20
  attr_accessor :content_length
21
21
 
22
- # Content type of attachment.
23
- attr_accessor :content_type
24
-
25
22
  attr_accessor :user_id
26
23
 
27
24
  # Attachment ID
@@ -31,16 +28,19 @@ module MailSlurpClient
31
28
 
32
29
  attr_accessor :updated_at
33
30
 
31
+ # Content type of attachment.
32
+ attr_accessor :content_type
33
+
34
34
  # Attribute mapping from ruby-style variable name to JSON key.
35
35
  def self.attribute_map
36
36
  {
37
37
  :'name' => :'name',
38
38
  :'content_length' => :'contentLength',
39
- :'content_type' => :'contentType',
40
39
  :'user_id' => :'userId',
41
40
  :'attachment_id' => :'attachmentId',
42
41
  :'created_at' => :'createdAt',
43
- :'updated_at' => :'updatedAt'
42
+ :'updated_at' => :'updatedAt',
43
+ :'content_type' => :'contentType'
44
44
  }
45
45
  end
46
46
 
@@ -49,11 +49,11 @@ module MailSlurpClient
49
49
  {
50
50
  :'name' => :'String',
51
51
  :'content_length' => :'Integer',
52
- :'content_type' => :'String',
53
52
  :'user_id' => :'String',
54
53
  :'attachment_id' => :'String',
55
54
  :'created_at' => :'DateTime',
56
- :'updated_at' => :'DateTime'
55
+ :'updated_at' => :'DateTime',
56
+ :'content_type' => :'String'
57
57
  }
58
58
  end
59
59
 
@@ -86,10 +86,6 @@ module MailSlurpClient
86
86
  self.content_length = attributes[:'content_length']
87
87
  end
88
88
 
89
- if attributes.key?(:'content_type')
90
- self.content_type = attributes[:'content_type']
91
- end
92
-
93
89
  if attributes.key?(:'user_id')
94
90
  self.user_id = attributes[:'user_id']
95
91
  end
@@ -105,6 +101,10 @@ module MailSlurpClient
105
101
  if attributes.key?(:'updated_at')
106
102
  self.updated_at = attributes[:'updated_at']
107
103
  end
104
+
105
+ if attributes.key?(:'content_type')
106
+ self.content_type = attributes[:'content_type']
107
+ end
108
108
  end
109
109
 
110
110
  # Show invalid properties with the reasons. Usually used together with valid?
@@ -147,11 +147,11 @@ module MailSlurpClient
147
147
  self.class == o.class &&
148
148
  name == o.name &&
149
149
  content_length == o.content_length &&
150
- content_type == o.content_type &&
151
150
  user_id == o.user_id &&
152
151
  attachment_id == o.attachment_id &&
153
152
  created_at == o.created_at &&
154
- updated_at == o.updated_at
153
+ updated_at == o.updated_at &&
154
+ content_type == o.content_type
155
155
  end
156
156
 
157
157
  # @see the `==` method
@@ -163,7 +163,7 @@ module MailSlurpClient
163
163
  # Calculates hash code according to all attributes.
164
164
  # @return [Integer] Hash code
165
165
  def hash
166
- [name, content_length, content_type, user_id, attachment_id, created_at, updated_at].hash
166
+ [name, content_length, user_id, attachment_id, created_at, updated_at, content_type].hash
167
167
  end
168
168
 
169
169
  # Builds the object from hash
@@ -19,10 +19,10 @@ module MailSlurpClient
19
19
 
20
20
  attr_accessor :from
21
21
 
22
- attr_accessor :subject
23
-
24
22
  attr_accessor :inbox_id
25
23
 
24
+ attr_accessor :subject
25
+
26
26
  attr_accessor :to
27
27
 
28
28
  attr_accessor :attachments
@@ -46,8 +46,8 @@ module MailSlurpClient
46
46
  {
47
47
  :'id' => :'id',
48
48
  :'from' => :'from',
49
- :'subject' => :'subject',
50
49
  :'inbox_id' => :'inboxId',
50
+ :'subject' => :'subject',
51
51
  :'to' => :'to',
52
52
  :'attachments' => :'attachments',
53
53
  :'bcc' => :'bcc',
@@ -65,8 +65,8 @@ module MailSlurpClient
65
65
  {
66
66
  :'id' => :'String',
67
67
  :'from' => :'String',
68
- :'subject' => :'String',
69
68
  :'inbox_id' => :'String',
69
+ :'subject' => :'String',
70
70
  :'to' => :'Array<String>',
71
71
  :'attachments' => :'Array<String>',
72
72
  :'bcc' => :'Array<String>',
@@ -108,14 +108,14 @@ module MailSlurpClient
108
108
  self.from = attributes[:'from']
109
109
  end
110
110
 
111
- if attributes.key?(:'subject')
112
- self.subject = attributes[:'subject']
113
- end
114
-
115
111
  if attributes.key?(:'inbox_id')
116
112
  self.inbox_id = attributes[:'inbox_id']
117
113
  end
118
114
 
115
+ if attributes.key?(:'subject')
116
+ self.subject = attributes[:'subject']
117
+ end
118
+
119
119
  if attributes.key?(:'to')
120
120
  if (value = attributes[:'to']).is_a?(Array)
121
121
  self.to = value
@@ -201,8 +201,8 @@ module MailSlurpClient
201
201
  self.class == o.class &&
202
202
  id == o.id &&
203
203
  from == o.from &&
204
- subject == o.subject &&
205
204
  inbox_id == o.inbox_id &&
205
+ subject == o.subject &&
206
206
  to == o.to &&
207
207
  attachments == o.attachments &&
208
208
  bcc == o.bcc &&
@@ -223,7 +223,7 @@ module MailSlurpClient
223
223
  # Calculates hash code according to all attributes.
224
224
  # @return [Integer] Hash code
225
225
  def hash
226
- [id, from, subject, inbox_id, to, attachments, bcc, cc, created_at, team_access, read, body_md5_hash, body_excerpt].hash
226
+ [id, from, inbox_id, subject, to, attachments, bcc, cc, created_at, team_access, read, body_md5_hash, body_excerpt].hash
227
227
  end
228
228
 
229
229
  # Builds the object from hash
@@ -16,18 +16,18 @@ module MailSlurpClient
16
16
  class ExpiredInboxRecordProjection
17
17
  attr_accessor :id
18
18
 
19
- attr_accessor :email_address
20
-
21
19
  attr_accessor :user_id
22
20
 
21
+ attr_accessor :email_address
22
+
23
23
  attr_accessor :created_at
24
24
 
25
25
  # Attribute mapping from ruby-style variable name to JSON key.
26
26
  def self.attribute_map
27
27
  {
28
28
  :'id' => :'id',
29
- :'email_address' => :'emailAddress',
30
29
  :'user_id' => :'userId',
30
+ :'email_address' => :'emailAddress',
31
31
  :'created_at' => :'createdAt'
32
32
  }
33
33
  end
@@ -36,8 +36,8 @@ module MailSlurpClient
36
36
  def self.openapi_types
37
37
  {
38
38
  :'id' => :'String',
39
- :'email_address' => :'String',
40
39
  :'user_id' => :'String',
40
+ :'email_address' => :'String',
41
41
  :'created_at' => :'DateTime'
42
42
  }
43
43
  end
@@ -67,14 +67,14 @@ module MailSlurpClient
67
67
  self.id = attributes[:'id']
68
68
  end
69
69
 
70
- if attributes.key?(:'email_address')
71
- self.email_address = attributes[:'email_address']
72
- end
73
-
74
70
  if attributes.key?(:'user_id')
75
71
  self.user_id = attributes[:'user_id']
76
72
  end
77
73
 
74
+ if attributes.key?(:'email_address')
75
+ self.email_address = attributes[:'email_address']
76
+ end
77
+
78
78
  if attributes.key?(:'created_at')
79
79
  self.created_at = attributes[:'created_at']
80
80
  end
@@ -88,14 +88,14 @@ module MailSlurpClient
88
88
  invalid_properties.push('invalid value for "id", id cannot be nil.')
89
89
  end
90
90
 
91
- if @email_address.nil?
92
- invalid_properties.push('invalid value for "email_address", email_address cannot be nil.')
93
- end
94
-
95
91
  if @user_id.nil?
96
92
  invalid_properties.push('invalid value for "user_id", user_id cannot be nil.')
97
93
  end
98
94
 
95
+ if @email_address.nil?
96
+ invalid_properties.push('invalid value for "email_address", email_address cannot be nil.')
97
+ end
98
+
99
99
  if @created_at.nil?
100
100
  invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
101
101
  end
@@ -107,8 +107,8 @@ module MailSlurpClient
107
107
  # @return true if the model is valid
108
108
  def valid?
109
109
  return false if @id.nil?
110
- return false if @email_address.nil?
111
110
  return false if @user_id.nil?
111
+ return false if @email_address.nil?
112
112
  return false if @created_at.nil?
113
113
  true
114
114
  end
@@ -119,8 +119,8 @@ module MailSlurpClient
119
119
  return true if self.equal?(o)
120
120
  self.class == o.class &&
121
121
  id == o.id &&
122
- email_address == o.email_address &&
123
122
  user_id == o.user_id &&
123
+ email_address == o.email_address &&
124
124
  created_at == o.created_at
125
125
  end
126
126
 
@@ -133,7 +133,7 @@ module MailSlurpClient
133
133
  # Calculates hash code according to all attributes.
134
134
  # @return [Integer] Hash code
135
135
  def hash
136
- [id, email_address, user_id, created_at].hash
136
+ [id, user_id, email_address, created_at].hash
137
137
  end
138
138
 
139
139
  # Builds the object from hash