mailslurp_client 15.11.0 → 15.11.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (70) hide show
  1. checksums.yaml +4 -4
  2. data/lib/mailslurp_client/api/attachment_controller_api.rb +4 -4
  3. data/lib/mailslurp_client/api/email_controller_api.rb +68 -3
  4. data/lib/mailslurp_client/api/missed_email_controller_api.rb +56 -0
  5. data/lib/mailslurp_client/api/phone_controller_api.rb +487 -0
  6. data/lib/mailslurp_client/api/sent_emails_controller_api.rb +73 -0
  7. data/lib/mailslurp_client/api/sms_controller_api.rb +286 -0
  8. data/lib/mailslurp_client/api/wait_for_controller_api.rb +64 -0
  9. data/lib/mailslurp_client/api/webhook_controller_api.rb +2 -2
  10. data/lib/mailslurp_client/models/abstract_webhook_payload.rb +2 -2
  11. data/lib/mailslurp_client/models/alias_projection.rb +27 -27
  12. data/lib/mailslurp_client/models/attachment_projection.rb +14 -14
  13. data/lib/mailslurp_client/models/contact_projection.rb +18 -18
  14. data/lib/mailslurp_client/models/create_emergency_address_options.rb +324 -0
  15. data/lib/mailslurp_client/models/create_webhook_options.rb +2 -2
  16. data/lib/mailslurp_client/models/email_html_dto.rb +215 -0
  17. data/lib/mailslurp_client/models/email_projection.rb +10 -10
  18. data/lib/mailslurp_client/models/emergency_address.rb +408 -0
  19. data/lib/mailslurp_client/models/emergency_address_dto.rb +273 -0
  20. data/lib/mailslurp_client/models/empty_response_dto.rb +206 -0
  21. data/lib/mailslurp_client/models/page_alias.rb +19 -19
  22. data/lib/mailslurp_client/models/page_attachment_entity.rb +19 -19
  23. data/lib/mailslurp_client/models/page_bounced_email.rb +19 -19
  24. data/lib/mailslurp_client/models/page_bounced_recipients.rb +19 -19
  25. data/lib/mailslurp_client/models/page_contact_projection.rb +19 -19
  26. data/lib/mailslurp_client/models/page_email_preview.rb +19 -19
  27. data/lib/mailslurp_client/models/page_email_projection.rb +19 -19
  28. data/lib/mailslurp_client/models/page_email_validation_request.rb +19 -19
  29. data/lib/mailslurp_client/models/page_expired_inbox_record_projection.rb +19 -19
  30. data/lib/mailslurp_client/models/page_group_projection.rb +19 -19
  31. data/lib/mailslurp_client/models/page_inbox_forwarder_dto.rb +19 -19
  32. data/lib/mailslurp_client/models/page_inbox_projection.rb +19 -19
  33. data/lib/mailslurp_client/models/page_inbox_ruleset_dto.rb +19 -19
  34. data/lib/mailslurp_client/models/page_missed_email_projection.rb +19 -19
  35. data/lib/mailslurp_client/models/page_organization_inbox_projection.rb +19 -19
  36. data/lib/mailslurp_client/models/page_phone_number_projection.rb +308 -0
  37. data/lib/mailslurp_client/models/page_sent_email_with_queue_projection.rb +344 -0
  38. data/lib/mailslurp_client/models/page_sms_projection.rb +308 -0
  39. data/lib/mailslurp_client/models/page_template_projection.rb +19 -19
  40. data/lib/mailslurp_client/models/page_thread_projection.rb +19 -19
  41. data/lib/mailslurp_client/models/page_tracking_pixel_projection.rb +19 -19
  42. data/lib/mailslurp_client/models/page_unknown_missed_email_projection.rb +19 -19
  43. data/lib/mailslurp_client/models/page_webhook_projection.rb +19 -19
  44. data/lib/mailslurp_client/models/page_webhook_result.rb +19 -19
  45. data/lib/mailslurp_client/models/phone_number_dto.rb +347 -0
  46. data/lib/mailslurp_client/models/phone_number_projection.rb +302 -0
  47. data/lib/mailslurp_client/models/phone_plan_dto.rb +287 -0
  48. data/lib/mailslurp_client/models/send_with_queue_result.rb +318 -0
  49. data/lib/mailslurp_client/models/sent_email_projection.rb +15 -15
  50. data/lib/mailslurp_client/models/sms_match_option.rb +289 -0
  51. data/lib/mailslurp_client/models/sms_message.rb +318 -0
  52. data/lib/mailslurp_client/models/sms_preview.rb +267 -0
  53. data/lib/mailslurp_client/models/sms_projection.rb +282 -0
  54. data/lib/mailslurp_client/models/template_projection.rb +18 -18
  55. data/lib/mailslurp_client/models/thread_projection.rb +36 -36
  56. data/lib/mailslurp_client/models/tracking_pixel_projection.rb +10 -10
  57. data/lib/mailslurp_client/models/wait_for_sms_conditions.rb +371 -0
  58. data/lib/mailslurp_client/models/webhook_bounce_payload.rb +2 -2
  59. data/lib/mailslurp_client/models/webhook_bounce_recipient_payload.rb +2 -2
  60. data/lib/mailslurp_client/models/webhook_dto.rb +2 -2
  61. data/lib/mailslurp_client/models/webhook_email_opened_payload.rb +2 -2
  62. data/lib/mailslurp_client/models/webhook_email_read_payload.rb +2 -2
  63. data/lib/mailslurp_client/models/webhook_new_attachment_payload.rb +2 -2
  64. data/lib/mailslurp_client/models/webhook_new_contact_payload.rb +2 -2
  65. data/lib/mailslurp_client/models/webhook_new_email_payload.rb +2 -2
  66. data/lib/mailslurp_client/models/webhook_projection.rb +2 -2
  67. data/lib/mailslurp_client/models/webhook_result_dto.rb +2 -2
  68. data/lib/mailslurp_client/version.rb +1 -1
  69. data/lib/mailslurp_client.rb +19 -0
  70. metadata +21 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bb28388cd42137297e9d5fa250da26aeacd023947c07c52eb5d026e2e8c54ee7
4
- data.tar.gz: 93a6d324de23969dae38e67a2ac53c07bb510bec2cace2911798c554dcc9e65f
3
+ metadata.gz: 8405ef6045794e6a9cc24dc15eb01813410bf4120aaec0f63b41d59c59097071
4
+ data.tar.gz: b20cef3856ade796cf813a54c318d3c1168bada7543d9eac88c0314e01e1b180
5
5
  SHA512:
6
- metadata.gz: ed93867a50c961ec32e9a347d4f98ac2dc4dc891ecc10a6d228fc4d7ad84ab2b413ce34f39a89d42600609ce3dbfa430f042b97663de28ce800a7cec6481f4d4
7
- data.tar.gz: 369c2cca0f0d3de706eaf13503f8e28356c51d5170ac3722ab62d6a0da5bf2785e6f3299345ef1bde0503b12377e2842260f707afd742ef40e02db694745024a
6
+ metadata.gz: d35ee5a2d41e2b48c77c42a8426dc1eaabb33259dc68cc9d51df09f324a9fa2b9ea3c787cea0804d485599c7b73f47f8d1ee3b30aa5c449412a76d1c60b3293c
7
+ data.tar.gz: c6b0deb8bc5645ee744fe674ccbe18cab4884697dc78a881d7834c7ee1cf7333d3746d4539a4504e3b83bced66f145cbef35b7af1523f164fb04dd579b5c901f
@@ -378,8 +378,8 @@ module MailSlurpClient
378
378
  # Get email attachments
379
379
  # 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.
380
380
  # @param [Hash] opts the optional parameters
381
- # @option opts [Integer] :page Optional page index event list pagination (default to 0)
382
- # @option opts [Integer] :size Optional page size event list pagination (default to 20)
381
+ # @option opts [Integer] :page Optional page index for list pagination (default to 0)
382
+ # @option opts [Integer] :size Optional page size for list pagination (default to 20)
383
383
  # @option opts [String] :sort Optional createdAt sort direction ASC or DESC (default to 'ASC')
384
384
  # @option opts [String] :file_name_filter Optional file name and content type search filter
385
385
  # @option opts [DateTime] :since Filter by created at after the given timestamp
@@ -393,8 +393,8 @@ module MailSlurpClient
393
393
  # Get email attachments
394
394
  # 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.
395
395
  # @param [Hash] opts the optional parameters
396
- # @option opts [Integer] :page Optional page index event list pagination
397
- # @option opts [Integer] :size Optional page size event list pagination
396
+ # @option opts [Integer] :page Optional page index for list pagination
397
+ # @option opts [Integer] :size Optional page size for list pagination
398
398
  # @option opts [String] :sort Optional createdAt sort direction ASC or DESC
399
399
  # @option opts [String] :file_name_filter Optional file name and content type search filter
400
400
  # @option opts [DateTime] :since Filter by created at after the given timestamp
@@ -856,7 +856,7 @@ module MailSlurpClient
856
856
  end
857
857
 
858
858
  # Get email content as HTML. For displaying emails in browser context.
859
- # Retrieve email content as HTML response for viewing in browsers. Decodes quoted-printable entities and converts charset to UTF-8. Pass your API KEY as a request parameter when viewing in a browser: `?apiKey=xxx`
859
+ # Retrieve email content as HTML response for viewing in browsers. Decodes quoted-printable entities and converts charset to UTF-8. Pass your API KEY as a request parameter when viewing in a browser: `?apiKey=xxx`. Returns content-type `text/html;charset=utf-8` so you must call expecting that content response not JSON. For JSON response see the `getEmailHTMLJson` method.
860
860
  # @param email_id [String]
861
861
  # @param [Hash] opts the optional parameters
862
862
  # @option opts [Boolean] :decode (default to false)
@@ -867,7 +867,7 @@ module MailSlurpClient
867
867
  end
868
868
 
869
869
  # Get email content as HTML. For displaying emails in browser context.
870
- # Retrieve email content as HTML response for viewing in browsers. Decodes quoted-printable entities and converts charset to UTF-8. Pass your API KEY as a request parameter when viewing in a browser: `?apiKey=xxx`
870
+ # Retrieve email content as HTML response for viewing in browsers. Decodes quoted-printable entities and converts charset to UTF-8. Pass your API KEY as a request parameter when viewing in a browser: `?apiKey=xxx`. Returns content-type `text/html;charset=utf-8` so you must call expecting that content response not JSON. For JSON response see the `getEmailHTMLJson` method.
871
871
  # @param email_id [String]
872
872
  # @param [Hash] opts the optional parameters
873
873
  # @option opts [Boolean] :decode
@@ -890,7 +890,7 @@ module MailSlurpClient
890
890
  # header parameters
891
891
  header_params = opts[:header_params] || {}
892
892
  # HTTP header 'Accept' (if needed)
893
- header_params['Accept'] = @api_client.select_header_accept(['text/html'])
893
+ header_params['Accept'] = @api_client.select_header_accept(['text/html;charset=utf-8', 'text/html'])
894
894
 
895
895
  # form parameters
896
896
  form_params = opts[:form_params] || {}
@@ -920,6 +920,71 @@ module MailSlurpClient
920
920
  return data, status_code, headers
921
921
  end
922
922
 
923
+ # Get email content as HTML in JSON wrapper. For fetching entity decoded HTML content
924
+ # Retrieve email content as HTML response. Decodes quoted-printable entities and converts charset to UTF-8. Returns content-type `application/json;charset=utf-8` so you must call expecting that content response not JSON.
925
+ # @param email_id [String]
926
+ # @param [Hash] opts the optional parameters
927
+ # @option opts [Boolean] :decode (default to false)
928
+ # @return [EmailHtmlDto]
929
+ def get_email_html_json(email_id, opts = {})
930
+ data, _status_code, _headers = get_email_html_json_with_http_info(email_id, opts)
931
+ data
932
+ end
933
+
934
+ # Get email content as HTML in JSON wrapper. For fetching entity decoded HTML content
935
+ # Retrieve email content as HTML response. Decodes quoted-printable entities and converts charset to UTF-8. Returns content-type `application/json;charset=utf-8` so you must call expecting that content response not JSON.
936
+ # @param email_id [String]
937
+ # @param [Hash] opts the optional parameters
938
+ # @option opts [Boolean] :decode
939
+ # @return [Array<(EmailHtmlDto, Integer, Hash)>] EmailHtmlDto data, response status code and response headers
940
+ def get_email_html_json_with_http_info(email_id, opts = {})
941
+ if @api_client.config.debugging
942
+ @api_client.config.logger.debug 'Calling API: EmailControllerApi.get_email_html_json ...'
943
+ end
944
+ # verify the required parameter 'email_id' is set
945
+ if @api_client.config.client_side_validation && email_id.nil?
946
+ fail ArgumentError, "Missing the required parameter 'email_id' when calling EmailControllerApi.get_email_html_json"
947
+ end
948
+ # resource path
949
+ local_var_path = '/emails/{emailId}/html/json'.sub('{' + 'emailId' + '}', CGI.escape(email_id.to_s))
950
+
951
+ # query parameters
952
+ query_params = opts[:query_params] || {}
953
+ query_params[:'decode'] = opts[:'decode'] if !opts[:'decode'].nil?
954
+
955
+ # header parameters
956
+ header_params = opts[:header_params] || {}
957
+ # HTTP header 'Accept' (if needed)
958
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
959
+
960
+ # form parameters
961
+ form_params = opts[:form_params] || {}
962
+
963
+ # http body (model)
964
+ post_body = opts[:body]
965
+
966
+ # return_type
967
+ return_type = opts[:return_type] || 'EmailHtmlDto'
968
+
969
+ # auth_names
970
+ auth_names = opts[:auth_names] || ['API_KEY']
971
+
972
+ new_options = opts.merge(
973
+ :header_params => header_params,
974
+ :query_params => query_params,
975
+ :form_params => form_params,
976
+ :body => post_body,
977
+ :auth_names => auth_names,
978
+ :return_type => return_type
979
+ )
980
+
981
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
982
+ if @api_client.config.debugging
983
+ @api_client.config.logger.debug "API called: EmailControllerApi#get_email_html_json\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
984
+ end
985
+ return data, status_code, headers
986
+ end
987
+
923
988
  # Parse and return text from an email, stripping HTML and decoding encoded characters
924
989
  # Parse an email body and return the content as an array of text. HTML parsing uses JSoup which supports JQuery/CSS style selectors
925
990
  # @param email_id [String] ID of email to perform HTML query on
@@ -180,6 +180,7 @@ module MailSlurpClient
180
180
  end
181
181
 
182
182
  # Get MissedEmail
183
+ # List emails that were missed due to plan limits.
183
184
  # @param missed_email_id [String]
184
185
  # @param [Hash] opts the optional parameters
185
186
  # @return [MissedEmail]
@@ -189,6 +190,7 @@ module MailSlurpClient
189
190
  end
190
191
 
191
192
  # Get MissedEmail
193
+ # List emails that were missed due to plan limits.
192
194
  # @param missed_email_id [String]
193
195
  # @param [Hash] opts the optional parameters
194
196
  # @return [Array<(MissedEmail, Integer, Hash)>] MissedEmail data, response status code and response headers
@@ -239,6 +241,60 @@ module MailSlurpClient
239
241
  return data, status_code, headers
240
242
  end
241
243
 
244
+ # Restore missed emails
245
+ # If emails were missed due to a plan limit they are saved as missed emails. If support team enables the canRestore flag these emails can be reload into your account using this method.
246
+ # @param [Hash] opts the optional parameters
247
+ # @return [nil]
248
+ def restore_missed_emails(opts = {})
249
+ restore_missed_emails_with_http_info(opts)
250
+ nil
251
+ end
252
+
253
+ # Restore missed emails
254
+ # If emails were missed due to a plan limit they are saved as missed emails. If support team enables the canRestore flag these emails can be reload into your account using this method.
255
+ # @param [Hash] opts the optional parameters
256
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
257
+ def restore_missed_emails_with_http_info(opts = {})
258
+ if @api_client.config.debugging
259
+ @api_client.config.logger.debug 'Calling API: MissedEmailControllerApi.restore_missed_emails ...'
260
+ end
261
+ # resource path
262
+ local_var_path = '/missed-emails/restore'
263
+
264
+ # query parameters
265
+ query_params = opts[:query_params] || {}
266
+
267
+ # header parameters
268
+ header_params = opts[:header_params] || {}
269
+
270
+ # form parameters
271
+ form_params = opts[:form_params] || {}
272
+
273
+ # http body (model)
274
+ post_body = opts[:body]
275
+
276
+ # return_type
277
+ return_type = opts[:return_type]
278
+
279
+ # auth_names
280
+ auth_names = opts[:auth_names] || ['API_KEY']
281
+
282
+ new_options = opts.merge(
283
+ :header_params => header_params,
284
+ :query_params => query_params,
285
+ :form_params => form_params,
286
+ :body => post_body,
287
+ :auth_names => auth_names,
288
+ :return_type => return_type
289
+ )
290
+
291
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
292
+ if @api_client.config.debugging
293
+ @api_client.config.logger.debug "API called: MissedEmailControllerApi#restore_missed_emails\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
294
+ end
295
+ return data, status_code, headers
296
+ end
297
+
242
298
  # Wait for Nth missed email
243
299
  # Wait for 0 based index missed email
244
300
  # @param index [Integer] Zero based index of the email to wait for. If 1 missed email already and you want to wait for the 2nd email pass index&#x3D;1