mailblastr 5.1.0 → 5.1.1
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/README.md +1 -0
- data/lib/mailblastr/contacts.rb +3 -0
- data/lib/mailblastr/emails.rb +15 -6
- data/lib/mailblastr/version.rb +1 -1
- 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: 4827370704c9533943a763c3797f16b472f80655940a911111abff606769fe71
|
|
4
|
+
data.tar.gz: 9a924fc0cc8bb4d7d29c78ef6a5b3e1290c82139dee33ea05fe0009b504b2a14
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 111d3d1c97ef0a2e4cf398b90327b48ac389de59f1dad3b80f8df34e16811f32385c2502c98a8672176339bdd7c5056a3467a8ed5a59f8dc14646803317c0dfc
|
|
7
|
+
data.tar.gz: 4ddd8faaba6b557b100c7177f15b9bbcdbf06df0a413088763ad8b174dc6f3fb6f69aac814445a7f8bd9dce1a4f22e2eed2ef324040de2503f63272e48db927b
|
data/README.md
CHANGED
|
@@ -104,6 +104,7 @@ That means `domain` (the sending domain, e.g. `"yourdomain.com"` — one of your
|
|
|
104
104
|
Mailblastr::Emails.send({ from: from, to: to, subject: subject, html: html })
|
|
105
105
|
Mailblastr::Emails.list({ limit: 20, after: cursor }) # cursor pagination
|
|
106
106
|
Mailblastr::Emails.list({ status: "bounced", search: "acme.com" }) # filters
|
|
107
|
+
Mailblastr::Emails.list({ folder: "scheduled" }) # one of outbox | sent | scheduled | failed — any other value is rejected (422)
|
|
107
108
|
Mailblastr::Emails.sources # per-campaign/automation send metrics
|
|
108
109
|
Mailblastr::Emails.get(email_id)
|
|
109
110
|
Mailblastr::Emails.list_attachments(email_id)
|
data/lib/mailblastr/contacts.rb
CHANGED
|
@@ -90,6 +90,9 @@ module Mailblastr
|
|
|
90
90
|
# Contacts.batch({ audience_id: "aud_1", contacts: [{ email: "a@b.com" }], on_conflict: "skip" })
|
|
91
91
|
def batch(params)
|
|
92
92
|
audience_id = Client.opt(params, :audience_id)
|
|
93
|
+
# "" is truthy in Ruby but names no audience — treat it as absent and
|
|
94
|
+
# take the flat route, matching the other MailBlastr SDKs.
|
|
95
|
+
audience_id = nil if audience_id == ""
|
|
93
96
|
query = {}
|
|
94
97
|
on_conflict = Client.opt(params, :on_conflict)
|
|
95
98
|
query[:on_conflict] = on_conflict if on_conflict
|
data/lib/mailblastr/emails.rb
CHANGED
|
@@ -27,10 +27,16 @@ module Mailblastr
|
|
|
27
27
|
|
|
28
28
|
# List sent emails (trimmed list items) — cursor pagination plus optional
|
|
29
29
|
# server-side filters: `campaign_id`, `automation_id`, `source`
|
|
30
|
-
# ("individual"
|
|
31
|
-
#
|
|
32
|
-
#
|
|
33
|
-
#
|
|
30
|
+
# ("individual" for all one-off sends with no campaign/automation origin,
|
|
31
|
+
# "api" for one-off sends made with an API key — which also covers mail
|
|
32
|
+
# sent before the send origin was recorded — or "dashboard" for one-off
|
|
33
|
+
# mail composed in the dashboard: the composer and inbox replies/forwards;
|
|
34
|
+
# honoured only when neither `campaign_id` nor `automation_id` is
|
|
35
|
+
# supplied), `domain_id`, `status` (matched case-insensitively
|
|
36
|
+
# against the row's `last_event`), `folder` (one of "outbox", "sent",
|
|
37
|
+
# "scheduled" or "failed" — any other value is rejected with a 422) and
|
|
38
|
+
# `search` (recipients, subject and sender). `q` is the server's alias
|
|
39
|
+
# for `search`, honoured only when `search` is absent. GET /emails
|
|
34
40
|
def list(params = {})
|
|
35
41
|
query = Client.pagination(params).merge(
|
|
36
42
|
Client.filters(params, :campaign_id, :automation_id, :source, :domain_id, :status, :search, :q, :folder)
|
|
@@ -38,8 +44,11 @@ module Mailblastr
|
|
|
38
44
|
Client.request(:get, "/emails", query: query)
|
|
39
45
|
end
|
|
40
46
|
|
|
41
|
-
# Per-source send metrics, one row per
|
|
42
|
-
#
|
|
47
|
+
# Per-source send metrics, one row per origin. `kind` is "campaign",
|
|
48
|
+
# "automation", "api" (one-off API-key sends, including mail sent before
|
|
49
|
+
# the send origin was recorded) or "individual" (dashboard-composed
|
|
50
|
+
# one-offs); `id`, `name`, `subject` and `status` are null for both the
|
|
51
|
+
# "api" and "individual" rows. Not paginated. GET /emails/sources
|
|
43
52
|
def sources
|
|
44
53
|
Client.request(:get, "/emails/sources")
|
|
45
54
|
end
|
data/lib/mailblastr/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: mailblastr
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 5.1.
|
|
4
|
+
version: 5.1.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- MailBlastr
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-08-
|
|
11
|
+
date: 2026-08-30 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: minitest
|