lithic 0.1.0.pre.alpha.36 → 0.1.0.pre.alpha.37
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/CHANGELOG.md +15 -0
- data/README.md +1 -1
- data/lib/lithic/internal/transport/base_client.rb +10 -2
- data/lib/lithic/models/transaction.rb +19 -1
- data/lib/lithic/version.rb +1 -1
- data/rbi/lithic/models/transaction.rbi +47 -0
- data/sig/lithic/models/transaction.rbs +20 -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: 9b4a8aa1bcee44fcd985d8a93418bc3533ea5a6148a11de990fcfabf018c9ec4
|
4
|
+
data.tar.gz: 7aa6f8bbca7ee0ed1768021d863a0c46d56e6baed438ca005e76f80820b9ca03
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 20a6d92fce5ebf2e08c8c9f21b5383e72859f38762d408177233df51df163ac6ed4b10f9cc096dc5305e09c33844c1f0275cfd6d6335c4d90d9a7926715ee17d
|
7
|
+
data.tar.gz: 9f5fade7164be49471441e76143513ac363539766fc46ee67fd74864dbfa35956aa2bafb391c083bc9f6f7f2cc53774a190dceb1fc73e28f3fbe65bcf0b15ea6
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,20 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## 0.1.0-alpha.37 (2025-07-02)
|
4
|
+
|
5
|
+
Full Changelog: [v0.1.0-alpha.36...v0.1.0-alpha.37](https://github.com/lithic-com/lithic-ruby/compare/v0.1.0-alpha.36...v0.1.0-alpha.37)
|
6
|
+
|
7
|
+
### Features
|
8
|
+
|
9
|
+
* **api:** api update ([95e6f93](https://github.com/lithic-com/lithic-ruby/commit/95e6f93cf300b9b2b96adaacc238da151d76bf06))
|
10
|
+
|
11
|
+
|
12
|
+
### Chores
|
13
|
+
|
14
|
+
* **ci:** only run for pushes and fork pull requests ([5e19b24](https://github.com/lithic-com/lithic-ruby/commit/5e19b24fcad22d51f01f3c26c82da029af648a3e))
|
15
|
+
* **internal:** allow streams to also be unwrapped on a per-row basis ([99c6f00](https://github.com/lithic-com/lithic-ruby/commit/99c6f001da13f61889cd29108f5ac6f49d875263))
|
16
|
+
* **internal:** manual updates ([05f1d5c](https://github.com/lithic-com/lithic-ruby/commit/05f1d5ceec90714c132c664035d658492c806653))
|
17
|
+
|
3
18
|
## 0.1.0-alpha.36 (2025-06-27)
|
4
19
|
|
5
20
|
Full Changelog: [v0.1.0-alpha.35...v0.1.0-alpha.36](https://github.com/lithic-com/lithic-ruby/compare/v0.1.0-alpha.35...v0.1.0-alpha.36)
|
data/README.md
CHANGED
@@ -15,7 +15,7 @@ To use this gem, install via Bundler by adding the following to your application
|
|
15
15
|
<!-- x-release-please-start-version -->
|
16
16
|
|
17
17
|
```ruby
|
18
|
-
gem "lithic", "~> 0.1.0.pre.alpha.
|
18
|
+
gem "lithic", "~> 0.1.0.pre.alpha.37"
|
19
19
|
```
|
20
20
|
|
21
21
|
<!-- x-release-please-end -->
|
@@ -471,6 +471,7 @@ module Lithic
|
|
471
471
|
self.class.validate!(req)
|
472
472
|
model = req.fetch(:model) { Lithic::Internal::Type::Unknown }
|
473
473
|
opts = req[:options].to_h
|
474
|
+
unwrap = req[:unwrap]
|
474
475
|
Lithic::RequestOptions.validate!(opts)
|
475
476
|
request = build_request(req.except(:options), opts)
|
476
477
|
url = request.fetch(:url)
|
@@ -487,11 +488,18 @@ module Lithic
|
|
487
488
|
decoded = Lithic::Internal::Util.decode_content(response, stream: stream)
|
488
489
|
case req
|
489
490
|
in {stream: Class => st}
|
490
|
-
st.new(
|
491
|
+
st.new(
|
492
|
+
model: model,
|
493
|
+
url: url,
|
494
|
+
status: status,
|
495
|
+
response: response,
|
496
|
+
unwrap: unwrap,
|
497
|
+
stream: decoded
|
498
|
+
)
|
491
499
|
in {page: Class => page}
|
492
500
|
page.new(client: self, req: req, headers: response, page_data: decoded)
|
493
501
|
else
|
494
|
-
unwrapped = Lithic::Internal::Util.dig(decoded,
|
502
|
+
unwrapped = Lithic::Internal::Util.dig(decoded, unwrap)
|
495
503
|
Lithic::Internal::Type::Converter.coerce(model, unwrapped)
|
496
504
|
end
|
497
505
|
end
|
@@ -1086,12 +1086,17 @@ module Lithic
|
|
1086
1086
|
# @return [Symbol, Lithic::Models::Transaction::Event::Type]
|
1087
1087
|
required :type, enum: -> { Lithic::Transaction::Event::Type }
|
1088
1088
|
|
1089
|
+
# @!attribute account_type
|
1090
|
+
#
|
1091
|
+
# @return [Symbol, Lithic::Models::Transaction::Event::AccountType, nil]
|
1092
|
+
optional :account_type, enum: -> { Lithic::Transaction::Event::AccountType }
|
1093
|
+
|
1089
1094
|
# @!attribute network_specific_data
|
1090
1095
|
#
|
1091
1096
|
# @return [Lithic::Models::Transaction::Event::NetworkSpecificData, nil]
|
1092
1097
|
optional :network_specific_data, -> { Lithic::Transaction::Event::NetworkSpecificData }
|
1093
1098
|
|
1094
|
-
# @!method initialize(token:, amount:, amounts:, created:, detailed_results:, effective_polarity:, network_info:, result:, rule_results:, type:, network_specific_data: nil)
|
1099
|
+
# @!method initialize(token:, amount:, amounts:, created:, detailed_results:, effective_polarity:, network_info:, result:, rule_results:, type:, account_type: nil, network_specific_data: nil)
|
1095
1100
|
# Some parameter documentations has been truncated, see
|
1096
1101
|
# {Lithic::Models::Transaction::Event} for more details.
|
1097
1102
|
#
|
@@ -1115,6 +1120,8 @@ module Lithic
|
|
1115
1120
|
#
|
1116
1121
|
# @param type [Symbol, Lithic::Models::Transaction::Event::Type] Type of transaction event
|
1117
1122
|
#
|
1123
|
+
# @param account_type [Symbol, Lithic::Models::Transaction::Event::AccountType]
|
1124
|
+
#
|
1118
1125
|
# @param network_specific_data [Lithic::Models::Transaction::Event::NetworkSpecificData]
|
1119
1126
|
|
1120
1127
|
# @see Lithic::Models::Transaction::Event#amounts
|
@@ -1633,6 +1640,17 @@ module Lithic
|
|
1633
1640
|
# @return [Array<Symbol>]
|
1634
1641
|
end
|
1635
1642
|
|
1643
|
+
# @see Lithic::Models::Transaction::Event#account_type
|
1644
|
+
module AccountType
|
1645
|
+
extend Lithic::Internal::Type::Enum
|
1646
|
+
|
1647
|
+
CHECKING = :CHECKING
|
1648
|
+
SAVINGS = :SAVINGS
|
1649
|
+
|
1650
|
+
# @!method self.values
|
1651
|
+
# @return [Array<Symbol>]
|
1652
|
+
end
|
1653
|
+
|
1636
1654
|
# @see Lithic::Models::Transaction::Event#network_specific_data
|
1637
1655
|
class NetworkSpecificData < Lithic::Internal::Type::BaseModel
|
1638
1656
|
# @!attribute mastercard
|
data/lib/lithic/version.rb
CHANGED
@@ -2087,6 +2087,20 @@ module Lithic
|
|
2087
2087
|
sig { returns(Lithic::Transaction::Event::Type::TaggedSymbol) }
|
2088
2088
|
attr_accessor :type
|
2089
2089
|
|
2090
|
+
sig do
|
2091
|
+
returns(
|
2092
|
+
T.nilable(Lithic::Transaction::Event::AccountType::TaggedSymbol)
|
2093
|
+
)
|
2094
|
+
end
|
2095
|
+
attr_reader :account_type
|
2096
|
+
|
2097
|
+
sig do
|
2098
|
+
params(
|
2099
|
+
account_type: Lithic::Transaction::Event::AccountType::OrSymbol
|
2100
|
+
).void
|
2101
|
+
end
|
2102
|
+
attr_writer :account_type
|
2103
|
+
|
2090
2104
|
sig do
|
2091
2105
|
returns(T.nilable(Lithic::Transaction::Event::NetworkSpecificData))
|
2092
2106
|
end
|
@@ -2116,6 +2130,7 @@ module Lithic
|
|
2116
2130
|
rule_results:
|
2117
2131
|
T::Array[Lithic::Transaction::Event::RuleResult::OrHash],
|
2118
2132
|
type: Lithic::Transaction::Event::Type::OrSymbol,
|
2133
|
+
account_type: Lithic::Transaction::Event::AccountType::OrSymbol,
|
2119
2134
|
network_specific_data:
|
2120
2135
|
Lithic::Transaction::Event::NetworkSpecificData::OrHash
|
2121
2136
|
).returns(T.attached_class)
|
@@ -2145,6 +2160,7 @@ module Lithic
|
|
2145
2160
|
rule_results:,
|
2146
2161
|
# Type of transaction event
|
2147
2162
|
type:,
|
2163
|
+
account_type: nil,
|
2148
2164
|
network_specific_data: nil
|
2149
2165
|
)
|
2150
2166
|
end
|
@@ -2166,6 +2182,8 @@ module Lithic
|
|
2166
2182
|
result: Lithic::Transaction::Event::Result::TaggedSymbol,
|
2167
2183
|
rule_results: T::Array[Lithic::Transaction::Event::RuleResult],
|
2168
2184
|
type: Lithic::Transaction::Event::Type::TaggedSymbol,
|
2185
|
+
account_type:
|
2186
|
+
Lithic::Transaction::Event::AccountType::TaggedSymbol,
|
2169
2187
|
network_specific_data:
|
2170
2188
|
Lithic::Transaction::Event::NetworkSpecificData
|
2171
2189
|
}
|
@@ -3612,6 +3630,35 @@ module Lithic
|
|
3612
3630
|
end
|
3613
3631
|
end
|
3614
3632
|
|
3633
|
+
module AccountType
|
3634
|
+
extend Lithic::Internal::Type::Enum
|
3635
|
+
|
3636
|
+
TaggedSymbol =
|
3637
|
+
T.type_alias do
|
3638
|
+
T.all(Symbol, Lithic::Transaction::Event::AccountType)
|
3639
|
+
end
|
3640
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
3641
|
+
|
3642
|
+
CHECKING =
|
3643
|
+
T.let(
|
3644
|
+
:CHECKING,
|
3645
|
+
Lithic::Transaction::Event::AccountType::TaggedSymbol
|
3646
|
+
)
|
3647
|
+
SAVINGS =
|
3648
|
+
T.let(
|
3649
|
+
:SAVINGS,
|
3650
|
+
Lithic::Transaction::Event::AccountType::TaggedSymbol
|
3651
|
+
)
|
3652
|
+
|
3653
|
+
sig do
|
3654
|
+
override.returns(
|
3655
|
+
T::Array[Lithic::Transaction::Event::AccountType::TaggedSymbol]
|
3656
|
+
)
|
3657
|
+
end
|
3658
|
+
def self.values
|
3659
|
+
end
|
3660
|
+
end
|
3661
|
+
|
3615
3662
|
class NetworkSpecificData < Lithic::Internal::Type::BaseModel
|
3616
3663
|
OrHash =
|
3617
3664
|
T.type_alias do
|
@@ -876,6 +876,7 @@ module Lithic
|
|
876
876
|
result: Lithic::Models::Transaction::Event::result,
|
877
877
|
rule_results: ::Array[Lithic::Transaction::Event::RuleResult],
|
878
878
|
type: Lithic::Models::Transaction::Event::type_,
|
879
|
+
account_type: Lithic::Models::Transaction::Event::account_type,
|
879
880
|
network_specific_data: Lithic::Transaction::Event::NetworkSpecificData
|
880
881
|
}
|
881
882
|
|
@@ -900,6 +901,12 @@ module Lithic
|
|
900
901
|
|
901
902
|
attr_accessor type: Lithic::Models::Transaction::Event::type_
|
902
903
|
|
904
|
+
attr_reader account_type: Lithic::Models::Transaction::Event::account_type?
|
905
|
+
|
906
|
+
def account_type=: (
|
907
|
+
Lithic::Models::Transaction::Event::account_type
|
908
|
+
) -> Lithic::Models::Transaction::Event::account_type
|
909
|
+
|
903
910
|
attr_reader network_specific_data: Lithic::Transaction::Event::NetworkSpecificData?
|
904
911
|
|
905
912
|
def network_specific_data=: (
|
@@ -917,6 +924,7 @@ module Lithic
|
|
917
924
|
result: Lithic::Models::Transaction::Event::result,
|
918
925
|
rule_results: ::Array[Lithic::Transaction::Event::RuleResult],
|
919
926
|
type: Lithic::Models::Transaction::Event::type_,
|
927
|
+
?account_type: Lithic::Models::Transaction::Event::account_type,
|
920
928
|
?network_specific_data: Lithic::Transaction::Event::NetworkSpecificData
|
921
929
|
) -> void
|
922
930
|
|
@@ -931,6 +939,7 @@ module Lithic
|
|
931
939
|
result: Lithic::Models::Transaction::Event::result,
|
932
940
|
rule_results: ::Array[Lithic::Transaction::Event::RuleResult],
|
933
941
|
type: Lithic::Models::Transaction::Event::type_,
|
942
|
+
account_type: Lithic::Models::Transaction::Event::account_type,
|
934
943
|
network_specific_data: Lithic::Transaction::Event::NetworkSpecificData
|
935
944
|
}
|
936
945
|
|
@@ -1504,6 +1513,17 @@ module Lithic
|
|
1504
1513
|
def self?.values: -> ::Array[Lithic::Models::Transaction::Event::type_]
|
1505
1514
|
end
|
1506
1515
|
|
1516
|
+
type account_type = :CHECKING | :SAVINGS
|
1517
|
+
|
1518
|
+
module AccountType
|
1519
|
+
extend Lithic::Internal::Type::Enum
|
1520
|
+
|
1521
|
+
CHECKING: :CHECKING
|
1522
|
+
SAVINGS: :SAVINGS
|
1523
|
+
|
1524
|
+
def self?.values: -> ::Array[Lithic::Models::Transaction::Event::account_type]
|
1525
|
+
end
|
1526
|
+
|
1507
1527
|
type network_specific_data =
|
1508
1528
|
{
|
1509
1529
|
mastercard: Lithic::Transaction::Event::NetworkSpecificData::Mastercard,
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lithic
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.0.pre.alpha.
|
4
|
+
version: 0.1.0.pre.alpha.37
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lithic
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-
|
11
|
+
date: 2025-07-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: connection_pool
|