zelf-sdk 1.3.0 → 1.3.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/zelf/errors.rb +6 -1
- data/lib/zelf/models.rb +1 -1
- data/lib/zelf/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c92c1167b2cddff274d5e14f91180d6ca5dc1eda305b2cd9ba9456356a535ead
|
|
4
|
+
data.tar.gz: 4232a2d6adc7520cd0d9972c2e2ade9dd71d2eaa453d58e90dd6a653006b92f8
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2e309ed0f46971b924ae70426ceaa14d677198938a898f653a499e92c1c813d1b278b86ceb829484cdba1d114d74b719861899916b344f42b16601ee4298ad00
|
|
7
|
+
data.tar.gz: 2f00087a2005a8e8a164867be31027d7fe99fe5bcf2daddd5e4e9c6da796c32019ad8d6073b373227c9067b7a00049a586c1b3931bc54663bd4b870aab5ad3f8
|
data/lib/zelf/errors.rb
CHANGED
|
@@ -14,7 +14,12 @@ module Zelf
|
|
|
14
14
|
attr_reader :status, :code, :details, :log_id
|
|
15
15
|
|
|
16
16
|
def initialize(message, status:, code: nil, details: nil, log_id: nil)
|
|
17
|
-
|
|
17
|
+
# The message alone says a request was refused but never which
|
|
18
|
+
# field or which limit, and that is the part a caller can act on.
|
|
19
|
+
reasons = (details || {}).map do |field, said|
|
|
20
|
+
"#{field}: #{said.is_a?(Array) ? said.join(' ') : said}"
|
|
21
|
+
end.join(' ')
|
|
22
|
+
super(reasons.empty? ? message : "#{message} #{reasons}")
|
|
18
23
|
@status = status
|
|
19
24
|
@code = code
|
|
20
25
|
@details = details || {}
|
data/lib/zelf/models.rb
CHANGED
|
@@ -507,7 +507,7 @@ module Zelf
|
|
|
507
507
|
field :transcript, "transcript"
|
|
508
508
|
# Direct URL to the post on its platform
|
|
509
509
|
field :platform_url, "platform_url"
|
|
510
|
-
#
|
|
510
|
+
# What the content was most recently collected under: a hashtag, a creator handle,...
|
|
511
511
|
field :last_keyword, "last_keyword"
|
|
512
512
|
# Short AI-generated summary of the content
|
|
513
513
|
field :ai_summary, "ai_summary"
|
data/lib/zelf/version.rb
CHANGED