mailslurp_client 12.6.4 → 12.7.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.rb +7 -0
- data/lib/mailslurp_client/api/email_controller_api.rb +7 -5
- data/lib/mailslurp_client/api/inbox_forwarder_controller_api.rb +548 -0
- data/lib/mailslurp_client/models/create_inbox_forwarder_options.rb +275 -0
- data/lib/mailslurp_client/models/domain_preview.rb +66 -4
- data/lib/mailslurp_client/models/inbox_forwarder_dto.rb +317 -0
- data/lib/mailslurp_client/models/inbox_forwarder_test_options.rb +211 -0
- data/lib/mailslurp_client/models/inbox_forwarder_test_result.rb +227 -0
- data/lib/mailslurp_client/models/page_inbox_forwarder_dto.rb +299 -0
- data/lib/mailslurp_client/models/test_new_inbox_forwarder_options.rb +225 -0
- data/lib/mailslurp_client/version.rb +1 -1
- metadata +9 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8d907fe29af9707e86cda64ddeb8374eda666440f3bb1e22e3d198393659bf00
|
4
|
+
data.tar.gz: 33fb186e151fb3e226050b3c011826cdbb78913dea7535d260e106e1b91fa5dd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2b6866210153496dd4fc9426b14b64875e12ca827d552dbc99290aaa1a11a1480ab82313704992dcfa27299cc0b8fec934acc71bea734655a347f99881308a49
|
7
|
+
data.tar.gz: 156ad05851da940c8a3fd122456c99ccc5ecaf611062361e5eb372b632733a1c7aff4641db6011b151ed324070f484369a4d3e616dba9455f502c1601aa021aa
|
data/lib/mailslurp_client.rb
CHANGED
@@ -33,6 +33,7 @@ require 'mailslurp_client/models/create_contact_options'
|
|
33
33
|
require 'mailslurp_client/models/create_domain_options'
|
34
34
|
require 'mailslurp_client/models/create_group_options'
|
35
35
|
require 'mailslurp_client/models/create_inbox_dto'
|
36
|
+
require 'mailslurp_client/models/create_inbox_forwarder_options'
|
36
37
|
require 'mailslurp_client/models/create_inbox_ruleset_options'
|
37
38
|
require 'mailslurp_client/models/create_template_options'
|
38
39
|
require 'mailslurp_client/models/create_tracking_pixel_options'
|
@@ -65,6 +66,9 @@ require 'mailslurp_client/models/group_projection'
|
|
65
66
|
require 'mailslurp_client/models/html_validation_result'
|
66
67
|
require 'mailslurp_client/models/ip_address_result'
|
67
68
|
require 'mailslurp_client/models/inbox'
|
69
|
+
require 'mailslurp_client/models/inbox_forwarder_dto'
|
70
|
+
require 'mailslurp_client/models/inbox_forwarder_test_options'
|
71
|
+
require 'mailslurp_client/models/inbox_forwarder_test_result'
|
68
72
|
require 'mailslurp_client/models/inbox_projection'
|
69
73
|
require 'mailslurp_client/models/inbox_ruleset_dto'
|
70
74
|
require 'mailslurp_client/models/inbox_ruleset_test_options'
|
@@ -83,6 +87,7 @@ require 'mailslurp_client/models/page_email_preview'
|
|
83
87
|
require 'mailslurp_client/models/page_email_projection'
|
84
88
|
require 'mailslurp_client/models/page_expired_inbox_record_projection'
|
85
89
|
require 'mailslurp_client/models/page_group_projection'
|
90
|
+
require 'mailslurp_client/models/page_inbox_forwarder_dto'
|
86
91
|
require 'mailslurp_client/models/page_inbox_projection'
|
87
92
|
require 'mailslurp_client/models/page_inbox_ruleset_dto'
|
88
93
|
require 'mailslurp_client/models/page_missed_email_projection'
|
@@ -106,6 +111,7 @@ require 'mailslurp_client/models/sort'
|
|
106
111
|
require 'mailslurp_client/models/template_dto'
|
107
112
|
require 'mailslurp_client/models/template_projection'
|
108
113
|
require 'mailslurp_client/models/template_variable'
|
114
|
+
require 'mailslurp_client/models/test_new_inbox_forwarder_options'
|
109
115
|
require 'mailslurp_client/models/test_new_inbox_ruleset_options'
|
110
116
|
require 'mailslurp_client/models/thread_projection'
|
111
117
|
require 'mailslurp_client/models/tracking_pixel_dto'
|
@@ -144,6 +150,7 @@ require 'mailslurp_client/api/export_controller_api'
|
|
144
150
|
require 'mailslurp_client/api/form_controller_api'
|
145
151
|
require 'mailslurp_client/api/group_controller_api'
|
146
152
|
require 'mailslurp_client/api/inbox_controller_api'
|
153
|
+
require 'mailslurp_client/api/inbox_forwarder_controller_api'
|
147
154
|
require 'mailslurp_client/api/inbox_ruleset_controller_api'
|
148
155
|
require 'mailslurp_client/api/mail_server_controller_api'
|
149
156
|
require 'mailslurp_client/api/missed_email_controller_api'
|
@@ -401,10 +401,10 @@ module MailSlurpClient
|
|
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
|
404
|
-
# @return [
|
404
|
+
# @return [SentEmailDto]
|
405
405
|
def forward_email(email_id, forward_email_options, opts = {})
|
406
|
-
forward_email_with_http_info(email_id, forward_email_options, opts)
|
407
|
-
|
406
|
+
data, _status_code, _headers = forward_email_with_http_info(email_id, forward_email_options, opts)
|
407
|
+
data
|
408
408
|
end
|
409
409
|
|
410
410
|
# Forward email to recipients
|
@@ -412,7 +412,7 @@ module MailSlurpClient
|
|
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
|
415
|
-
# @return [Array<(
|
415
|
+
# @return [Array<(SentEmailDto, Integer, Hash)>] SentEmailDto data, response status code and response headers
|
416
416
|
def forward_email_with_http_info(email_id, forward_email_options, opts = {})
|
417
417
|
if @api_client.config.debugging
|
418
418
|
@api_client.config.logger.debug 'Calling API: EmailControllerApi.forward_email ...'
|
@@ -433,6 +433,8 @@ module MailSlurpClient
|
|
433
433
|
|
434
434
|
# header parameters
|
435
435
|
header_params = opts[:header_params] || {}
|
436
|
+
# HTTP header 'Accept' (if needed)
|
437
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
436
438
|
# HTTP header 'Content-Type'
|
437
439
|
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
438
440
|
|
@@ -443,7 +445,7 @@ module MailSlurpClient
|
|
443
445
|
post_body = opts[:body] || @api_client.object_to_http_body(forward_email_options)
|
444
446
|
|
445
447
|
# return_type
|
446
|
-
return_type = opts[:return_type]
|
448
|
+
return_type = opts[:return_type] || 'SentEmailDto'
|
447
449
|
|
448
450
|
# auth_names
|
449
451
|
auth_names = opts[:auth_names] || ['API_KEY']
|
@@ -0,0 +1,548 @@
|
|
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
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.1
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'cgi'
|
14
|
+
|
15
|
+
module MailSlurpClient
|
16
|
+
class InboxForwarderControllerApi
|
17
|
+
attr_accessor :api_client
|
18
|
+
|
19
|
+
def initialize(api_client = ApiClient.default)
|
20
|
+
@api_client = api_client
|
21
|
+
end
|
22
|
+
# Create an inbox forwarder
|
23
|
+
# Create a new inbox rule for forwarding, blocking, and allowing emails when sending and receiving
|
24
|
+
# @param create_inbox_forwarder_options [CreateInboxForwarderOptions] createInboxForwarderOptions
|
25
|
+
# @param [Hash] opts the optional parameters
|
26
|
+
# @option opts [String] :inbox_id Inbox id to attach forwarder to
|
27
|
+
# @return [InboxForwarderDto]
|
28
|
+
def create_new_inbox_forwarder(create_inbox_forwarder_options, opts = {})
|
29
|
+
data, _status_code, _headers = create_new_inbox_forwarder_with_http_info(create_inbox_forwarder_options, opts)
|
30
|
+
data
|
31
|
+
end
|
32
|
+
|
33
|
+
# Create an inbox forwarder
|
34
|
+
# Create a new inbox rule for forwarding, blocking, and allowing emails when sending and receiving
|
35
|
+
# @param create_inbox_forwarder_options [CreateInboxForwarderOptions] createInboxForwarderOptions
|
36
|
+
# @param [Hash] opts the optional parameters
|
37
|
+
# @option opts [String] :inbox_id Inbox id to attach forwarder to
|
38
|
+
# @return [Array<(InboxForwarderDto, Integer, Hash)>] InboxForwarderDto data, response status code and response headers
|
39
|
+
def create_new_inbox_forwarder_with_http_info(create_inbox_forwarder_options, opts = {})
|
40
|
+
if @api_client.config.debugging
|
41
|
+
@api_client.config.logger.debug 'Calling API: InboxForwarderControllerApi.create_new_inbox_forwarder ...'
|
42
|
+
end
|
43
|
+
# verify the required parameter 'create_inbox_forwarder_options' is set
|
44
|
+
if @api_client.config.client_side_validation && create_inbox_forwarder_options.nil?
|
45
|
+
fail ArgumentError, "Missing the required parameter 'create_inbox_forwarder_options' when calling InboxForwarderControllerApi.create_new_inbox_forwarder"
|
46
|
+
end
|
47
|
+
# resource path
|
48
|
+
local_var_path = '/forwarders'
|
49
|
+
|
50
|
+
# query parameters
|
51
|
+
query_params = opts[:query_params] || {}
|
52
|
+
query_params[:'inboxId'] = opts[:'inbox_id'] if !opts[:'inbox_id'].nil?
|
53
|
+
|
54
|
+
# header parameters
|
55
|
+
header_params = opts[:header_params] || {}
|
56
|
+
# HTTP header 'Accept' (if needed)
|
57
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
58
|
+
# HTTP header 'Content-Type'
|
59
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
60
|
+
|
61
|
+
# form parameters
|
62
|
+
form_params = opts[:form_params] || {}
|
63
|
+
|
64
|
+
# http body (model)
|
65
|
+
post_body = opts[:body] || @api_client.object_to_http_body(create_inbox_forwarder_options)
|
66
|
+
|
67
|
+
# return_type
|
68
|
+
return_type = opts[:return_type] || 'InboxForwarderDto'
|
69
|
+
|
70
|
+
# auth_names
|
71
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
72
|
+
|
73
|
+
new_options = opts.merge(
|
74
|
+
:header_params => header_params,
|
75
|
+
:query_params => query_params,
|
76
|
+
:form_params => form_params,
|
77
|
+
:body => post_body,
|
78
|
+
:auth_names => auth_names,
|
79
|
+
:return_type => return_type
|
80
|
+
)
|
81
|
+
|
82
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
83
|
+
if @api_client.config.debugging
|
84
|
+
@api_client.config.logger.debug "API called: InboxForwarderControllerApi#create_new_inbox_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
85
|
+
end
|
86
|
+
return data, status_code, headers
|
87
|
+
end
|
88
|
+
|
89
|
+
# Delete an inbox forwarder
|
90
|
+
# Delete inbox forwarder
|
91
|
+
# @param id [String] ID of inbox forwarder
|
92
|
+
# @param [Hash] opts the optional parameters
|
93
|
+
# @return [nil]
|
94
|
+
def delete_inbox_forwarder(id, opts = {})
|
95
|
+
delete_inbox_forwarder_with_http_info(id, opts)
|
96
|
+
nil
|
97
|
+
end
|
98
|
+
|
99
|
+
# Delete an inbox forwarder
|
100
|
+
# Delete inbox forwarder
|
101
|
+
# @param id [String] ID of inbox forwarder
|
102
|
+
# @param [Hash] opts the optional parameters
|
103
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
104
|
+
def delete_inbox_forwarder_with_http_info(id, opts = {})
|
105
|
+
if @api_client.config.debugging
|
106
|
+
@api_client.config.logger.debug 'Calling API: InboxForwarderControllerApi.delete_inbox_forwarder ...'
|
107
|
+
end
|
108
|
+
# verify the required parameter 'id' is set
|
109
|
+
if @api_client.config.client_side_validation && id.nil?
|
110
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling InboxForwarderControllerApi.delete_inbox_forwarder"
|
111
|
+
end
|
112
|
+
# resource path
|
113
|
+
local_var_path = '/forwarders/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
114
|
+
|
115
|
+
# query parameters
|
116
|
+
query_params = opts[:query_params] || {}
|
117
|
+
|
118
|
+
# header parameters
|
119
|
+
header_params = opts[:header_params] || {}
|
120
|
+
|
121
|
+
# form parameters
|
122
|
+
form_params = opts[:form_params] || {}
|
123
|
+
|
124
|
+
# http body (model)
|
125
|
+
post_body = opts[:body]
|
126
|
+
|
127
|
+
# return_type
|
128
|
+
return_type = opts[:return_type]
|
129
|
+
|
130
|
+
# auth_names
|
131
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
132
|
+
|
133
|
+
new_options = opts.merge(
|
134
|
+
:header_params => header_params,
|
135
|
+
:query_params => query_params,
|
136
|
+
:form_params => form_params,
|
137
|
+
:body => post_body,
|
138
|
+
:auth_names => auth_names,
|
139
|
+
:return_type => return_type
|
140
|
+
)
|
141
|
+
|
142
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
143
|
+
if @api_client.config.debugging
|
144
|
+
@api_client.config.logger.debug "API called: InboxForwarderControllerApi#delete_inbox_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
145
|
+
end
|
146
|
+
return data, status_code, headers
|
147
|
+
end
|
148
|
+
|
149
|
+
# Delete inbox forwarders
|
150
|
+
# Delete inbox forwarders. Accepts optional inboxId filter.
|
151
|
+
# @param [Hash] opts the optional parameters
|
152
|
+
# @option opts [String] :inbox_id Optional inbox id to attach forwarder to
|
153
|
+
# @return [nil]
|
154
|
+
def delete_inbox_forwarders(opts = {})
|
155
|
+
delete_inbox_forwarders_with_http_info(opts)
|
156
|
+
nil
|
157
|
+
end
|
158
|
+
|
159
|
+
# Delete inbox forwarders
|
160
|
+
# Delete inbox forwarders. Accepts optional inboxId filter.
|
161
|
+
# @param [Hash] opts the optional parameters
|
162
|
+
# @option opts [String] :inbox_id Optional inbox id to attach forwarder to
|
163
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
164
|
+
def delete_inbox_forwarders_with_http_info(opts = {})
|
165
|
+
if @api_client.config.debugging
|
166
|
+
@api_client.config.logger.debug 'Calling API: InboxForwarderControllerApi.delete_inbox_forwarders ...'
|
167
|
+
end
|
168
|
+
# resource path
|
169
|
+
local_var_path = '/forwarders'
|
170
|
+
|
171
|
+
# query parameters
|
172
|
+
query_params = opts[:query_params] || {}
|
173
|
+
query_params[:'inboxId'] = opts[:'inbox_id'] if !opts[:'inbox_id'].nil?
|
174
|
+
|
175
|
+
# header parameters
|
176
|
+
header_params = opts[:header_params] || {}
|
177
|
+
|
178
|
+
# form parameters
|
179
|
+
form_params = opts[:form_params] || {}
|
180
|
+
|
181
|
+
# http body (model)
|
182
|
+
post_body = opts[:body]
|
183
|
+
|
184
|
+
# return_type
|
185
|
+
return_type = opts[:return_type]
|
186
|
+
|
187
|
+
# auth_names
|
188
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
189
|
+
|
190
|
+
new_options = opts.merge(
|
191
|
+
:header_params => header_params,
|
192
|
+
:query_params => query_params,
|
193
|
+
:form_params => form_params,
|
194
|
+
:body => post_body,
|
195
|
+
:auth_names => auth_names,
|
196
|
+
:return_type => return_type
|
197
|
+
)
|
198
|
+
|
199
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
200
|
+
if @api_client.config.debugging
|
201
|
+
@api_client.config.logger.debug "API called: InboxForwarderControllerApi#delete_inbox_forwarders\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
202
|
+
end
|
203
|
+
return data, status_code, headers
|
204
|
+
end
|
205
|
+
|
206
|
+
# Get an inbox forwarder
|
207
|
+
# Get inbox ruleset
|
208
|
+
# @param id [String] ID of inbox forwarder
|
209
|
+
# @param [Hash] opts the optional parameters
|
210
|
+
# @return [InboxForwarderDto]
|
211
|
+
def get_inbox_forwarder(id, opts = {})
|
212
|
+
data, _status_code, _headers = get_inbox_forwarder_with_http_info(id, opts)
|
213
|
+
data
|
214
|
+
end
|
215
|
+
|
216
|
+
# Get an inbox forwarder
|
217
|
+
# Get inbox ruleset
|
218
|
+
# @param id [String] ID of inbox forwarder
|
219
|
+
# @param [Hash] opts the optional parameters
|
220
|
+
# @return [Array<(InboxForwarderDto, Integer, Hash)>] InboxForwarderDto data, response status code and response headers
|
221
|
+
def get_inbox_forwarder_with_http_info(id, opts = {})
|
222
|
+
if @api_client.config.debugging
|
223
|
+
@api_client.config.logger.debug 'Calling API: InboxForwarderControllerApi.get_inbox_forwarder ...'
|
224
|
+
end
|
225
|
+
# verify the required parameter 'id' is set
|
226
|
+
if @api_client.config.client_side_validation && id.nil?
|
227
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling InboxForwarderControllerApi.get_inbox_forwarder"
|
228
|
+
end
|
229
|
+
# resource path
|
230
|
+
local_var_path = '/forwarders/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
231
|
+
|
232
|
+
# query parameters
|
233
|
+
query_params = opts[:query_params] || {}
|
234
|
+
|
235
|
+
# header parameters
|
236
|
+
header_params = opts[:header_params] || {}
|
237
|
+
# HTTP header 'Accept' (if needed)
|
238
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
239
|
+
|
240
|
+
# form parameters
|
241
|
+
form_params = opts[:form_params] || {}
|
242
|
+
|
243
|
+
# http body (model)
|
244
|
+
post_body = opts[:body]
|
245
|
+
|
246
|
+
# return_type
|
247
|
+
return_type = opts[:return_type] || 'InboxForwarderDto'
|
248
|
+
|
249
|
+
# auth_names
|
250
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
251
|
+
|
252
|
+
new_options = opts.merge(
|
253
|
+
:header_params => header_params,
|
254
|
+
:query_params => query_params,
|
255
|
+
:form_params => form_params,
|
256
|
+
:body => post_body,
|
257
|
+
:auth_names => auth_names,
|
258
|
+
:return_type => return_type
|
259
|
+
)
|
260
|
+
|
261
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
262
|
+
if @api_client.config.debugging
|
263
|
+
@api_client.config.logger.debug "API called: InboxForwarderControllerApi#get_inbox_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
264
|
+
end
|
265
|
+
return data, status_code, headers
|
266
|
+
end
|
267
|
+
|
268
|
+
# List inbox forwarders
|
269
|
+
# List all forwarders attached to an inbox
|
270
|
+
# @param [Hash] opts the optional parameters
|
271
|
+
# @option opts [String] :inbox_id Optional inbox id to get forwarders from
|
272
|
+
# @option opts [Integer] :page Optional page index in inbox forwarder list pagination (default to 0)
|
273
|
+
# @option opts [String] :search_filter Optional search filter
|
274
|
+
# @option opts [Integer] :size Optional page size in inbox forwarder list pagination (default to 20)
|
275
|
+
# @option opts [String] :sort Optional createdAt sort direction ASC or DESC (default to 'ASC')
|
276
|
+
# @return [PageInboxForwarderDto]
|
277
|
+
def get_inbox_forwarders(opts = {})
|
278
|
+
data, _status_code, _headers = get_inbox_forwarders_with_http_info(opts)
|
279
|
+
data
|
280
|
+
end
|
281
|
+
|
282
|
+
# List inbox forwarders
|
283
|
+
# List all forwarders attached to an inbox
|
284
|
+
# @param [Hash] opts the optional parameters
|
285
|
+
# @option opts [String] :inbox_id Optional inbox id to get forwarders from
|
286
|
+
# @option opts [Integer] :page Optional page index in inbox forwarder list pagination
|
287
|
+
# @option opts [String] :search_filter Optional search filter
|
288
|
+
# @option opts [Integer] :size Optional page size in inbox forwarder list pagination
|
289
|
+
# @option opts [String] :sort Optional createdAt sort direction ASC or DESC
|
290
|
+
# @return [Array<(PageInboxForwarderDto, Integer, Hash)>] PageInboxForwarderDto data, response status code and response headers
|
291
|
+
def get_inbox_forwarders_with_http_info(opts = {})
|
292
|
+
if @api_client.config.debugging
|
293
|
+
@api_client.config.logger.debug 'Calling API: InboxForwarderControllerApi.get_inbox_forwarders ...'
|
294
|
+
end
|
295
|
+
allowable_values = ["ASC", "DESC"]
|
296
|
+
if @api_client.config.client_side_validation && opts[:'sort'] && !allowable_values.include?(opts[:'sort'])
|
297
|
+
fail ArgumentError, "invalid value for \"sort\", must be one of #{allowable_values}"
|
298
|
+
end
|
299
|
+
# resource path
|
300
|
+
local_var_path = '/forwarders'
|
301
|
+
|
302
|
+
# query parameters
|
303
|
+
query_params = opts[:query_params] || {}
|
304
|
+
query_params[:'inboxId'] = opts[:'inbox_id'] if !opts[:'inbox_id'].nil?
|
305
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
306
|
+
query_params[:'searchFilter'] = opts[:'search_filter'] if !opts[:'search_filter'].nil?
|
307
|
+
query_params[:'size'] = opts[:'size'] if !opts[:'size'].nil?
|
308
|
+
query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
|
309
|
+
|
310
|
+
# header parameters
|
311
|
+
header_params = opts[:header_params] || {}
|
312
|
+
# HTTP header 'Accept' (if needed)
|
313
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
314
|
+
|
315
|
+
# form parameters
|
316
|
+
form_params = opts[:form_params] || {}
|
317
|
+
|
318
|
+
# http body (model)
|
319
|
+
post_body = opts[:body]
|
320
|
+
|
321
|
+
# return_type
|
322
|
+
return_type = opts[:return_type] || 'PageInboxForwarderDto'
|
323
|
+
|
324
|
+
# auth_names
|
325
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
326
|
+
|
327
|
+
new_options = opts.merge(
|
328
|
+
:header_params => header_params,
|
329
|
+
:query_params => query_params,
|
330
|
+
:form_params => form_params,
|
331
|
+
:body => post_body,
|
332
|
+
:auth_names => auth_names,
|
333
|
+
:return_type => return_type
|
334
|
+
)
|
335
|
+
|
336
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
337
|
+
if @api_client.config.debugging
|
338
|
+
@api_client.config.logger.debug "API called: InboxForwarderControllerApi#get_inbox_forwarders\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
339
|
+
end
|
340
|
+
return data, status_code, headers
|
341
|
+
end
|
342
|
+
|
343
|
+
# Test an inbox forwarder
|
344
|
+
# Test an inbox forwarder
|
345
|
+
# @param id [String] ID of inbox forwarder
|
346
|
+
# @param inbox_forwarder_test_options [InboxForwarderTestOptions] inboxForwarderTestOptions
|
347
|
+
# @param [Hash] opts the optional parameters
|
348
|
+
# @return [InboxForwarderTestResult]
|
349
|
+
def test_inbox_forwarder(id, inbox_forwarder_test_options, opts = {})
|
350
|
+
data, _status_code, _headers = test_inbox_forwarder_with_http_info(id, inbox_forwarder_test_options, opts)
|
351
|
+
data
|
352
|
+
end
|
353
|
+
|
354
|
+
# Test an inbox forwarder
|
355
|
+
# Test an inbox forwarder
|
356
|
+
# @param id [String] ID of inbox forwarder
|
357
|
+
# @param inbox_forwarder_test_options [InboxForwarderTestOptions] inboxForwarderTestOptions
|
358
|
+
# @param [Hash] opts the optional parameters
|
359
|
+
# @return [Array<(InboxForwarderTestResult, Integer, Hash)>] InboxForwarderTestResult data, response status code and response headers
|
360
|
+
def test_inbox_forwarder_with_http_info(id, inbox_forwarder_test_options, opts = {})
|
361
|
+
if @api_client.config.debugging
|
362
|
+
@api_client.config.logger.debug 'Calling API: InboxForwarderControllerApi.test_inbox_forwarder ...'
|
363
|
+
end
|
364
|
+
# verify the required parameter 'id' is set
|
365
|
+
if @api_client.config.client_side_validation && id.nil?
|
366
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling InboxForwarderControllerApi.test_inbox_forwarder"
|
367
|
+
end
|
368
|
+
# verify the required parameter 'inbox_forwarder_test_options' is set
|
369
|
+
if @api_client.config.client_side_validation && inbox_forwarder_test_options.nil?
|
370
|
+
fail ArgumentError, "Missing the required parameter 'inbox_forwarder_test_options' when calling InboxForwarderControllerApi.test_inbox_forwarder"
|
371
|
+
end
|
372
|
+
# resource path
|
373
|
+
local_var_path = '/forwarders/{id}/test'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
374
|
+
|
375
|
+
# query parameters
|
376
|
+
query_params = opts[:query_params] || {}
|
377
|
+
|
378
|
+
# header parameters
|
379
|
+
header_params = opts[:header_params] || {}
|
380
|
+
# HTTP header 'Accept' (if needed)
|
381
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
382
|
+
# HTTP header 'Content-Type'
|
383
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
384
|
+
|
385
|
+
# form parameters
|
386
|
+
form_params = opts[:form_params] || {}
|
387
|
+
|
388
|
+
# http body (model)
|
389
|
+
post_body = opts[:body] || @api_client.object_to_http_body(inbox_forwarder_test_options)
|
390
|
+
|
391
|
+
# return_type
|
392
|
+
return_type = opts[:return_type] || 'InboxForwarderTestResult'
|
393
|
+
|
394
|
+
# auth_names
|
395
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
396
|
+
|
397
|
+
new_options = opts.merge(
|
398
|
+
:header_params => header_params,
|
399
|
+
:query_params => query_params,
|
400
|
+
:form_params => form_params,
|
401
|
+
:body => post_body,
|
402
|
+
:auth_names => auth_names,
|
403
|
+
:return_type => return_type
|
404
|
+
)
|
405
|
+
|
406
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
407
|
+
if @api_client.config.debugging
|
408
|
+
@api_client.config.logger.debug "API called: InboxForwarderControllerApi#test_inbox_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
409
|
+
end
|
410
|
+
return data, status_code, headers
|
411
|
+
end
|
412
|
+
|
413
|
+
# Test inbox forwarders for inbox
|
414
|
+
# Test inbox forwarders for inbox
|
415
|
+
# @param inbox_id [String] ID of inbox
|
416
|
+
# @param inbox_forwarder_test_options [InboxForwarderTestOptions] inboxForwarderTestOptions
|
417
|
+
# @param [Hash] opts the optional parameters
|
418
|
+
# @return [InboxForwarderTestResult]
|
419
|
+
def test_inbox_forwarders_for_inbox(inbox_id, inbox_forwarder_test_options, opts = {})
|
420
|
+
data, _status_code, _headers = test_inbox_forwarders_for_inbox_with_http_info(inbox_id, inbox_forwarder_test_options, opts)
|
421
|
+
data
|
422
|
+
end
|
423
|
+
|
424
|
+
# Test inbox forwarders for inbox
|
425
|
+
# Test inbox forwarders for inbox
|
426
|
+
# @param inbox_id [String] ID of inbox
|
427
|
+
# @param inbox_forwarder_test_options [InboxForwarderTestOptions] inboxForwarderTestOptions
|
428
|
+
# @param [Hash] opts the optional parameters
|
429
|
+
# @return [Array<(InboxForwarderTestResult, Integer, Hash)>] InboxForwarderTestResult data, response status code and response headers
|
430
|
+
def test_inbox_forwarders_for_inbox_with_http_info(inbox_id, inbox_forwarder_test_options, opts = {})
|
431
|
+
if @api_client.config.debugging
|
432
|
+
@api_client.config.logger.debug 'Calling API: InboxForwarderControllerApi.test_inbox_forwarders_for_inbox ...'
|
433
|
+
end
|
434
|
+
# verify the required parameter 'inbox_id' is set
|
435
|
+
if @api_client.config.client_side_validation && inbox_id.nil?
|
436
|
+
fail ArgumentError, "Missing the required parameter 'inbox_id' when calling InboxForwarderControllerApi.test_inbox_forwarders_for_inbox"
|
437
|
+
end
|
438
|
+
# verify the required parameter 'inbox_forwarder_test_options' is set
|
439
|
+
if @api_client.config.client_side_validation && inbox_forwarder_test_options.nil?
|
440
|
+
fail ArgumentError, "Missing the required parameter 'inbox_forwarder_test_options' when calling InboxForwarderControllerApi.test_inbox_forwarders_for_inbox"
|
441
|
+
end
|
442
|
+
# resource path
|
443
|
+
local_var_path = '/forwarders'
|
444
|
+
|
445
|
+
# query parameters
|
446
|
+
query_params = opts[:query_params] || {}
|
447
|
+
query_params[:'inboxId'] = inbox_id
|
448
|
+
|
449
|
+
# header parameters
|
450
|
+
header_params = opts[:header_params] || {}
|
451
|
+
# HTTP header 'Accept' (if needed)
|
452
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
453
|
+
# HTTP header 'Content-Type'
|
454
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
455
|
+
|
456
|
+
# form parameters
|
457
|
+
form_params = opts[:form_params] || {}
|
458
|
+
|
459
|
+
# http body (model)
|
460
|
+
post_body = opts[:body] || @api_client.object_to_http_body(inbox_forwarder_test_options)
|
461
|
+
|
462
|
+
# return_type
|
463
|
+
return_type = opts[:return_type] || 'InboxForwarderTestResult'
|
464
|
+
|
465
|
+
# auth_names
|
466
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
467
|
+
|
468
|
+
new_options = opts.merge(
|
469
|
+
:header_params => header_params,
|
470
|
+
:query_params => query_params,
|
471
|
+
:form_params => form_params,
|
472
|
+
:body => post_body,
|
473
|
+
:auth_names => auth_names,
|
474
|
+
:return_type => return_type
|
475
|
+
)
|
476
|
+
|
477
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
478
|
+
if @api_client.config.debugging
|
479
|
+
@api_client.config.logger.debug "API called: InboxForwarderControllerApi#test_inbox_forwarders_for_inbox\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
480
|
+
end
|
481
|
+
return data, status_code, headers
|
482
|
+
end
|
483
|
+
|
484
|
+
# Test new inbox forwarder
|
485
|
+
# Test new inbox forwarder
|
486
|
+
# @param test_new_inbox_forwarder_options [TestNewInboxForwarderOptions] testNewInboxForwarderOptions
|
487
|
+
# @param [Hash] opts the optional parameters
|
488
|
+
# @return [InboxForwarderTestResult]
|
489
|
+
def test_new_inbox_forwarder(test_new_inbox_forwarder_options, opts = {})
|
490
|
+
data, _status_code, _headers = test_new_inbox_forwarder_with_http_info(test_new_inbox_forwarder_options, opts)
|
491
|
+
data
|
492
|
+
end
|
493
|
+
|
494
|
+
# Test new inbox forwarder
|
495
|
+
# Test new inbox forwarder
|
496
|
+
# @param test_new_inbox_forwarder_options [TestNewInboxForwarderOptions] testNewInboxForwarderOptions
|
497
|
+
# @param [Hash] opts the optional parameters
|
498
|
+
# @return [Array<(InboxForwarderTestResult, Integer, Hash)>] InboxForwarderTestResult data, response status code and response headers
|
499
|
+
def test_new_inbox_forwarder_with_http_info(test_new_inbox_forwarder_options, opts = {})
|
500
|
+
if @api_client.config.debugging
|
501
|
+
@api_client.config.logger.debug 'Calling API: InboxForwarderControllerApi.test_new_inbox_forwarder ...'
|
502
|
+
end
|
503
|
+
# verify the required parameter 'test_new_inbox_forwarder_options' is set
|
504
|
+
if @api_client.config.client_side_validation && test_new_inbox_forwarder_options.nil?
|
505
|
+
fail ArgumentError, "Missing the required parameter 'test_new_inbox_forwarder_options' when calling InboxForwarderControllerApi.test_new_inbox_forwarder"
|
506
|
+
end
|
507
|
+
# resource path
|
508
|
+
local_var_path = '/forwarders'
|
509
|
+
|
510
|
+
# query parameters
|
511
|
+
query_params = opts[:query_params] || {}
|
512
|
+
|
513
|
+
# header parameters
|
514
|
+
header_params = opts[:header_params] || {}
|
515
|
+
# HTTP header 'Accept' (if needed)
|
516
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
517
|
+
# HTTP header 'Content-Type'
|
518
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
519
|
+
|
520
|
+
# form parameters
|
521
|
+
form_params = opts[:form_params] || {}
|
522
|
+
|
523
|
+
# http body (model)
|
524
|
+
post_body = opts[:body] || @api_client.object_to_http_body(test_new_inbox_forwarder_options)
|
525
|
+
|
526
|
+
# return_type
|
527
|
+
return_type = opts[:return_type] || 'InboxForwarderTestResult'
|
528
|
+
|
529
|
+
# auth_names
|
530
|
+
auth_names = opts[:auth_names] || ['API_KEY']
|
531
|
+
|
532
|
+
new_options = opts.merge(
|
533
|
+
:header_params => header_params,
|
534
|
+
:query_params => query_params,
|
535
|
+
:form_params => form_params,
|
536
|
+
:body => post_body,
|
537
|
+
:auth_names => auth_names,
|
538
|
+
:return_type => return_type
|
539
|
+
)
|
540
|
+
|
541
|
+
data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
|
542
|
+
if @api_client.config.debugging
|
543
|
+
@api_client.config.logger.debug "API called: InboxForwarderControllerApi#test_new_inbox_forwarder\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
544
|
+
end
|
545
|
+
return data, status_code, headers
|
546
|
+
end
|
547
|
+
end
|
548
|
+
end
|