sendly 3.29.0 → 3.30.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/Gemfile.lock +1 -1
- data/README.md +1 -1
- data/lib/sendly/version.rb +1 -1
- data/lib/sendly/webhooks_resource.rb +50 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 0aa8097776c931f504cc3f006783ed8232691fc48c35c93b8930437c9f5480b5
|
|
4
|
+
data.tar.gz: 74cfe38cea2edefae5a4173dbbae2ff4df2a3364e69de2329191ef95fd26195b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 40d6bb9e8df8757fa585253b39b49e85973f7959f1278b8354c803b293047bb0dbf279dafd5c5550e61d4b6a26ed78ada5295ab686a312dc32f026d46ff7203f
|
|
7
|
+
data.tar.gz: b4ee727e07b7fc3fa75326e36ae073c62d50e6d3c98b5905c745444c80d6dd358ab19a5ed36c0853af3c07eba7fbba50d6db7389f469c3555abf15d6960b5742
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
|
@@ -354,7 +354,7 @@ message.pending? # => true/false
|
|
|
354
354
|
|
|
355
355
|
| Tier | Countries | Credits per SMS |
|
|
356
356
|
|------|-----------|-----------------|
|
|
357
|
-
| Domestic | US, CA |
|
|
357
|
+
| Domestic | US, CA | 2 |
|
|
358
358
|
| Tier 1 | GB, PL, IN, etc. | 8 |
|
|
359
359
|
| Tier 2 | FR, JP, AU, etc. | 12 |
|
|
360
360
|
| Tier 3 | DE, IT, MX, etc. | 16 |
|
data/lib/sendly/version.rb
CHANGED
|
@@ -110,6 +110,56 @@ module Sendly
|
|
|
110
110
|
@client.post("/webhooks/#{webhook_id}/reset-circuit")
|
|
111
111
|
end
|
|
112
112
|
|
|
113
|
+
# Replay failed or cancelled webhook deliveries from the audit log.
|
|
114
|
+
#
|
|
115
|
+
# Use after a customer endpoint has recovered from an outage to re-fire
|
|
116
|
+
# deliveries we recorded but couldn't deliver. Each replay creates a new
|
|
117
|
+
# delivery row preserving the original event_id so customers can dedupe.
|
|
118
|
+
# Rejects with HTTP 409 if the circuit is currently open — call
|
|
119
|
+
# {#reset_circuit} first.
|
|
120
|
+
#
|
|
121
|
+
# @param webhook_id [String] Webhook ID
|
|
122
|
+
# @param since [String, nil] ISO-8601, default now − 24h
|
|
123
|
+
# @param until_ [String, nil] ISO-8601, default now
|
|
124
|
+
# @param event_types [Array<String>, nil] Filter by event type
|
|
125
|
+
# @param statuses [Array<String>, nil] Default ["failed", "cancelled"]
|
|
126
|
+
# @param limit [Integer, nil] Max deliveries to requeue (default 1000, max 10000)
|
|
127
|
+
# @return [Hash] Counts of requeued deliveries plus delivery IDs
|
|
128
|
+
def redeliver(webhook_id, since: nil, until_: nil, event_types: nil, statuses: nil, limit: nil)
|
|
129
|
+
validate_webhook_id!(webhook_id)
|
|
130
|
+
body = {}
|
|
131
|
+
body[:since] = since unless since.nil?
|
|
132
|
+
body[:until] = until_ unless until_.nil?
|
|
133
|
+
body[:event_types] = event_types unless event_types.nil?
|
|
134
|
+
body[:statuses] = statuses unless statuses.nil?
|
|
135
|
+
body[:limit] = limit unless limit.nil?
|
|
136
|
+
@client.post("/webhooks/#{webhook_id}/redeliver", body)
|
|
137
|
+
end
|
|
138
|
+
|
|
139
|
+
# Backfill missed webhook events from the underlying message log.
|
|
140
|
+
#
|
|
141
|
+
# Use when a circuit-breaker outage left events with no audit row (the
|
|
142
|
+
# case {#redeliver} cannot recover). Synthesized events have fresh IDs;
|
|
143
|
+
# clients should dedupe by event.data.object.id (the message ID).
|
|
144
|
+
# Rejects with HTTP 409 if the circuit is currently open — call
|
|
145
|
+
# {#reset_circuit} first.
|
|
146
|
+
#
|
|
147
|
+
# @param webhook_id [String] Webhook ID
|
|
148
|
+
# @param since [String, nil] ISO-8601, default now − 24h
|
|
149
|
+
# @param until_ [String, nil] ISO-8601, default now
|
|
150
|
+
# @param event_types [Array<String>, nil] Filter by event type
|
|
151
|
+
# @param limit [Integer, nil] Max events to synthesize (default 1000, max 10000)
|
|
152
|
+
# @return [Hash] Counts grouped by event type plus delivery IDs
|
|
153
|
+
def backfill(webhook_id, since: nil, until_: nil, event_types: nil, limit: nil)
|
|
154
|
+
validate_webhook_id!(webhook_id)
|
|
155
|
+
body = {}
|
|
156
|
+
body[:since] = since unless since.nil?
|
|
157
|
+
body[:until] = until_ unless until_.nil?
|
|
158
|
+
body[:event_types] = event_types unless event_types.nil?
|
|
159
|
+
body[:limit] = limit unless limit.nil?
|
|
160
|
+
@client.post("/webhooks/#{webhook_id}/backfill", body)
|
|
161
|
+
end
|
|
162
|
+
|
|
113
163
|
# Rotate the webhook signing secret
|
|
114
164
|
#
|
|
115
165
|
# @param webhook_id [String] Webhook ID
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: sendly
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.
|
|
4
|
+
version: 3.30.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Sendly
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-
|
|
11
|
+
date: 2026-05-01 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: faraday
|