buchida 0.2.0 → 0.2.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/lib/buchida/resources/emails.rb +7 -1
- data/lib/buchida/resources/templates.rb +7 -2
- data/lib/buchida/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: 7dbd112ad5d392d35ec62955149963bbec35a8765644c4305939fb42d985b4de
|
|
4
|
+
data.tar.gz: bee7497ebefacd406ff96a6501e09df13e4b8009b5d814bdcbd79b4edec81aea
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 104960ce3956b0c51b243139a74c14fd045eef4d7f391d4b1bf41f0ccbdc290852507391cdd65d278b85b13ce89cea92d35260b6f5a8f6ffb7b80598ca917720
|
|
7
|
+
data.tar.gz: 814f8c84b3398dd20ba19d852523c946afd8099676db8cade70d9f3fe3c8724ef958fbcce35cd6bc1695c9f388ffd62a54a2dd9a7ed48b0d32da51ca68279553
|
|
@@ -24,13 +24,19 @@ module Buchida
|
|
|
24
24
|
@client.request_object(:get, "/emails/#{id}")
|
|
25
25
|
end
|
|
26
26
|
|
|
27
|
-
|
|
27
|
+
# +from+ / +to+ filter by sender / recipient ADDRESS (not dates).
|
|
28
|
+
# +from_date+ / +to_date+ (ISO 8601) filter by creation date;
|
|
29
|
+
# +direction+ is "inbound" or "outbound".
|
|
30
|
+
def list(cursor: nil, limit: nil, status: nil, from: nil, to: nil, from_date: nil, to_date: nil, direction: nil)
|
|
28
31
|
params = {}
|
|
29
32
|
params[:cursor] = cursor if cursor
|
|
30
33
|
params[:limit] = limit if limit
|
|
31
34
|
params[:status] = status if status
|
|
32
35
|
params[:from] = from if from
|
|
33
36
|
params[:to] = to if to
|
|
37
|
+
params[:from_date] = from_date if from_date
|
|
38
|
+
params[:to_date] = to_date if to_date
|
|
39
|
+
params[:direction] = direction if direction
|
|
34
40
|
qs = URI.encode_www_form(params) unless params.empty?
|
|
35
41
|
path = qs ? "/emails?#{qs}" : "/emails"
|
|
36
42
|
@client.request_list(:get, path)
|
|
@@ -7,8 +7,13 @@ module Buchida
|
|
|
7
7
|
@client = client
|
|
8
8
|
end
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
# +status+ is "draft" or "published"; +search+ matches name/subject.
|
|
11
|
+
def list(status: nil, search: nil)
|
|
12
|
+
params = {}
|
|
13
|
+
params[:status] = status if status
|
|
14
|
+
params[:search] = search if search
|
|
15
|
+
path = params.empty? ? "/templates" : "/templates?#{URI.encode_www_form(params)}"
|
|
16
|
+
@client.request_list(:get, path)
|
|
12
17
|
end
|
|
13
18
|
|
|
14
19
|
def get(id)
|
data/lib/buchida/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: buchida
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- buchida
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-10-
|
|
11
|
+
date: 2026-10-19 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: minitest
|