resend 1.12.0 → 1.13.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/version.rb +1 -1
- data/lib/resend/webhooks.rb +59 -0
- metadata +7 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 02a3659fe54719cec434f3a832095f1b7ca944ace42891c84f74f295dcf6c241
|
|
4
|
+
data.tar.gz: 36879b724cb895f867f470a56daad7b1b1747796fe9fbc4fa45ff1b184d2c6cf
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 22f62c7e2ff8994689eba4ae17978f12455e6c1d98e16b3cb969c4cc36a9750909bfce85dcef5fc7d7b69f714001c46b101c15c42e2b00a03a9717f71efd50bb
|
|
7
|
+
data.tar.gz: 95d4550369ebee3ee9a1b85fd1347ab6a606cd3a8d0ba8db062da02d1f0bb57c81063ed3073654ef185d444dabeb52e22dc1fd3027914268cbed0a559873b25f
|
data/lib/resend/version.rb
CHANGED
data/lib/resend/webhooks.rb
CHANGED
|
@@ -84,6 +84,65 @@ module Resend
|
|
|
84
84
|
Resend::Request.new(path, {}, "get").perform
|
|
85
85
|
end
|
|
86
86
|
|
|
87
|
+
# Retrieve webhook events
|
|
88
|
+
#
|
|
89
|
+
# @param webhook_id [String] The webhook ID
|
|
90
|
+
# @param params [Hash] The pagination parameters
|
|
91
|
+
# @option params [Integer] :limit Number of webhook events to retrieve (max: 100, min: 1)
|
|
92
|
+
# @option params [String] :after The ID after which to retrieve more webhook events
|
|
93
|
+
#
|
|
94
|
+
# @return [Hash] A paginated list of webhook events
|
|
95
|
+
#
|
|
96
|
+
# @example
|
|
97
|
+
# Resend::Webhooks.list_events("4dd369bc-aa82-4ff3-97de-514ae3000ee0")
|
|
98
|
+
#
|
|
99
|
+
# @example With pagination
|
|
100
|
+
# Resend::Webhooks.list_events("4dd369bc-aa82-4ff3-97de-514ae3000ee0", limit: 20, after: "msg_123")
|
|
101
|
+
def list_events(webhook_id, params = {})
|
|
102
|
+
path = Resend::PaginationHelper.build_paginated_path("webhooks/#{webhook_id}/events", params)
|
|
103
|
+
Resend::Request.new(path, {}, "get").perform
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
# Retrieve a webhook event
|
|
107
|
+
#
|
|
108
|
+
# @param webhook_id [String] The webhook ID
|
|
109
|
+
# @param event_id [String] The webhook event ID
|
|
110
|
+
#
|
|
111
|
+
# @return [Hash] The webhook event with full details
|
|
112
|
+
#
|
|
113
|
+
# @example
|
|
114
|
+
# Resend::Webhooks.get_event("4dd369bc-aa82-4ff3-97de-514ae3000ee0", "msg_123")
|
|
115
|
+
def get_event(webhook_id, event_id)
|
|
116
|
+
path = "webhooks/#{webhook_id}/events/#{event_id}"
|
|
117
|
+
Resend::Request.new(path, {}, "get").perform
|
|
118
|
+
end
|
|
119
|
+
|
|
120
|
+
# Retrieve delivery attempts for a webhook event
|
|
121
|
+
#
|
|
122
|
+
# @param webhook_id [String] The webhook ID
|
|
123
|
+
# @param event_id [String] The webhook event ID
|
|
124
|
+
# @param params [Hash] The pagination parameters
|
|
125
|
+
# @option params [Integer] :limit Number of delivery attempts to retrieve (max: 100, min: 1)
|
|
126
|
+
# @option params [String] :after The ID after which to retrieve more delivery attempts
|
|
127
|
+
#
|
|
128
|
+
# @return [Hash] A paginated list of webhook event delivery attempts
|
|
129
|
+
#
|
|
130
|
+
# @example
|
|
131
|
+
# Resend::Webhooks.list_event_attempts("4dd369bc-aa82-4ff3-97de-514ae3000ee0", "msg_123")
|
|
132
|
+
#
|
|
133
|
+
# @example With pagination
|
|
134
|
+
# Resend::Webhooks.list_event_attempts(
|
|
135
|
+
# "4dd369bc-aa82-4ff3-97de-514ae3000ee0",
|
|
136
|
+
# "msg_123",
|
|
137
|
+
# limit: 20,
|
|
138
|
+
# after: "atmpt_123"
|
|
139
|
+
# )
|
|
140
|
+
def list_event_attempts(webhook_id, event_id, params = {})
|
|
141
|
+
base_path = "webhooks/#{webhook_id}/events/#{event_id}/attempts"
|
|
142
|
+
path = Resend::PaginationHelper.build_paginated_path(base_path, params)
|
|
143
|
+
Resend::Request.new(path, {}, "get").perform
|
|
144
|
+
end
|
|
145
|
+
|
|
87
146
|
# Update an existing webhook configuration
|
|
88
147
|
#
|
|
89
148
|
# @param params [Hash] The webhook update parameters
|
metadata
CHANGED
|
@@ -1,13 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: resend
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.13.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Derich Pacheco
|
|
8
|
+
autorequire:
|
|
8
9
|
bindir: bin
|
|
9
10
|
cert_chain: []
|
|
10
|
-
date:
|
|
11
|
+
date: 2026-08-26 00:00:00.000000000 Z
|
|
11
12
|
dependencies:
|
|
12
13
|
- !ruby/object:Gem::Dependency
|
|
13
14
|
name: base64
|
|
@@ -37,6 +38,7 @@ dependencies:
|
|
|
37
38
|
- - ">="
|
|
38
39
|
- !ruby/object:Gem::Version
|
|
39
40
|
version: 0.22.0
|
|
41
|
+
description:
|
|
40
42
|
email: carlosderich@gmail.com
|
|
41
43
|
executables: []
|
|
42
44
|
extensions: []
|
|
@@ -83,6 +85,7 @@ homepage: https://github.com/resend/resend-ruby
|
|
|
83
85
|
licenses:
|
|
84
86
|
- MIT
|
|
85
87
|
metadata: {}
|
|
88
|
+
post_install_message:
|
|
86
89
|
rdoc_options: []
|
|
87
90
|
require_paths:
|
|
88
91
|
- lib
|
|
@@ -97,7 +100,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
97
100
|
- !ruby/object:Gem::Version
|
|
98
101
|
version: '0'
|
|
99
102
|
requirements: []
|
|
100
|
-
rubygems_version:
|
|
103
|
+
rubygems_version: 3.0.3.1
|
|
104
|
+
signing_key:
|
|
101
105
|
specification_version: 4
|
|
102
106
|
summary: The Ruby and Rails SDK for resend.com
|
|
103
107
|
test_files: []
|