resend 1.3.0 → 1.4.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ae47d450acbf7a17e8cc0cfc77c62aea2fe7366f5336f629184cfdf9e80b8a2a
4
- data.tar.gz: 3ffffd20088ffdf0ec7005aeef284bca4823c477f547d42d4dfe70cd4e59afc7
3
+ metadata.gz: 5bac6323a992135612079621a1d9933831c44e6202838cff57377397c2214f2c
4
+ data.tar.gz: c584c139bad503543f7cad52639f9dc6fe86812da1550b38729cd96638b9988b
5
5
  SHA512:
6
- metadata.gz: c51c73409a3f32adbedd3b1630938eedb88190121aed9885271907405abaff2c1828bcd6c1f96d69242278cbe57eed00a25e38e95fffaad80ddabbaf12ae2a79
7
- data.tar.gz: 1481bfc139bdc8c30173143c626be748de08f0b734f482928fa37e63e01dd21f6a74cfc765c60243da2603d392785d4fcdc96b8abc2def20846bf511a941a81f
6
+ metadata.gz: 4411842066220cc450056f799a94d6cba513a6bf5c0c67c8f467e68e1cc8320911c3f47f983ec32430dc09961d4e005fb1f1ce429997b2ae5be5045eb7b85de6
7
+ data.tar.gz: '0586cc9b333744f728d34847cc7de9bb18109b5658e870354f3b6a69b1988d4366e0bf4f37e3564a6a63f16de9e33f1070b3f15410be0dc88a996e8d3eff9336'
@@ -8,12 +8,20 @@ module Resend
8
8
  # Retrieve a single received email
9
9
  #
10
10
  # @param email_id [String] The ID of the received email
11
+ # @param params [Hash] Optional query parameters
12
+ # @option params [String] :html_format Format of the HTML content (e.g., "sanitized", "raw")
11
13
  # @return [Hash] The received email object
12
14
  #
13
15
  # @example
14
16
  # Resend::Emails::Receiving.get("4ef9a417-02e9-4d39-ad75-9611e0fcc33c")
15
- def get(email_id = "")
17
+ #
18
+ # @example With html_format
19
+ # Resend::Emails::Receiving.get("4ef9a417-02e9-4d39-ad75-9611e0fcc33c", html_format: "sanitized")
20
+ def get(email_id = "", params = {})
16
21
  path = "emails/receiving/#{email_id}"
22
+
23
+ path += "?html_format=#{CGI.escape(params[:html_format].to_s)}" if params[:html_format]
24
+
17
25
  Resend::Request.new(path, {}, "get").perform
18
26
  end
19
27
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Resend
4
- VERSION = "1.3.0"
4
+ VERSION = "1.4.0"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: resend
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.0
4
+ version: 1.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Derich Pacheco