resend 1.19.0 → 1.20.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/resend/domains/forge.rb +27 -0
- data/lib/resend/domains.rb +5 -2
- data/lib/resend/version.rb +1 -1
- data/lib/resend.rb +1 -0
- metadata +2 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: affe43971dd7a98780846553d195485f10fabfc03ed0b07a1c116eb9c1c53900
|
|
4
|
+
data.tar.gz: 1547e140aa0c32b6eb9033a331a89abf6737ea36dfa3adec8226ff5e66bb4bc5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: '08481ada73dbc769b9aed075dfe11a301a5a9551fab2740f4ed39fa83c54ca0d343c627c64a3d4074e5d9dccd9f33f1d25309ae8f0c7b867f3b2a8772249a934'
|
|
7
|
+
data.tar.gz: 2166a5fd68509af30d794821545aa70a5992bdf7d10a61d7255572dd641d8e44f867cbb642e866b13cc400585b65ccb5caed864adcf077c344a8d8efc0f12ff4
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Resend
|
|
4
|
+
module Domains
|
|
5
|
+
# Domain Forge API wrapper
|
|
6
|
+
module Forge
|
|
7
|
+
class << self
|
|
8
|
+
#
|
|
9
|
+
# Activate Forge on a domain. Returns the full domain, in the same shape
|
|
10
|
+
# as Resend::Domains.get. Enabling a domain that is already migrated is
|
|
11
|
+
# idempotent and returns its current state.
|
|
12
|
+
#
|
|
13
|
+
# @param params [Hash] the parameters
|
|
14
|
+
# @option params [String] :id the ID of the domain (required)
|
|
15
|
+
# @option params [String] :custom_return_path subdomain for the Return-Path address,
|
|
16
|
+
# validated like :custom_return_path on Resend::Domains.create. When omitted, the
|
|
17
|
+
# server picks a free DNS label. Set once: it cannot be changed afterwards.
|
|
18
|
+
#
|
|
19
|
+
# https://resend.com/docs/api-reference/domains/enable-forge
|
|
20
|
+
def enable(params)
|
|
21
|
+
path = "domains/#{params[:id]}/forge"
|
|
22
|
+
Resend::Request.new(path, params.slice(:custom_return_path), "post").perform
|
|
23
|
+
end
|
|
24
|
+
end
|
|
25
|
+
end
|
|
26
|
+
end
|
|
27
|
+
end
|
data/lib/resend/domains.rb
CHANGED
|
@@ -34,10 +34,13 @@ module Resend
|
|
|
34
34
|
Resend::Request.new(path, {}, "delete").perform
|
|
35
35
|
end
|
|
36
36
|
|
|
37
|
+
# Triggers domain verification. Pass `scope: ["forge"]` to re-check only
|
|
38
|
+
# the Forge record; without a scope the whole domain is verified.
|
|
39
|
+
#
|
|
37
40
|
# https://resend.com/docs/api-reference/domains/verify-domain
|
|
38
|
-
def verify(domain_id = "")
|
|
41
|
+
def verify(domain_id = "", params = {})
|
|
39
42
|
path = "domains/#{domain_id}/verify"
|
|
40
|
-
Resend::Request.new(path,
|
|
43
|
+
Resend::Request.new(path, params.slice(:scope), "post").perform
|
|
41
44
|
end
|
|
42
45
|
end
|
|
43
46
|
end
|
data/lib/resend/version.rb
CHANGED
data/lib/resend.rb
CHANGED
|
@@ -27,6 +27,7 @@ require "resend/contacts/topics"
|
|
|
27
27
|
require "resend/contact_properties"
|
|
28
28
|
require "resend/domains"
|
|
29
29
|
require "resend/domains/claims"
|
|
30
|
+
require "resend/domains/forge"
|
|
30
31
|
require "resend/emails"
|
|
31
32
|
require "resend/templates"
|
|
32
33
|
require "resend/emails/receiving"
|
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.
|
|
4
|
+
version: 1.20.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Derich Pacheco
|
|
@@ -62,6 +62,7 @@ files:
|
|
|
62
62
|
- lib/resend/contacts/topics.rb
|
|
63
63
|
- lib/resend/domains.rb
|
|
64
64
|
- lib/resend/domains/claims.rb
|
|
65
|
+
- lib/resend/domains/forge.rb
|
|
65
66
|
- lib/resend/emails.rb
|
|
66
67
|
- lib/resend/emails/attachments.rb
|
|
67
68
|
- lib/resend/emails/receiving.rb
|