From 1bb4cc80ab6e025ebf0d6fcdd88c5b62cbb602a0 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 1 Sep 2026 12:53:27 +0000 Subject: [PATCH 01/14] feat(api): add OTHER enum value to auth_rules type field --- .stats.yml | 4 +-- lib/lithic/models/auth_rules/auth_rule.rb | 5 +++ .../models/auth_rules/v2_create_params.rb | 15 +++++++++ rbi/lithic/models/auth_rules/auth_rule.rbi | 7 ++++ .../models/auth_rules/v2_create_params.rbi | 33 +++++++++++++++++++ sig/lithic/models/auth_rules/auth_rule.rbs | 2 ++ .../models/auth_rules/v2_create_params.rbs | 6 ++++ 7 files changed, 70 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index 47c7d754..9326df23 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 216 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-38a020a15ab14f79c7fea3290822406cf80a9d43d46ab3295632a9723f5e42cd.yml -openapi_spec_hash: 5a7357a17c5119bc91d8f5e42297fac3 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-9a4064ca9be1efe3e33d922cae77a5d186b6a0119ef1d3601b5ded1447feb7f7.yml +openapi_spec_hash: bff457821129b2eb4fc5150e23efa197 config_hash: 27fa50e251754c8982e3dc615ef6da41 diff --git a/lib/lithic/models/auth_rules/auth_rule.rb b/lib/lithic/models/auth_rules/auth_rule.rb index 0c894dc8..73f09962 100644 --- a/lib/lithic/models/auth_rules/auth_rule.rb +++ b/lib/lithic/models/auth_rules/auth_rule.rb @@ -86,6 +86,8 @@ class AuthRule < Lithic::Internal::Type::BaseModel # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. # # @return [Symbol, Lithic::Models::AuthRules::AuthRule::Type] required :type, enum: -> { Lithic::AuthRules::AuthRule::Type } @@ -339,6 +341,8 @@ module State # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. # # @see Lithic::Models::AuthRules::AuthRule#type module Type @@ -349,6 +353,7 @@ module Type MERCHANT_LOCK = :MERCHANT_LOCK CONDITIONAL_ACTION = :CONDITIONAL_ACTION TYPESCRIPT_CODE = :TYPESCRIPT_CODE + OTHER = :OTHER # @!method self.values # @return [Array] diff --git a/lib/lithic/models/auth_rules/v2_create_params.rb b/lib/lithic/models/auth_rules/v2_create_params.rb index 26be59f5..7e33c77c 100644 --- a/lib/lithic/models/auth_rules/v2_create_params.rb +++ b/lib/lithic/models/auth_rules/v2_create_params.rb @@ -49,6 +49,8 @@ class AccountLevelRule < Lithic::Internal::Type::BaseModel # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. # # @return [Symbol, Lithic::Models::AuthRules::V2CreateParams::Body::AccountLevelRule::Type] required :type, enum: -> { Lithic::AuthRules::V2CreateParams::Body::AccountLevelRule::Type } @@ -143,6 +145,8 @@ module Parameters # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. # # @see Lithic::Models::AuthRules::V2CreateParams::Body::AccountLevelRule#type module Type @@ -153,6 +157,7 @@ module Type MERCHANT_LOCK = :MERCHANT_LOCK CONDITIONAL_ACTION = :CONDITIONAL_ACTION TYPESCRIPT_CODE = :TYPESCRIPT_CODE + OTHER = :OTHER # @!method self.values # @return [Array] @@ -188,6 +193,8 @@ class CardLevelRule < Lithic::Internal::Type::BaseModel # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. # # @return [Symbol, Lithic::Models::AuthRules::V2CreateParams::Body::CardLevelRule::Type] required :type, enum: -> { Lithic::AuthRules::V2CreateParams::Body::CardLevelRule::Type } @@ -268,6 +275,8 @@ module Parameters # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. # # @see Lithic::Models::AuthRules::V2CreateParams::Body::CardLevelRule#type module Type @@ -278,6 +287,7 @@ module Type MERCHANT_LOCK = :MERCHANT_LOCK CONDITIONAL_ACTION = :CONDITIONAL_ACTION TYPESCRIPT_CODE = :TYPESCRIPT_CODE + OTHER = :OTHER # @!method self.values # @return [Array] @@ -313,6 +323,8 @@ class ProgramLevelRule < Lithic::Internal::Type::BaseModel # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. # # @return [Symbol, Lithic::Models::AuthRules::V2CreateParams::Body::ProgramLevelRule::Type] required :type, enum: -> { Lithic::AuthRules::V2CreateParams::Body::ProgramLevelRule::Type } @@ -417,6 +429,8 @@ module Parameters # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. # # @see Lithic::Models::AuthRules::V2CreateParams::Body::ProgramLevelRule#type module Type @@ -427,6 +441,7 @@ module Type MERCHANT_LOCK = :MERCHANT_LOCK CONDITIONAL_ACTION = :CONDITIONAL_ACTION TYPESCRIPT_CODE = :TYPESCRIPT_CODE + OTHER = :OTHER # @!method self.values # @return [Array] diff --git a/rbi/lithic/models/auth_rules/auth_rule.rbi b/rbi/lithic/models/auth_rules/auth_rule.rbi index c7ec1192..d4f9baba 100644 --- a/rbi/lithic/models/auth_rules/auth_rule.rbi +++ b/rbi/lithic/models/auth_rules/auth_rule.rbi @@ -85,6 +85,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. sig { returns(Lithic::AuthRules::AuthRule::Type::TaggedSymbol) } attr_accessor :type @@ -167,6 +169,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. type:, # Account tokens to which the Auth Rule does not apply. excluded_account_tokens: nil, @@ -517,6 +521,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. module Type extend Lithic::Internal::Type::Enum @@ -549,6 +555,7 @@ module Lithic :TYPESCRIPT_CODE, Lithic::AuthRules::AuthRule::Type::TaggedSymbol ) + OTHER = T.let(:OTHER, Lithic::AuthRules::AuthRule::Type::TaggedSymbol) sig do override.returns( diff --git a/rbi/lithic/models/auth_rules/v2_create_params.rbi b/rbi/lithic/models/auth_rules/v2_create_params.rbi index 8e27fedf..5f99fa5a 100644 --- a/rbi/lithic/models/auth_rules/v2_create_params.rbi +++ b/rbi/lithic/models/auth_rules/v2_create_params.rbi @@ -109,6 +109,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. sig do returns( Lithic::AuthRules::V2CreateParams::Body::AccountLevelRule::Type::OrSymbol @@ -187,6 +189,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. type:, # Account tokens to which the Auth Rule applies. account_tokens: nil, @@ -275,6 +279,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. module Type extend Lithic::Internal::Type::Enum @@ -312,6 +318,11 @@ module Lithic :TYPESCRIPT_CODE, Lithic::AuthRules::V2CreateParams::Body::AccountLevelRule::Type::TaggedSymbol ) + OTHER = + T.let( + :OTHER, + Lithic::AuthRules::V2CreateParams::Body::AccountLevelRule::Type::TaggedSymbol + ) sig do override.returns( @@ -373,6 +384,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. sig do returns( Lithic::AuthRules::V2CreateParams::Body::CardLevelRule::Type::OrSymbol @@ -438,6 +451,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. type:, # The event stream during which the rule will be evaluated. event_stream: nil, @@ -521,6 +536,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. module Type extend Lithic::Internal::Type::Enum @@ -558,6 +575,11 @@ module Lithic :TYPESCRIPT_CODE, Lithic::AuthRules::V2CreateParams::Body::CardLevelRule::Type::TaggedSymbol ) + OTHER = + T.let( + :OTHER, + Lithic::AuthRules::V2CreateParams::Body::CardLevelRule::Type::TaggedSymbol + ) sig do override.returns( @@ -619,6 +641,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. sig do returns( Lithic::AuthRules::V2CreateParams::Body::ProgramLevelRule::Type::OrSymbol @@ -710,6 +734,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. type:, # The event stream during which the rule will be evaluated. event_stream: nil, @@ -802,6 +828,8 @@ module Lithic # - `TYPESCRIPT_CODE`: AUTHORIZATION, THREE_DS_AUTHENTICATION, TOKENIZATION, # ACH_CREDIT_RECEIPT, ACH_DEBIT_RECEIPT, CARD_TRANSACTION_UPDATE, or # ACH_PAYMENT_UPDATE event stream. + # - `OTHER`: A rule whose type is not exposed through this API. Rules of this type + # are read-only; `OTHER` cannot be used when creating a rule. module Type extend Lithic::Internal::Type::Enum @@ -839,6 +867,11 @@ module Lithic :TYPESCRIPT_CODE, Lithic::AuthRules::V2CreateParams::Body::ProgramLevelRule::Type::TaggedSymbol ) + OTHER = + T.let( + :OTHER, + Lithic::AuthRules::V2CreateParams::Body::ProgramLevelRule::Type::TaggedSymbol + ) sig do override.returns( diff --git a/sig/lithic/models/auth_rules/auth_rule.rbs b/sig/lithic/models/auth_rules/auth_rule.rbs index 276741ca..47ba813d 100644 --- a/sig/lithic/models/auth_rules/auth_rule.rbs +++ b/sig/lithic/models/auth_rules/auth_rule.rbs @@ -218,6 +218,7 @@ module Lithic | :MERCHANT_LOCK | :CONDITIONAL_ACTION | :TYPESCRIPT_CODE + | :OTHER module Type extend Lithic::Internal::Type::Enum @@ -227,6 +228,7 @@ module Lithic MERCHANT_LOCK: :MERCHANT_LOCK CONDITIONAL_ACTION: :CONDITIONAL_ACTION TYPESCRIPT_CODE: :TYPESCRIPT_CODE + OTHER: :OTHER def self?.values: -> ::Array[Lithic::Models::AuthRules::AuthRule::type_] end diff --git a/sig/lithic/models/auth_rules/v2_create_params.rbs b/sig/lithic/models/auth_rules/v2_create_params.rbs index c31a0584..1d36c954 100644 --- a/sig/lithic/models/auth_rules/v2_create_params.rbs +++ b/sig/lithic/models/auth_rules/v2_create_params.rbs @@ -103,6 +103,7 @@ module Lithic | :MERCHANT_LOCK | :CONDITIONAL_ACTION | :TYPESCRIPT_CODE + | :OTHER module Type extend Lithic::Internal::Type::Enum @@ -112,6 +113,7 @@ module Lithic MERCHANT_LOCK: :MERCHANT_LOCK CONDITIONAL_ACTION: :CONDITIONAL_ACTION TYPESCRIPT_CODE: :TYPESCRIPT_CODE + OTHER: :OTHER def self?.values: -> ::Array[Lithic::Models::AuthRules::V2CreateParams::Body::AccountLevelRule::type_] end @@ -182,6 +184,7 @@ module Lithic | :MERCHANT_LOCK | :CONDITIONAL_ACTION | :TYPESCRIPT_CODE + | :OTHER module Type extend Lithic::Internal::Type::Enum @@ -191,6 +194,7 @@ module Lithic MERCHANT_LOCK: :MERCHANT_LOCK CONDITIONAL_ACTION: :CONDITIONAL_ACTION TYPESCRIPT_CODE: :TYPESCRIPT_CODE + OTHER: :OTHER def self?.values: -> ::Array[Lithic::Models::AuthRules::V2CreateParams::Body::CardLevelRule::type_] end @@ -284,6 +288,7 @@ module Lithic | :MERCHANT_LOCK | :CONDITIONAL_ACTION | :TYPESCRIPT_CODE + | :OTHER module Type extend Lithic::Internal::Type::Enum @@ -293,6 +298,7 @@ module Lithic MERCHANT_LOCK: :MERCHANT_LOCK CONDITIONAL_ACTION: :CONDITIONAL_ACTION TYPESCRIPT_CODE: :TYPESCRIPT_CODE + OTHER: :OTHER def self?.values: -> ::Array[Lithic::Models::AuthRules::V2CreateParams::Body::ProgramLevelRule::type_] end From 518aebb0cf94cbc0b1ca1ef85a94a71c5bf1983e Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 3 Sep 2026 16:13:35 +0000 Subject: [PATCH 02/14] feat(api): add EXTERNAL_STABLECOIN category and events to payment resources --- .stats.yml | 4 +-- .../models/account_activity_list_params.rb | 1 + .../models/account_activity_list_response.rb | 1 + ..._activity_retrieve_transaction_response.rb | 1 + lib/lithic/models/external_payment.rb | 6 ++++ .../models/external_payment_create_params.rb | 1 + .../models/external_payment_list_params.rb | 1 + .../statements/statement_line_items.rb | 6 ++++ lib/lithic/models/financial_event.rb | 5 ++++ lib/lithic/models/payment.rb | 1 + .../models/account_activity_list_params.rbi | 5 ++++ .../models/account_activity_list_response.rbi | 5 ++++ ...activity_retrieve_transaction_response.rbi | 5 ++++ rbi/lithic/models/external_payment.rbi | 30 +++++++++++++++++++ .../models/external_payment_create_params.rbi | 5 ++++ .../models/external_payment_list_params.rbi | 5 ++++ .../statements/statement_line_items.rbi | 30 +++++++++++++++++++ rbi/lithic/models/financial_event.rbi | 25 ++++++++++++++++ rbi/lithic/models/payment.rbi | 2 ++ .../models/account_activity_list_params.rbs | 2 ++ .../models/account_activity_list_response.rbs | 2 ++ ...activity_retrieve_transaction_response.rbs | 2 ++ sig/lithic/models/external_payment.rbs | 12 ++++++++ .../models/external_payment_create_params.rbs | 2 ++ .../models/external_payment_list_params.rbs | 2 ++ .../statements/statement_line_items.rbs | 12 ++++++++ sig/lithic/models/financial_event.rbs | 10 +++++++ sig/lithic/models/payment.rbs | 2 ++ 28 files changed, 183 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index 9326df23..36e76ee0 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 216 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-9a4064ca9be1efe3e33d922cae77a5d186b6a0119ef1d3601b5ded1447feb7f7.yml -openapi_spec_hash: bff457821129b2eb4fc5150e23efa197 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-61d6a4ff8361065995b3a743d6034b7deb3d307e3f3d0c9ef24010dd1b71d692.yml +openapi_spec_hash: 736b5c82d6b4a14788140fe05e0fbc30 config_hash: 27fa50e251754c8982e3dc615ef6da41 diff --git a/lib/lithic/models/account_activity_list_params.rb b/lib/lithic/models/account_activity_list_params.rb index 5465acda..4697e79d 100644 --- a/lib/lithic/models/account_activity_list_params.rb +++ b/lib/lithic/models/account_activity_list_params.rb @@ -123,6 +123,7 @@ module Category EXTERNAL_CHECK = :EXTERNAL_CHECK EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW EXTERNAL_RTP = :EXTERNAL_RTP + EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER EXTERNAL_WIRE = :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT = :MANAGEMENT_ADJUSTMENT diff --git a/lib/lithic/models/account_activity_list_response.rb b/lib/lithic/models/account_activity_list_response.rb index 5572dd54..e9f4e0e3 100644 --- a/lib/lithic/models/account_activity_list_response.rb +++ b/lib/lithic/models/account_activity_list_response.rb @@ -162,6 +162,7 @@ module Category EXTERNAL_CHECK = :EXTERNAL_CHECK EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW EXTERNAL_RTP = :EXTERNAL_RTP + EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER EXTERNAL_WIRE = :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT = :MANAGEMENT_ADJUSTMENT diff --git a/lib/lithic/models/account_activity_retrieve_transaction_response.rb b/lib/lithic/models/account_activity_retrieve_transaction_response.rb index 86cd3c86..e39310bd 100644 --- a/lib/lithic/models/account_activity_retrieve_transaction_response.rb +++ b/lib/lithic/models/account_activity_retrieve_transaction_response.rb @@ -165,6 +165,7 @@ module Category EXTERNAL_CHECK = :EXTERNAL_CHECK EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW EXTERNAL_RTP = :EXTERNAL_RTP + EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER EXTERNAL_WIRE = :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT = :MANAGEMENT_ADJUSTMENT diff --git a/lib/lithic/models/external_payment.rb b/lib/lithic/models/external_payment.rb index f9b90b25..754b904e 100644 --- a/lib/lithic/models/external_payment.rb +++ b/lib/lithic/models/external_payment.rb @@ -134,6 +134,7 @@ module Category EXTERNAL_CHECK = :EXTERNAL_CHECK EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW EXTERNAL_RTP = :EXTERNAL_RTP + EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER # @!method self.values @@ -247,6 +248,11 @@ module Type EXTERNAL_RTP_SETTLED = :EXTERNAL_RTP_SETTLED EXTERNAL_RTP_REVERSED = :EXTERNAL_RTP_REVERSED EXTERNAL_RTP_RELEASED = :EXTERNAL_RTP_RELEASED + EXTERNAL_STABLECOIN_INITIATED = :EXTERNAL_STABLECOIN_INITIATED + EXTERNAL_STABLECOIN_CANCELED = :EXTERNAL_STABLECOIN_CANCELED + EXTERNAL_STABLECOIN_SETTLED = :EXTERNAL_STABLECOIN_SETTLED + EXTERNAL_STABLECOIN_REVERSED = :EXTERNAL_STABLECOIN_REVERSED + EXTERNAL_STABLECOIN_RELEASED = :EXTERNAL_STABLECOIN_RELEASED # @!method self.values # @return [Array] diff --git a/lib/lithic/models/external_payment_create_params.rb b/lib/lithic/models/external_payment_create_params.rb index 7adb232f..be134509 100644 --- a/lib/lithic/models/external_payment_create_params.rb +++ b/lib/lithic/models/external_payment_create_params.rb @@ -86,6 +86,7 @@ module Category EXTERNAL_CHECK = :EXTERNAL_CHECK EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW EXTERNAL_RTP = :EXTERNAL_RTP + EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER # @!method self.values diff --git a/lib/lithic/models/external_payment_list_params.rb b/lib/lithic/models/external_payment_list_params.rb index 980f3735..f3a00908 100644 --- a/lib/lithic/models/external_payment_list_params.rb +++ b/lib/lithic/models/external_payment_list_params.rb @@ -106,6 +106,7 @@ module Category EXTERNAL_CHECK = :EXTERNAL_CHECK EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW EXTERNAL_RTP = :EXTERNAL_RTP + EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER # @!method self.values diff --git a/lib/lithic/models/financial_accounts/statements/statement_line_items.rb b/lib/lithic/models/financial_accounts/statements/statement_line_items.rb index 5023e2b2..9ac87c6e 100644 --- a/lib/lithic/models/financial_accounts/statements/statement_line_items.rb +++ b/lib/lithic/models/financial_accounts/statements/statement_line_items.rb @@ -162,6 +162,7 @@ module Category EXTERNAL_CHECK = :EXTERNAL_CHECK EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW EXTERNAL_RTP = :EXTERNAL_RTP + EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER EXTERNAL_WIRE = :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT = :MANAGEMENT_ADJUSTMENT @@ -234,6 +235,11 @@ module EventType EXTERNAL_RTP_RELEASED = :EXTERNAL_RTP_RELEASED EXTERNAL_RTP_REVERSED = :EXTERNAL_RTP_REVERSED EXTERNAL_RTP_SETTLED = :EXTERNAL_RTP_SETTLED + EXTERNAL_STABLECOIN_CANCELED = :EXTERNAL_STABLECOIN_CANCELED + EXTERNAL_STABLECOIN_INITIATED = :EXTERNAL_STABLECOIN_INITIATED + EXTERNAL_STABLECOIN_RELEASED = :EXTERNAL_STABLECOIN_RELEASED + EXTERNAL_STABLECOIN_REVERSED = :EXTERNAL_STABLECOIN_REVERSED + EXTERNAL_STABLECOIN_SETTLED = :EXTERNAL_STABLECOIN_SETTLED EXTERNAL_TRANSFER_CANCELED = :EXTERNAL_TRANSFER_CANCELED EXTERNAL_TRANSFER_INITIATED = :EXTERNAL_TRANSFER_INITIATED EXTERNAL_TRANSFER_RELEASED = :EXTERNAL_TRANSFER_RELEASED diff --git a/lib/lithic/models/financial_event.rb b/lib/lithic/models/financial_event.rb index 1e111999..b94152ef 100644 --- a/lib/lithic/models/financial_event.rb +++ b/lib/lithic/models/financial_event.rb @@ -121,6 +121,11 @@ module Type EXTERNAL_RTP_RELEASED = :EXTERNAL_RTP_RELEASED EXTERNAL_RTP_REVERSED = :EXTERNAL_RTP_REVERSED EXTERNAL_RTP_SETTLED = :EXTERNAL_RTP_SETTLED + EXTERNAL_STABLECOIN_CANCELED = :EXTERNAL_STABLECOIN_CANCELED + EXTERNAL_STABLECOIN_INITIATED = :EXTERNAL_STABLECOIN_INITIATED + EXTERNAL_STABLECOIN_RELEASED = :EXTERNAL_STABLECOIN_RELEASED + EXTERNAL_STABLECOIN_REVERSED = :EXTERNAL_STABLECOIN_REVERSED + EXTERNAL_STABLECOIN_SETTLED = :EXTERNAL_STABLECOIN_SETTLED EXTERNAL_TRANSFER_CANCELED = :EXTERNAL_TRANSFER_CANCELED EXTERNAL_TRANSFER_INITIATED = :EXTERNAL_TRANSFER_INITIATED EXTERNAL_TRANSFER_RELEASED = :EXTERNAL_TRANSFER_RELEASED diff --git a/lib/lithic/models/payment.rb b/lib/lithic/models/payment.rb index 94af119b..cd229382 100644 --- a/lib/lithic/models/payment.rb +++ b/lib/lithic/models/payment.rb @@ -222,6 +222,7 @@ module Category EXTERNAL_CHECK = :EXTERNAL_CHECK EXTERNAL_FEDNOW = :EXTERNAL_FEDNOW EXTERNAL_RTP = :EXTERNAL_RTP + EXTERNAL_STABLECOIN = :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER = :EXTERNAL_TRANSFER EXTERNAL_WIRE = :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT = :MANAGEMENT_ADJUSTMENT diff --git a/rbi/lithic/models/account_activity_list_params.rbi b/rbi/lithic/models/account_activity_list_params.rbi index a137b151..3d9c2756 100644 --- a/rbi/lithic/models/account_activity_list_params.rbi +++ b/rbi/lithic/models/account_activity_list_params.rbi @@ -250,6 +250,11 @@ module Lithic :EXTERNAL_RTP, Lithic::AccountActivityListParams::Category::TaggedSymbol ) + EXTERNAL_STABLECOIN = + T.let( + :EXTERNAL_STABLECOIN, + Lithic::AccountActivityListParams::Category::TaggedSymbol + ) EXTERNAL_TRANSFER = T.let( :EXTERNAL_TRANSFER, diff --git a/rbi/lithic/models/account_activity_list_response.rbi b/rbi/lithic/models/account_activity_list_response.rbi index 0b5b8a00..64734d2f 100644 --- a/rbi/lithic/models/account_activity_list_response.rbi +++ b/rbi/lithic/models/account_activity_list_response.rbi @@ -256,6 +256,11 @@ module Lithic :EXTERNAL_RTP, Lithic::Models::AccountActivityListResponse::Internal::Category::TaggedSymbol ) + EXTERNAL_STABLECOIN = + T.let( + :EXTERNAL_STABLECOIN, + Lithic::Models::AccountActivityListResponse::Internal::Category::TaggedSymbol + ) EXTERNAL_TRANSFER = T.let( :EXTERNAL_TRANSFER, diff --git a/rbi/lithic/models/account_activity_retrieve_transaction_response.rbi b/rbi/lithic/models/account_activity_retrieve_transaction_response.rbi index 564e8f49..c894d16e 100644 --- a/rbi/lithic/models/account_activity_retrieve_transaction_response.rbi +++ b/rbi/lithic/models/account_activity_retrieve_transaction_response.rbi @@ -256,6 +256,11 @@ module Lithic :EXTERNAL_RTP, Lithic::Models::AccountActivityRetrieveTransactionResponse::Internal::Category::TaggedSymbol ) + EXTERNAL_STABLECOIN = + T.let( + :EXTERNAL_STABLECOIN, + Lithic::Models::AccountActivityRetrieveTransactionResponse::Internal::Category::TaggedSymbol + ) EXTERNAL_TRANSFER = T.let( :EXTERNAL_TRANSFER, diff --git a/rbi/lithic/models/external_payment.rbi b/rbi/lithic/models/external_payment.rbi index 7714279a..fa95471a 100644 --- a/rbi/lithic/models/external_payment.rbi +++ b/rbi/lithic/models/external_payment.rbi @@ -207,6 +207,11 @@ module Lithic ) EXTERNAL_RTP = T.let(:EXTERNAL_RTP, Lithic::ExternalPayment::Category::TaggedSymbol) + EXTERNAL_STABLECOIN = + T.let( + :EXTERNAL_STABLECOIN, + Lithic::ExternalPayment::Category::TaggedSymbol + ) EXTERNAL_TRANSFER = T.let( :EXTERNAL_TRANSFER, @@ -522,6 +527,31 @@ module Lithic :EXTERNAL_RTP_RELEASED, Lithic::ExternalPayment::Event::Type::TaggedSymbol ) + EXTERNAL_STABLECOIN_INITIATED = + T.let( + :EXTERNAL_STABLECOIN_INITIATED, + Lithic::ExternalPayment::Event::Type::TaggedSymbol + ) + EXTERNAL_STABLECOIN_CANCELED = + T.let( + :EXTERNAL_STABLECOIN_CANCELED, + Lithic::ExternalPayment::Event::Type::TaggedSymbol + ) + EXTERNAL_STABLECOIN_SETTLED = + T.let( + :EXTERNAL_STABLECOIN_SETTLED, + Lithic::ExternalPayment::Event::Type::TaggedSymbol + ) + EXTERNAL_STABLECOIN_REVERSED = + T.let( + :EXTERNAL_STABLECOIN_REVERSED, + Lithic::ExternalPayment::Event::Type::TaggedSymbol + ) + EXTERNAL_STABLECOIN_RELEASED = + T.let( + :EXTERNAL_STABLECOIN_RELEASED, + Lithic::ExternalPayment::Event::Type::TaggedSymbol + ) sig do override.returns( diff --git a/rbi/lithic/models/external_payment_create_params.rbi b/rbi/lithic/models/external_payment_create_params.rbi index 68333728..12049ea6 100644 --- a/rbi/lithic/models/external_payment_create_params.rbi +++ b/rbi/lithic/models/external_payment_create_params.rbi @@ -149,6 +149,11 @@ module Lithic :EXTERNAL_RTP, Lithic::ExternalPaymentCreateParams::Category::TaggedSymbol ) + EXTERNAL_STABLECOIN = + T.let( + :EXTERNAL_STABLECOIN, + Lithic::ExternalPaymentCreateParams::Category::TaggedSymbol + ) EXTERNAL_TRANSFER = T.let( :EXTERNAL_TRANSFER, diff --git a/rbi/lithic/models/external_payment_list_params.rbi b/rbi/lithic/models/external_payment_list_params.rbi index 84830e53..e9a99b30 100644 --- a/rbi/lithic/models/external_payment_list_params.rbi +++ b/rbi/lithic/models/external_payment_list_params.rbi @@ -200,6 +200,11 @@ module Lithic :EXTERNAL_RTP, Lithic::ExternalPaymentListParams::Category::TaggedSymbol ) + EXTERNAL_STABLECOIN = + T.let( + :EXTERNAL_STABLECOIN, + Lithic::ExternalPaymentListParams::Category::TaggedSymbol + ) EXTERNAL_TRANSFER = T.let( :EXTERNAL_TRANSFER, diff --git a/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi b/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi index d170987e..b4811bed 100644 --- a/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi +++ b/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi @@ -293,6 +293,11 @@ module Lithic :EXTERNAL_RTP, Lithic::FinancialAccounts::Statements::StatementLineItems::Data::Category::TaggedSymbol ) + EXTERNAL_STABLECOIN = + T.let( + :EXTERNAL_STABLECOIN, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::Category::TaggedSymbol + ) EXTERNAL_TRANSFER = T.let( :EXTERNAL_TRANSFER, @@ -632,6 +637,31 @@ module Lithic :EXTERNAL_RTP_SETTLED, Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol ) + EXTERNAL_STABLECOIN_CANCELED = + T.let( + :EXTERNAL_STABLECOIN_CANCELED, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) + EXTERNAL_STABLECOIN_INITIATED = + T.let( + :EXTERNAL_STABLECOIN_INITIATED, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) + EXTERNAL_STABLECOIN_RELEASED = + T.let( + :EXTERNAL_STABLECOIN_RELEASED, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) + EXTERNAL_STABLECOIN_REVERSED = + T.let( + :EXTERNAL_STABLECOIN_REVERSED, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) + EXTERNAL_STABLECOIN_SETTLED = + T.let( + :EXTERNAL_STABLECOIN_SETTLED, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) EXTERNAL_TRANSFER_CANCELED = T.let( :EXTERNAL_TRANSFER_CANCELED, diff --git a/rbi/lithic/models/financial_event.rbi b/rbi/lithic/models/financial_event.rbi index 7de815e5..222e493d 100644 --- a/rbi/lithic/models/financial_event.rbi +++ b/rbi/lithic/models/financial_event.rbi @@ -341,6 +341,31 @@ module Lithic :EXTERNAL_RTP_SETTLED, Lithic::FinancialEvent::Type::TaggedSymbol ) + EXTERNAL_STABLECOIN_CANCELED = + T.let( + :EXTERNAL_STABLECOIN_CANCELED, + Lithic::FinancialEvent::Type::TaggedSymbol + ) + EXTERNAL_STABLECOIN_INITIATED = + T.let( + :EXTERNAL_STABLECOIN_INITIATED, + Lithic::FinancialEvent::Type::TaggedSymbol + ) + EXTERNAL_STABLECOIN_RELEASED = + T.let( + :EXTERNAL_STABLECOIN_RELEASED, + Lithic::FinancialEvent::Type::TaggedSymbol + ) + EXTERNAL_STABLECOIN_REVERSED = + T.let( + :EXTERNAL_STABLECOIN_REVERSED, + Lithic::FinancialEvent::Type::TaggedSymbol + ) + EXTERNAL_STABLECOIN_SETTLED = + T.let( + :EXTERNAL_STABLECOIN_SETTLED, + Lithic::FinancialEvent::Type::TaggedSymbol + ) EXTERNAL_TRANSFER_CANCELED = T.let( :EXTERNAL_TRANSFER_CANCELED, diff --git a/rbi/lithic/models/payment.rbi b/rbi/lithic/models/payment.rbi index 696b7eb9..587b8b95 100644 --- a/rbi/lithic/models/payment.rbi +++ b/rbi/lithic/models/payment.rbi @@ -267,6 +267,8 @@ module Lithic T.let(:EXTERNAL_FEDNOW, Lithic::Payment::Category::TaggedSymbol) EXTERNAL_RTP = T.let(:EXTERNAL_RTP, Lithic::Payment::Category::TaggedSymbol) + EXTERNAL_STABLECOIN = + T.let(:EXTERNAL_STABLECOIN, Lithic::Payment::Category::TaggedSymbol) EXTERNAL_TRANSFER = T.let(:EXTERNAL_TRANSFER, Lithic::Payment::Category::TaggedSymbol) EXTERNAL_WIRE = diff --git a/sig/lithic/models/account_activity_list_params.rbs b/sig/lithic/models/account_activity_list_params.rbs index b099fb77..a6443699 100644 --- a/sig/lithic/models/account_activity_list_params.rbs +++ b/sig/lithic/models/account_activity_list_params.rbs @@ -115,6 +115,7 @@ module Lithic | :EXTERNAL_CHECK | :EXTERNAL_FEDNOW | :EXTERNAL_RTP + | :EXTERNAL_STABLECOIN | :EXTERNAL_TRANSFER | :EXTERNAL_WIRE | :MANAGEMENT_ADJUSTMENT @@ -143,6 +144,7 @@ module Lithic EXTERNAL_CHECK: :EXTERNAL_CHECK EXTERNAL_FEDNOW: :EXTERNAL_FEDNOW EXTERNAL_RTP: :EXTERNAL_RTP + EXTERNAL_STABLECOIN: :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER: :EXTERNAL_TRANSFER EXTERNAL_WIRE: :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT: :MANAGEMENT_ADJUSTMENT diff --git a/sig/lithic/models/account_activity_list_response.rbs b/sig/lithic/models/account_activity_list_response.rbs index b2fb3ed1..9e14ce1f 100644 --- a/sig/lithic/models/account_activity_list_response.rbs +++ b/sig/lithic/models/account_activity_list_response.rbs @@ -103,6 +103,7 @@ module Lithic | :EXTERNAL_CHECK | :EXTERNAL_FEDNOW | :EXTERNAL_RTP + | :EXTERNAL_STABLECOIN | :EXTERNAL_TRANSFER | :EXTERNAL_WIRE | :MANAGEMENT_ADJUSTMENT @@ -131,6 +132,7 @@ module Lithic EXTERNAL_CHECK: :EXTERNAL_CHECK EXTERNAL_FEDNOW: :EXTERNAL_FEDNOW EXTERNAL_RTP: :EXTERNAL_RTP + EXTERNAL_STABLECOIN: :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER: :EXTERNAL_TRANSFER EXTERNAL_WIRE: :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT: :MANAGEMENT_ADJUSTMENT diff --git a/sig/lithic/models/account_activity_retrieve_transaction_response.rbs b/sig/lithic/models/account_activity_retrieve_transaction_response.rbs index 6003cc68..a229b011 100644 --- a/sig/lithic/models/account_activity_retrieve_transaction_response.rbs +++ b/sig/lithic/models/account_activity_retrieve_transaction_response.rbs @@ -103,6 +103,7 @@ module Lithic | :EXTERNAL_CHECK | :EXTERNAL_FEDNOW | :EXTERNAL_RTP + | :EXTERNAL_STABLECOIN | :EXTERNAL_TRANSFER | :EXTERNAL_WIRE | :MANAGEMENT_ADJUSTMENT @@ -131,6 +132,7 @@ module Lithic EXTERNAL_CHECK: :EXTERNAL_CHECK EXTERNAL_FEDNOW: :EXTERNAL_FEDNOW EXTERNAL_RTP: :EXTERNAL_RTP + EXTERNAL_STABLECOIN: :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER: :EXTERNAL_TRANSFER EXTERNAL_WIRE: :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT: :MANAGEMENT_ADJUSTMENT diff --git a/sig/lithic/models/external_payment.rbs b/sig/lithic/models/external_payment.rbs index 8dc7e553..87e60cf1 100644 --- a/sig/lithic/models/external_payment.rbs +++ b/sig/lithic/models/external_payment.rbs @@ -131,6 +131,7 @@ module Lithic | :EXTERNAL_CHECK | :EXTERNAL_FEDNOW | :EXTERNAL_RTP + | :EXTERNAL_STABLECOIN | :EXTERNAL_TRANSFER module Category @@ -141,6 +142,7 @@ module Lithic EXTERNAL_CHECK: :EXTERNAL_CHECK EXTERNAL_FEDNOW: :EXTERNAL_FEDNOW EXTERNAL_RTP: :EXTERNAL_RTP + EXTERNAL_STABLECOIN: :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER: :EXTERNAL_TRANSFER def self?.values: -> ::Array[Lithic::Models::ExternalPayment::category] @@ -250,6 +252,11 @@ module Lithic | :EXTERNAL_RTP_SETTLED | :EXTERNAL_RTP_REVERSED | :EXTERNAL_RTP_RELEASED + | :EXTERNAL_STABLECOIN_INITIATED + | :EXTERNAL_STABLECOIN_CANCELED + | :EXTERNAL_STABLECOIN_SETTLED + | :EXTERNAL_STABLECOIN_REVERSED + | :EXTERNAL_STABLECOIN_RELEASED module Type extend Lithic::Internal::Type::Enum @@ -284,6 +291,11 @@ module Lithic EXTERNAL_RTP_SETTLED: :EXTERNAL_RTP_SETTLED EXTERNAL_RTP_REVERSED: :EXTERNAL_RTP_REVERSED EXTERNAL_RTP_RELEASED: :EXTERNAL_RTP_RELEASED + EXTERNAL_STABLECOIN_INITIATED: :EXTERNAL_STABLECOIN_INITIATED + EXTERNAL_STABLECOIN_CANCELED: :EXTERNAL_STABLECOIN_CANCELED + EXTERNAL_STABLECOIN_SETTLED: :EXTERNAL_STABLECOIN_SETTLED + EXTERNAL_STABLECOIN_REVERSED: :EXTERNAL_STABLECOIN_REVERSED + EXTERNAL_STABLECOIN_RELEASED: :EXTERNAL_STABLECOIN_RELEASED def self?.values: -> ::Array[Lithic::Models::ExternalPayment::Event::type_] end diff --git a/sig/lithic/models/external_payment_create_params.rbs b/sig/lithic/models/external_payment_create_params.rbs index a2204135..9972ba84 100644 --- a/sig/lithic/models/external_payment_create_params.rbs +++ b/sig/lithic/models/external_payment_create_params.rbs @@ -78,6 +78,7 @@ module Lithic | :EXTERNAL_CHECK | :EXTERNAL_FEDNOW | :EXTERNAL_RTP + | :EXTERNAL_STABLECOIN | :EXTERNAL_TRANSFER module Category @@ -88,6 +89,7 @@ module Lithic EXTERNAL_CHECK: :EXTERNAL_CHECK EXTERNAL_FEDNOW: :EXTERNAL_FEDNOW EXTERNAL_RTP: :EXTERNAL_RTP + EXTERNAL_STABLECOIN: :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER: :EXTERNAL_TRANSFER def self?.values: -> ::Array[Lithic::Models::ExternalPaymentCreateParams::category] diff --git a/sig/lithic/models/external_payment_list_params.rbs b/sig/lithic/models/external_payment_list_params.rbs index 43ed0b8f..50760b51 100644 --- a/sig/lithic/models/external_payment_list_params.rbs +++ b/sig/lithic/models/external_payment_list_params.rbs @@ -99,6 +99,7 @@ module Lithic | :EXTERNAL_CHECK | :EXTERNAL_FEDNOW | :EXTERNAL_RTP + | :EXTERNAL_STABLECOIN | :EXTERNAL_TRANSFER module Category @@ -109,6 +110,7 @@ module Lithic EXTERNAL_CHECK: :EXTERNAL_CHECK EXTERNAL_FEDNOW: :EXTERNAL_FEDNOW EXTERNAL_RTP: :EXTERNAL_RTP + EXTERNAL_STABLECOIN: :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER: :EXTERNAL_TRANSFER def self?.values: -> ::Array[Lithic::Models::ExternalPaymentListParams::category] diff --git a/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs b/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs index fb3bac8e..bf0dc455 100644 --- a/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs +++ b/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs @@ -123,6 +123,7 @@ module Lithic | :EXTERNAL_CHECK | :EXTERNAL_FEDNOW | :EXTERNAL_RTP + | :EXTERNAL_STABLECOIN | :EXTERNAL_TRANSFER | :EXTERNAL_WIRE | :MANAGEMENT_ADJUSTMENT @@ -151,6 +152,7 @@ module Lithic EXTERNAL_CHECK: :EXTERNAL_CHECK EXTERNAL_FEDNOW: :EXTERNAL_FEDNOW EXTERNAL_RTP: :EXTERNAL_RTP + EXTERNAL_STABLECOIN: :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER: :EXTERNAL_TRANSFER EXTERNAL_WIRE: :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT: :MANAGEMENT_ADJUSTMENT @@ -219,6 +221,11 @@ module Lithic | :EXTERNAL_RTP_RELEASED | :EXTERNAL_RTP_REVERSED | :EXTERNAL_RTP_SETTLED + | :EXTERNAL_STABLECOIN_CANCELED + | :EXTERNAL_STABLECOIN_INITIATED + | :EXTERNAL_STABLECOIN_RELEASED + | :EXTERNAL_STABLECOIN_REVERSED + | :EXTERNAL_STABLECOIN_SETTLED | :EXTERNAL_TRANSFER_CANCELED | :EXTERNAL_TRANSFER_INITIATED | :EXTERNAL_TRANSFER_RELEASED @@ -319,6 +326,11 @@ module Lithic EXTERNAL_RTP_RELEASED: :EXTERNAL_RTP_RELEASED EXTERNAL_RTP_REVERSED: :EXTERNAL_RTP_REVERSED EXTERNAL_RTP_SETTLED: :EXTERNAL_RTP_SETTLED + EXTERNAL_STABLECOIN_CANCELED: :EXTERNAL_STABLECOIN_CANCELED + EXTERNAL_STABLECOIN_INITIATED: :EXTERNAL_STABLECOIN_INITIATED + EXTERNAL_STABLECOIN_RELEASED: :EXTERNAL_STABLECOIN_RELEASED + EXTERNAL_STABLECOIN_REVERSED: :EXTERNAL_STABLECOIN_REVERSED + EXTERNAL_STABLECOIN_SETTLED: :EXTERNAL_STABLECOIN_SETTLED EXTERNAL_TRANSFER_CANCELED: :EXTERNAL_TRANSFER_CANCELED EXTERNAL_TRANSFER_INITIATED: :EXTERNAL_TRANSFER_INITIATED EXTERNAL_TRANSFER_RELEASED: :EXTERNAL_TRANSFER_RELEASED diff --git a/sig/lithic/models/financial_event.rbs b/sig/lithic/models/financial_event.rbs index a5f3e9ca..262d4d38 100644 --- a/sig/lithic/models/financial_event.rbs +++ b/sig/lithic/models/financial_event.rbs @@ -115,6 +115,11 @@ module Lithic | :EXTERNAL_RTP_RELEASED | :EXTERNAL_RTP_REVERSED | :EXTERNAL_RTP_SETTLED + | :EXTERNAL_STABLECOIN_CANCELED + | :EXTERNAL_STABLECOIN_INITIATED + | :EXTERNAL_STABLECOIN_RELEASED + | :EXTERNAL_STABLECOIN_REVERSED + | :EXTERNAL_STABLECOIN_SETTLED | :EXTERNAL_TRANSFER_CANCELED | :EXTERNAL_TRANSFER_INITIATED | :EXTERNAL_TRANSFER_RELEASED @@ -215,6 +220,11 @@ module Lithic EXTERNAL_RTP_RELEASED: :EXTERNAL_RTP_RELEASED EXTERNAL_RTP_REVERSED: :EXTERNAL_RTP_REVERSED EXTERNAL_RTP_SETTLED: :EXTERNAL_RTP_SETTLED + EXTERNAL_STABLECOIN_CANCELED: :EXTERNAL_STABLECOIN_CANCELED + EXTERNAL_STABLECOIN_INITIATED: :EXTERNAL_STABLECOIN_INITIATED + EXTERNAL_STABLECOIN_RELEASED: :EXTERNAL_STABLECOIN_RELEASED + EXTERNAL_STABLECOIN_REVERSED: :EXTERNAL_STABLECOIN_REVERSED + EXTERNAL_STABLECOIN_SETTLED: :EXTERNAL_STABLECOIN_SETTLED EXTERNAL_TRANSFER_CANCELED: :EXTERNAL_TRANSFER_CANCELED EXTERNAL_TRANSFER_INITIATED: :EXTERNAL_TRANSFER_INITIATED EXTERNAL_TRANSFER_RELEASED: :EXTERNAL_TRANSFER_RELEASED diff --git a/sig/lithic/models/payment.rbs b/sig/lithic/models/payment.rbs index e4b70200..fd6bf1b6 100644 --- a/sig/lithic/models/payment.rbs +++ b/sig/lithic/models/payment.rbs @@ -154,6 +154,7 @@ module Lithic | :EXTERNAL_CHECK | :EXTERNAL_FEDNOW | :EXTERNAL_RTP + | :EXTERNAL_STABLECOIN | :EXTERNAL_TRANSFER | :EXTERNAL_WIRE | :MANAGEMENT_ADJUSTMENT @@ -182,6 +183,7 @@ module Lithic EXTERNAL_CHECK: :EXTERNAL_CHECK EXTERNAL_FEDNOW: :EXTERNAL_FEDNOW EXTERNAL_RTP: :EXTERNAL_RTP + EXTERNAL_STABLECOIN: :EXTERNAL_STABLECOIN EXTERNAL_TRANSFER: :EXTERNAL_TRANSFER EXTERNAL_WIRE: :EXTERNAL_WIRE MANAGEMENT_ADJUSTMENT: :MANAGEMENT_ADJUSTMENT From 050c7bdd679e3c090c6e1819c0aa3405e3cbfc0c Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 10 Sep 2026 15:53:33 +0000 Subject: [PATCH 03/14] feat: TRE-14429: Document the stablecoin payments endpoint --- .stats.yml | 8 +- lib/lithic.rb | 2 + lib/lithic/models.rb | 2 + .../payment_create_stablecoin_params.rb | 99 +++++++++++ .../payment_create_stablecoin_response.rb | 19 ++ lib/lithic/models/payment_list_params.rb | 1 + lib/lithic/resources/payments.rb | 62 ++++++- rbi/lithic/models.rbi | 2 + .../payment_create_stablecoin_params.rbi | 162 ++++++++++++++++++ .../payment_create_stablecoin_response.rbi | 34 ++++ rbi/lithic/models/payment_list_params.rbi | 2 + rbi/lithic/resources/payments.rbi | 60 ++++++- sig/lithic/models.rbs | 2 + .../payment_create_stablecoin_params.rbs | 84 +++++++++ .../payment_create_stablecoin_response.rbs | 15 ++ sig/lithic/models/payment_list_params.rbs | 3 +- sig/lithic/resources/payments.rbs | 11 ++ test/lithic/resources/payments_test.rb | 14 ++ 18 files changed, 575 insertions(+), 7 deletions(-) create mode 100644 lib/lithic/models/payment_create_stablecoin_params.rb create mode 100644 lib/lithic/models/payment_create_stablecoin_response.rb create mode 100644 rbi/lithic/models/payment_create_stablecoin_params.rbi create mode 100644 rbi/lithic/models/payment_create_stablecoin_response.rbi create mode 100644 sig/lithic/models/payment_create_stablecoin_params.rbs create mode 100644 sig/lithic/models/payment_create_stablecoin_response.rbs diff --git a/.stats.yml b/.stats.yml index 36e76ee0..3bbc4737 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ -configured_endpoints: 216 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-61d6a4ff8361065995b3a743d6034b7deb3d307e3f3d0c9ef24010dd1b71d692.yml -openapi_spec_hash: 736b5c82d6b4a14788140fe05e0fbc30 -config_hash: 27fa50e251754c8982e3dc615ef6da41 +configured_endpoints: 217 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-70147140a7b2043acf622024eb3bde9b04264f8e9a695d4c79b5ee4db1534518.yml +openapi_spec_hash: 7a181cb1cfaaa201143bd9d04a841a2e +config_hash: e95c2dda5d175f9316457e0a84e35dce diff --git a/lib/lithic.rb b/lib/lithic.rb index d7c81541..ec6e7ccb 100644 --- a/lib/lithic.rb +++ b/lib/lithic.rb @@ -383,6 +383,8 @@ require_relative "lithic/models/parsed_webhook_event" require_relative "lithic/models/payment_create_params" require_relative "lithic/models/payment_create_response" +require_relative "lithic/models/payment_create_stablecoin_params" +require_relative "lithic/models/payment_create_stablecoin_response" require_relative "lithic/models/payment_list_params" require_relative "lithic/models/payment_retrieve_params" require_relative "lithic/models/payment_retry_params" diff --git a/lib/lithic/models.rb b/lib/lithic/models.rb index 4dde49d0..2691fcb7 100644 --- a/lib/lithic/models.rb +++ b/lib/lithic/models.rb @@ -475,6 +475,8 @@ module Lithic PaymentCreateParams = Lithic::Models::PaymentCreateParams + PaymentCreateStablecoinParams = Lithic::Models::PaymentCreateStablecoinParams + PaymentListParams = Lithic::Models::PaymentListParams PaymentRetrieveParams = Lithic::Models::PaymentRetrieveParams diff --git a/lib/lithic/models/payment_create_stablecoin_params.rb b/lib/lithic/models/payment_create_stablecoin_params.rb new file mode 100644 index 00000000..951fb397 --- /dev/null +++ b/lib/lithic/models/payment_create_stablecoin_params.rb @@ -0,0 +1,99 @@ +# frozen_string_literal: true + +module Lithic + module Models + # @see Lithic::Resources::Payments#create_stablecoin + class PaymentCreateStablecoinParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + # @!attribute amount + # Payout amount in cents + # + # @return [Integer] + required :amount, Integer + + # @!attribute blockchain_recipient_token + # Token of the blockchain recipient to send the payout to. The recipient must be + # in the `ENABLED` verification state + # + # @return [String] + required :blockchain_recipient_token, String + + # @!attribute financial_account_token + # Token of the financial account the payout is funded from + # + # @return [String] + required :financial_account_token, String + + # @!attribute type + # Direction of the payment. Stablecoin supports payouts only + # + # @return [Symbol, Lithic::Models::PaymentCreateStablecoinParams::Type] + required :type, enum: -> { Lithic::PaymentCreateStablecoinParams::Type } + + # @!attribute token + # Customer-provided token that will serve as an idempotency token. This token will + # become the transaction token + # + # @return [String, nil] + optional :token, String + + # @!attribute hold + # Optional hold to settle when this payout is initiated + # + # @return [Lithic::Models::PaymentCreateStablecoinParams::Hold, nil] + optional :hold, -> { Lithic::PaymentCreateStablecoinParams::Hold } + + # @!attribute memo + # Memo recorded on the payout. Defaults to `Stablecoin payout on ` when + # omitted + # + # @return [String, nil] + optional :memo, String + + # @!method initialize(amount:, blockchain_recipient_token:, financial_account_token:, type:, token: nil, hold: nil, memo: nil, request_options: {}) + # Some parameter documentations has been truncated, see + # {Lithic::Models::PaymentCreateStablecoinParams} for more details. + # + # @param amount [Integer] Payout amount in cents + # + # @param blockchain_recipient_token [String] Token of the blockchain recipient to send the payout to. The recipient must be i + # + # @param financial_account_token [String] Token of the financial account the payout is funded from + # + # @param type [Symbol, Lithic::Models::PaymentCreateStablecoinParams::Type] Direction of the payment. Stablecoin supports payouts only + # + # @param token [String] Customer-provided token that will serve as an idempotency token. This token will + # + # @param hold [Lithic::Models::PaymentCreateStablecoinParams::Hold] Optional hold to settle when this payout is initiated + # + # @param memo [String] Memo recorded on the payout. Defaults to `Stablecoin payout on ` when omi + # + # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}] + + # Direction of the payment. Stablecoin supports payouts only + module Type + extend Lithic::Internal::Type::Enum + + PAYMENT = :PAYMENT + + # @!method self.values + # @return [Array] + end + + class Hold < Lithic::Internal::Type::BaseModel + # @!attribute token + # Token of the hold to settle when this payout is initiated + # + # @return [String] + required :token, String + + # @!method initialize(token:) + # Optional hold to settle when this payout is initiated + # + # @param token [String] Token of the hold to settle when this payout is initiated + end + end + end +end diff --git a/lib/lithic/models/payment_create_stablecoin_response.rb b/lib/lithic/models/payment_create_stablecoin_response.rb new file mode 100644 index 00000000..f1de06c9 --- /dev/null +++ b/lib/lithic/models/payment_create_stablecoin_response.rb @@ -0,0 +1,19 @@ +# frozen_string_literal: true + +module Lithic + module Models + # @see Lithic::Resources::Payments#create_stablecoin + class PaymentCreateStablecoinResponse < Lithic::Models::Payment + # @!attribute balance + # Balance + # + # @return [Lithic::Models::Balance, nil] + optional :balance, -> { Lithic::Balance } + + # @!method initialize(balance: nil) + # Payment transaction + # + # @param balance [Lithic::Models::Balance] Balance + end + end +end diff --git a/lib/lithic/models/payment_list_params.rb b/lib/lithic/models/payment_list_params.rb index 721f43a0..010ea84d 100644 --- a/lib/lithic/models/payment_list_params.rb +++ b/lib/lithic/models/payment_list_params.rb @@ -103,6 +103,7 @@ module Category extend Lithic::Internal::Type::Enum ACH = :ACH + STABLECOIN = :STABLECOIN # @!method self.values # @return [Array] diff --git a/lib/lithic/resources/payments.rb b/lib/lithic/resources/payments.rb index 7f12f251..b20ea1df 100644 --- a/lib/lithic/resources/payments.rb +++ b/lib/lithic/resources/payments.rb @@ -6,7 +6,14 @@ class Payments # Some parameter documentations has been truncated, see # {Lithic::Models::PaymentCreateParams} for more details. # - # Initiates a payment between a financial account and an external bank account. + # Initiates an ACH payment between a financial account and an external bank + # account. + # + # This endpoint originates on the ACH rail only. To send a stablecoin payout, use + # the + # [Create stablecoin payment](https://docs.lithic.com/reference/createstablecoinpayment) + # endpoint. Payments on every rail are read back through + # [List payments](https://docs.lithic.com/reference/searchpayments). # # @overload create(amount:, external_bank_account_token:, financial_account_token:, method_:, method_attributes:, type:, token: nil, hold: nil, memo: nil, user_defined_id: nil, request_options: {}) # @@ -112,6 +119,59 @@ def list(params = {}) ) end + # Some parameter documentations has been truncated, see + # {Lithic::Models::PaymentCreateStablecoinParams} for more details. + # + # Initiates a stablecoin payout from a financial account to a registered + # blockchain recipient. + # + # The recipient must have been registered with + # [Create blockchain recipient](https://docs.lithic.com/reference/createblockchainrecipient) + # and have completed address screening — only a recipient in the `ENABLED` + # verification state can receive a payout. The destination address and chain come + # from the recipient, so they are not supplied here. + # + # Only payouts are initiated through this endpoint. Stablecoin pay-ins are + # credited from on-chain deposits to a financial account's deposit address and are + # not created through the API. Funds are placed on hold when the payout is + # initiated, and a payout that fails on chain reverses that hold. A payout cannot + # be cancelled once it has been submitted on chain. + # + # This endpoint is only available to stablecoin-enabled programs. Contact your + # customer success manager to learn more. + # + # @overload create_stablecoin(amount:, blockchain_recipient_token:, financial_account_token:, type:, token: nil, hold: nil, memo: nil, request_options: {}) + # + # @param amount [Integer] Payout amount in cents + # + # @param blockchain_recipient_token [String] Token of the blockchain recipient to send the payout to. The recipient must be i + # + # @param financial_account_token [String] Token of the financial account the payout is funded from + # + # @param type [Symbol, Lithic::Models::PaymentCreateStablecoinParams::Type] Direction of the payment. Stablecoin supports payouts only + # + # @param token [String] Customer-provided token that will serve as an idempotency token. This token will + # + # @param hold [Lithic::Models::PaymentCreateStablecoinParams::Hold] Optional hold to settle when this payout is initiated + # + # @param memo [String] Memo recorded on the payout. Defaults to `Stablecoin payout on ` when omi + # + # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}, nil] + # + # @return [Lithic::Models::PaymentCreateStablecoinResponse] + # + # @see Lithic::Models::PaymentCreateStablecoinParams + def create_stablecoin(params) + parsed, options = Lithic::PaymentCreateStablecoinParams.dump_request(params) + @client.request( + method: :post, + path: "v1/payments/stablecoin", + body: parsed, + model: Lithic::Models::PaymentCreateStablecoinResponse, + options: options + ) + end + # Retry an origination which has been returned. # # @overload retry_(payment_token, request_options: {}) diff --git a/rbi/lithic/models.rbi b/rbi/lithic/models.rbi index eb73cf11..5eb02609 100644 --- a/rbi/lithic/models.rbi +++ b/rbi/lithic/models.rbi @@ -493,6 +493,8 @@ module Lithic PaymentCreateParams = Lithic::Models::PaymentCreateParams + PaymentCreateStablecoinParams = Lithic::Models::PaymentCreateStablecoinParams + PaymentListParams = Lithic::Models::PaymentListParams PaymentRetrieveParams = Lithic::Models::PaymentRetrieveParams diff --git a/rbi/lithic/models/payment_create_stablecoin_params.rbi b/rbi/lithic/models/payment_create_stablecoin_params.rbi new file mode 100644 index 00000000..f1e6d2db --- /dev/null +++ b/rbi/lithic/models/payment_create_stablecoin_params.rbi @@ -0,0 +1,162 @@ +# typed: strong + +module Lithic + module Models + class PaymentCreateStablecoinParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + OrHash = + T.type_alias do + T.any( + Lithic::PaymentCreateStablecoinParams, + Lithic::Internal::AnyHash + ) + end + + # Payout amount in cents + sig { returns(Integer) } + attr_accessor :amount + + # Token of the blockchain recipient to send the payout to. The recipient must be + # in the `ENABLED` verification state + sig { returns(String) } + attr_accessor :blockchain_recipient_token + + # Token of the financial account the payout is funded from + sig { returns(String) } + attr_accessor :financial_account_token + + # Direction of the payment. Stablecoin supports payouts only + sig { returns(Lithic::PaymentCreateStablecoinParams::Type::OrSymbol) } + attr_accessor :type + + # Customer-provided token that will serve as an idempotency token. This token will + # become the transaction token + sig { returns(T.nilable(String)) } + attr_reader :token + + sig { params(token: String).void } + attr_writer :token + + # Optional hold to settle when this payout is initiated + sig { returns(T.nilable(Lithic::PaymentCreateStablecoinParams::Hold)) } + attr_reader :hold + + sig do + params(hold: Lithic::PaymentCreateStablecoinParams::Hold::OrHash).void + end + attr_writer :hold + + # Memo recorded on the payout. Defaults to `Stablecoin payout on ` when + # omitted + sig { returns(T.nilable(String)) } + attr_reader :memo + + sig { params(memo: String).void } + attr_writer :memo + + sig do + params( + amount: Integer, + blockchain_recipient_token: String, + financial_account_token: String, + type: Lithic::PaymentCreateStablecoinParams::Type::OrSymbol, + token: String, + hold: Lithic::PaymentCreateStablecoinParams::Hold::OrHash, + memo: String, + request_options: Lithic::RequestOptions::OrHash + ).returns(T.attached_class) + end + def self.new( + # Payout amount in cents + amount:, + # Token of the blockchain recipient to send the payout to. The recipient must be + # in the `ENABLED` verification state + blockchain_recipient_token:, + # Token of the financial account the payout is funded from + financial_account_token:, + # Direction of the payment. Stablecoin supports payouts only + type:, + # Customer-provided token that will serve as an idempotency token. This token will + # become the transaction token + token: nil, + # Optional hold to settle when this payout is initiated + hold: nil, + # Memo recorded on the payout. Defaults to `Stablecoin payout on ` when + # omitted + memo: nil, + request_options: {} + ) + end + + sig do + override.returns( + { + amount: Integer, + blockchain_recipient_token: String, + financial_account_token: String, + type: Lithic::PaymentCreateStablecoinParams::Type::OrSymbol, + token: String, + hold: Lithic::PaymentCreateStablecoinParams::Hold, + memo: String, + request_options: Lithic::RequestOptions + } + ) + end + def to_hash + end + + # Direction of the payment. Stablecoin supports payouts only + module Type + extend Lithic::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all(Symbol, Lithic::PaymentCreateStablecoinParams::Type) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + PAYMENT = + T.let( + :PAYMENT, + Lithic::PaymentCreateStablecoinParams::Type::TaggedSymbol + ) + + sig do + override.returns( + T::Array[Lithic::PaymentCreateStablecoinParams::Type::TaggedSymbol] + ) + end + def self.values + end + end + + class Hold < Lithic::Internal::Type::BaseModel + OrHash = + T.type_alias do + T.any( + Lithic::PaymentCreateStablecoinParams::Hold, + Lithic::Internal::AnyHash + ) + end + + # Token of the hold to settle when this payout is initiated + sig { returns(String) } + attr_accessor :token + + # Optional hold to settle when this payout is initiated + sig { params(token: String).returns(T.attached_class) } + def self.new( + # Token of the hold to settle when this payout is initiated + token: + ) + end + + sig { override.returns({ token: String }) } + def to_hash + end + end + end + end +end diff --git a/rbi/lithic/models/payment_create_stablecoin_response.rbi b/rbi/lithic/models/payment_create_stablecoin_response.rbi new file mode 100644 index 00000000..2d406592 --- /dev/null +++ b/rbi/lithic/models/payment_create_stablecoin_response.rbi @@ -0,0 +1,34 @@ +# typed: strong + +module Lithic + module Models + class PaymentCreateStablecoinResponse < Lithic::Models::Payment + OrHash = + T.type_alias do + T.any( + Lithic::Models::PaymentCreateStablecoinResponse, + Lithic::Internal::AnyHash + ) + end + + # Balance + sig { returns(T.nilable(Lithic::Balance)) } + attr_reader :balance + + sig { params(balance: Lithic::Balance::OrHash).void } + attr_writer :balance + + # Payment transaction + sig { params(balance: Lithic::Balance::OrHash).returns(T.attached_class) } + def self.new( + # Balance + balance: nil + ) + end + + sig { override.returns({ balance: Lithic::Balance }) } + def to_hash + end + end + end +end diff --git a/rbi/lithic/models/payment_list_params.rbi b/rbi/lithic/models/payment_list_params.rbi index 3cf3a6f9..016a7397 100644 --- a/rbi/lithic/models/payment_list_params.rbi +++ b/rbi/lithic/models/payment_list_params.rbi @@ -158,6 +158,8 @@ module Lithic OrSymbol = T.type_alias { T.any(Symbol, String) } ACH = T.let(:ACH, Lithic::PaymentListParams::Category::TaggedSymbol) + STABLECOIN = + T.let(:STABLECOIN, Lithic::PaymentListParams::Category::TaggedSymbol) sig do override.returns( diff --git a/rbi/lithic/resources/payments.rbi b/rbi/lithic/resources/payments.rbi index 8e59659a..6c60171d 100644 --- a/rbi/lithic/resources/payments.rbi +++ b/rbi/lithic/resources/payments.rbi @@ -3,7 +3,14 @@ module Lithic module Resources class Payments - # Initiates a payment between a financial account and an external bank account. + # Initiates an ACH payment between a financial account and an external bank + # account. + # + # This endpoint originates on the ACH rail only. To send a stablecoin payout, use + # the + # [Create stablecoin payment](https://docs.lithic.com/reference/createstablecoinpayment) + # endpoint. Payments on every rail are read back through + # [List payments](https://docs.lithic.com/reference/searchpayments). sig do params( amount: Integer, @@ -90,6 +97,57 @@ module Lithic ) end + # Initiates a stablecoin payout from a financial account to a registered + # blockchain recipient. + # + # The recipient must have been registered with + # [Create blockchain recipient](https://docs.lithic.com/reference/createblockchainrecipient) + # and have completed address screening — only a recipient in the `ENABLED` + # verification state can receive a payout. The destination address and chain come + # from the recipient, so they are not supplied here. + # + # Only payouts are initiated through this endpoint. Stablecoin pay-ins are + # credited from on-chain deposits to a financial account's deposit address and are + # not created through the API. Funds are placed on hold when the payout is + # initiated, and a payout that fails on chain reverses that hold. A payout cannot + # be cancelled once it has been submitted on chain. + # + # This endpoint is only available to stablecoin-enabled programs. Contact your + # customer success manager to learn more. + sig do + params( + amount: Integer, + blockchain_recipient_token: String, + financial_account_token: String, + type: Lithic::PaymentCreateStablecoinParams::Type::OrSymbol, + token: String, + hold: Lithic::PaymentCreateStablecoinParams::Hold::OrHash, + memo: String, + request_options: Lithic::RequestOptions::OrHash + ).returns(Lithic::Models::PaymentCreateStablecoinResponse) + end + def create_stablecoin( + # Payout amount in cents + amount:, + # Token of the blockchain recipient to send the payout to. The recipient must be + # in the `ENABLED` verification state + blockchain_recipient_token:, + # Token of the financial account the payout is funded from + financial_account_token:, + # Direction of the payment. Stablecoin supports payouts only + type:, + # Customer-provided token that will serve as an idempotency token. This token will + # become the transaction token + token: nil, + # Optional hold to settle when this payout is initiated + hold: nil, + # Memo recorded on the payout. Defaults to `Stablecoin payout on ` when + # omitted + memo: nil, + request_options: {} + ) + end + # Retry an origination which has been returned. sig do params( diff --git a/sig/lithic/models.rbs b/sig/lithic/models.rbs index 38d60a8c..c1c531fc 100644 --- a/sig/lithic/models.rbs +++ b/sig/lithic/models.rbs @@ -425,6 +425,8 @@ module Lithic class PaymentCreateParams = Lithic::Models::PaymentCreateParams + class PaymentCreateStablecoinParams = Lithic::Models::PaymentCreateStablecoinParams + class PaymentListParams = Lithic::Models::PaymentListParams class PaymentRetrieveParams = Lithic::Models::PaymentRetrieveParams diff --git a/sig/lithic/models/payment_create_stablecoin_params.rbs b/sig/lithic/models/payment_create_stablecoin_params.rbs new file mode 100644 index 00000000..ea5c3626 --- /dev/null +++ b/sig/lithic/models/payment_create_stablecoin_params.rbs @@ -0,0 +1,84 @@ +module Lithic + module Models + type payment_create_stablecoin_params = + { + amount: Integer, + blockchain_recipient_token: String, + financial_account_token: String, + type: Lithic::Models::PaymentCreateStablecoinParams::type_, + token: String, + hold: Lithic::PaymentCreateStablecoinParams::Hold, + memo: String + } + & Lithic::Internal::Type::request_parameters + + class PaymentCreateStablecoinParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + attr_accessor amount: Integer + + attr_accessor blockchain_recipient_token: String + + attr_accessor financial_account_token: String + + attr_accessor type: Lithic::Models::PaymentCreateStablecoinParams::type_ + + attr_reader token: String? + + def token=: (String) -> String + + attr_reader hold: Lithic::PaymentCreateStablecoinParams::Hold? + + def hold=: ( + Lithic::PaymentCreateStablecoinParams::Hold + ) -> Lithic::PaymentCreateStablecoinParams::Hold + + attr_reader memo: String? + + def memo=: (String) -> String + + def initialize: ( + amount: Integer, + blockchain_recipient_token: String, + financial_account_token: String, + type: Lithic::Models::PaymentCreateStablecoinParams::type_, + ?token: String, + ?hold: Lithic::PaymentCreateStablecoinParams::Hold, + ?memo: String, + ?request_options: Lithic::request_opts + ) -> void + + def to_hash: -> { + amount: Integer, + blockchain_recipient_token: String, + financial_account_token: String, + type: Lithic::Models::PaymentCreateStablecoinParams::type_, + token: String, + hold: Lithic::PaymentCreateStablecoinParams::Hold, + memo: String, + request_options: Lithic::RequestOptions + } + + type type_ = :PAYMENT + + module Type + extend Lithic::Internal::Type::Enum + + PAYMENT: :PAYMENT + + def self?.values: -> ::Array[Lithic::Models::PaymentCreateStablecoinParams::type_] + end + + type hold = { token: String } + + class Hold < Lithic::Internal::Type::BaseModel + attr_accessor token: String + + def initialize: (token: String) -> void + + def to_hash: -> { token: String } + end + end + end +end diff --git a/sig/lithic/models/payment_create_stablecoin_response.rbs b/sig/lithic/models/payment_create_stablecoin_response.rbs new file mode 100644 index 00000000..d90eda87 --- /dev/null +++ b/sig/lithic/models/payment_create_stablecoin_response.rbs @@ -0,0 +1,15 @@ +module Lithic + module Models + type payment_create_stablecoin_response = { balance: Lithic::Balance } + + class PaymentCreateStablecoinResponse < Lithic::Models::Payment + def balance: -> Lithic::Balance? + + def balance=: (Lithic::Balance _) -> Lithic::Balance + + def initialize: (?balance: Lithic::Balance) -> void + + def to_hash: -> { balance: Lithic::Balance } + end + end +end diff --git a/sig/lithic/models/payment_list_params.rbs b/sig/lithic/models/payment_list_params.rbs index 84f6a9ec..3d64cd82 100644 --- a/sig/lithic/models/payment_list_params.rbs +++ b/sig/lithic/models/payment_list_params.rbs @@ -100,12 +100,13 @@ module Lithic request_options: Lithic::RequestOptions } - type category = :ACH + type category = :ACH | :STABLECOIN module Category extend Lithic::Internal::Type::Enum ACH: :ACH + STABLECOIN: :STABLECOIN def self?.values: -> ::Array[Lithic::Models::PaymentListParams::category] end diff --git a/sig/lithic/resources/payments.rbs b/sig/lithic/resources/payments.rbs index cbf52d48..d46f5168 100644 --- a/sig/lithic/resources/payments.rbs +++ b/sig/lithic/resources/payments.rbs @@ -35,6 +35,17 @@ module Lithic ?request_options: Lithic::request_opts ) -> Lithic::Internal::CursorPage[Lithic::Payment] + def create_stablecoin: ( + amount: Integer, + blockchain_recipient_token: String, + financial_account_token: String, + type: Lithic::Models::PaymentCreateStablecoinParams::type_, + ?token: String, + ?hold: Lithic::PaymentCreateStablecoinParams::Hold, + ?memo: String, + ?request_options: Lithic::request_opts + ) -> Lithic::Models::PaymentCreateStablecoinResponse + def retry_: ( String payment_token, ?request_options: Lithic::request_opts diff --git a/test/lithic/resources/payments_test.rb b/test/lithic/resources/payments_test.rb index 98a39f25..de15a1e8 100644 --- a/test/lithic/resources/payments_test.rb +++ b/test/lithic/resources/payments_test.rb @@ -100,6 +100,20 @@ def test_list end end + def test_create_stablecoin_required_params + response = + @lithic.payments.create_stablecoin( + amount: 1588, + blockchain_recipient_token: "1e3fdb71-4b52-4a30-a7a9-52c85e26a1d9", + financial_account_token: "35b0c466-a3e3-519a-9549-ead6a6a2277d", + type: :PAYMENT + ) + + assert_pattern do + response => Lithic::Models::PaymentCreateStablecoinResponse + end + end + def test_retry_ response = @lithic.payments.retry_("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e") From bd71bde5d20641e236b5b2e95908293bf0ef48e9 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 10 Sep 2026 17:05:55 +0000 Subject: [PATCH 04/14] feat: TRE-14349: add installment plan management operation event types --- .stats.yml | 4 ++-- .../statements/statement_line_items.rb | 2 ++ lib/lithic/models/financial_event.rb | 2 ++ .../models/management_operation_create_params.rb | 2 ++ lib/lithic/models/management_operation_transaction.rb | 2 ++ .../statements/statement_line_items.rbi | 10 ++++++++++ rbi/lithic/models/financial_event.rbi | 7 +++++++ .../models/management_operation_create_params.rbi | 10 ++++++++++ rbi/lithic/models/management_operation_transaction.rbi | 10 ++++++++++ .../statements/statement_line_items.rbs | 4 ++++ sig/lithic/models/financial_event.rbs | 4 ++++ .../models/management_operation_create_params.rbs | 4 ++++ sig/lithic/models/management_operation_transaction.rbs | 4 ++++ 13 files changed, 63 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index 3bbc4737..d5cfb794 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 217 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-70147140a7b2043acf622024eb3bde9b04264f8e9a695d4c79b5ee4db1534518.yml -openapi_spec_hash: 7a181cb1cfaaa201143bd9d04a841a2e +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-17e70cd484ec2fc2aca1243462ac8849153dbbe9b9245959ff51681b14f74024.yml +openapi_spec_hash: cc75e169c1c5ddc9ed619de07ee94d70 config_hash: e95c2dda5d175f9316457e0a84e35dce diff --git a/lib/lithic/models/financial_accounts/statements/statement_line_items.rb b/lib/lithic/models/financial_accounts/statements/statement_line_items.rb index 9ac87c6e..7dda6b61 100644 --- a/lib/lithic/models/financial_accounts/statements/statement_line_items.rb +++ b/lib/lithic/models/financial_accounts/statements/statement_line_items.rb @@ -252,6 +252,8 @@ module EventType EXTERNAL_WIRE_SETTLED = :EXTERNAL_WIRE_SETTLED FINANCIAL_AUTHORIZATION = :FINANCIAL_AUTHORIZATION FINANCIAL_CREDIT_AUTHORIZATION = :FINANCIAL_CREDIT_AUTHORIZATION + INSTALLMENT_FEE = :INSTALLMENT_FEE + INSTALLMENT_FEE_REVERSAL = :INSTALLMENT_FEE_REVERSAL INTEREST = :INTEREST INTEREST_REVERSAL = :INTEREST_REVERSAL INTERNAL_ADJUSTMENT = :INTERNAL_ADJUSTMENT diff --git a/lib/lithic/models/financial_event.rb b/lib/lithic/models/financial_event.rb index b94152ef..17fe92d7 100644 --- a/lib/lithic/models/financial_event.rb +++ b/lib/lithic/models/financial_event.rb @@ -138,6 +138,8 @@ module Type EXTERNAL_WIRE_SETTLED = :EXTERNAL_WIRE_SETTLED FINANCIAL_AUTHORIZATION = :FINANCIAL_AUTHORIZATION FINANCIAL_CREDIT_AUTHORIZATION = :FINANCIAL_CREDIT_AUTHORIZATION + INSTALLMENT_FEE = :INSTALLMENT_FEE + INSTALLMENT_FEE_REVERSAL = :INSTALLMENT_FEE_REVERSAL INTEREST = :INTEREST INTEREST_REVERSAL = :INTEREST_REVERSAL INTERNAL_ADJUSTMENT = :INTERNAL_ADJUSTMENT diff --git a/lib/lithic/models/management_operation_create_params.rb b/lib/lithic/models/management_operation_create_params.rb index 7aff24b8..63304757 100644 --- a/lib/lithic/models/management_operation_create_params.rb +++ b/lib/lithic/models/management_operation_create_params.rb @@ -126,6 +126,8 @@ module EventType CURRENCY_CONVERSION_REVERSAL = :CURRENCY_CONVERSION_REVERSAL INTEREST = :INTEREST INTEREST_REVERSAL = :INTEREST_REVERSAL + INSTALLMENT_FEE = :INSTALLMENT_FEE + INSTALLMENT_FEE_REVERSAL = :INSTALLMENT_FEE_REVERSAL LATE_PAYMENT = :LATE_PAYMENT LATE_PAYMENT_REVERSAL = :LATE_PAYMENT_REVERSAL BILLING_ERROR = :BILLING_ERROR diff --git a/lib/lithic/models/management_operation_transaction.rb b/lib/lithic/models/management_operation_transaction.rb index fc172b33..129d198d 100644 --- a/lib/lithic/models/management_operation_transaction.rb +++ b/lib/lithic/models/management_operation_transaction.rb @@ -259,6 +259,8 @@ module Type CURRENCY_CONVERSION_REVERSAL = :CURRENCY_CONVERSION_REVERSAL INTEREST = :INTEREST INTEREST_REVERSAL = :INTEREST_REVERSAL + INSTALLMENT_FEE = :INSTALLMENT_FEE + INSTALLMENT_FEE_REVERSAL = :INSTALLMENT_FEE_REVERSAL LATE_PAYMENT = :LATE_PAYMENT LATE_PAYMENT_REVERSAL = :LATE_PAYMENT_REVERSAL BILLING_ERROR = :BILLING_ERROR diff --git a/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi b/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi index b4811bed..269f707c 100644 --- a/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi +++ b/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi @@ -722,6 +722,16 @@ module Lithic :FINANCIAL_CREDIT_AUTHORIZATION, Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol ) + INSTALLMENT_FEE = + T.let( + :INSTALLMENT_FEE, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) + INSTALLMENT_FEE_REVERSAL = + T.let( + :INSTALLMENT_FEE_REVERSAL, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) INTEREST = T.let( :INTEREST, diff --git a/rbi/lithic/models/financial_event.rbi b/rbi/lithic/models/financial_event.rbi index 222e493d..2fb61a5f 100644 --- a/rbi/lithic/models/financial_event.rbi +++ b/rbi/lithic/models/financial_event.rbi @@ -426,6 +426,13 @@ module Lithic :FINANCIAL_CREDIT_AUTHORIZATION, Lithic::FinancialEvent::Type::TaggedSymbol ) + INSTALLMENT_FEE = + T.let(:INSTALLMENT_FEE, Lithic::FinancialEvent::Type::TaggedSymbol) + INSTALLMENT_FEE_REVERSAL = + T.let( + :INSTALLMENT_FEE_REVERSAL, + Lithic::FinancialEvent::Type::TaggedSymbol + ) INTEREST = T.let(:INTEREST, Lithic::FinancialEvent::Type::TaggedSymbol) INTEREST_REVERSAL = T.let(:INTEREST_REVERSAL, Lithic::FinancialEvent::Type::TaggedSymbol) diff --git a/rbi/lithic/models/management_operation_create_params.rbi b/rbi/lithic/models/management_operation_create_params.rbi index 4543f96f..402cce6f 100644 --- a/rbi/lithic/models/management_operation_create_params.rbi +++ b/rbi/lithic/models/management_operation_create_params.rbi @@ -266,6 +266,16 @@ module Lithic :INTEREST_REVERSAL, Lithic::ManagementOperationCreateParams::EventType::TaggedSymbol ) + INSTALLMENT_FEE = + T.let( + :INSTALLMENT_FEE, + Lithic::ManagementOperationCreateParams::EventType::TaggedSymbol + ) + INSTALLMENT_FEE_REVERSAL = + T.let( + :INSTALLMENT_FEE_REVERSAL, + Lithic::ManagementOperationCreateParams::EventType::TaggedSymbol + ) LATE_PAYMENT = T.let( :LATE_PAYMENT, diff --git a/rbi/lithic/models/management_operation_transaction.rbi b/rbi/lithic/models/management_operation_transaction.rbi index 5d798ea8..f0eec44d 100644 --- a/rbi/lithic/models/management_operation_transaction.rbi +++ b/rbi/lithic/models/management_operation_transaction.rbi @@ -592,6 +592,16 @@ module Lithic :INTEREST_REVERSAL, Lithic::ManagementOperationTransaction::Event::Type::TaggedSymbol ) + INSTALLMENT_FEE = + T.let( + :INSTALLMENT_FEE, + Lithic::ManagementOperationTransaction::Event::Type::TaggedSymbol + ) + INSTALLMENT_FEE_REVERSAL = + T.let( + :INSTALLMENT_FEE_REVERSAL, + Lithic::ManagementOperationTransaction::Event::Type::TaggedSymbol + ) LATE_PAYMENT = T.let( :LATE_PAYMENT, diff --git a/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs b/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs index bf0dc455..e8ea5871 100644 --- a/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs +++ b/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs @@ -238,6 +238,8 @@ module Lithic | :EXTERNAL_WIRE_SETTLED | :FINANCIAL_AUTHORIZATION | :FINANCIAL_CREDIT_AUTHORIZATION + | :INSTALLMENT_FEE + | :INSTALLMENT_FEE_REVERSAL | :INTEREST | :INTEREST_REVERSAL | :INTERNAL_ADJUSTMENT @@ -343,6 +345,8 @@ module Lithic EXTERNAL_WIRE_SETTLED: :EXTERNAL_WIRE_SETTLED FINANCIAL_AUTHORIZATION: :FINANCIAL_AUTHORIZATION FINANCIAL_CREDIT_AUTHORIZATION: :FINANCIAL_CREDIT_AUTHORIZATION + INSTALLMENT_FEE: :INSTALLMENT_FEE + INSTALLMENT_FEE_REVERSAL: :INSTALLMENT_FEE_REVERSAL INTEREST: :INTEREST INTEREST_REVERSAL: :INTEREST_REVERSAL INTERNAL_ADJUSTMENT: :INTERNAL_ADJUSTMENT diff --git a/sig/lithic/models/financial_event.rbs b/sig/lithic/models/financial_event.rbs index 262d4d38..c90157ef 100644 --- a/sig/lithic/models/financial_event.rbs +++ b/sig/lithic/models/financial_event.rbs @@ -132,6 +132,8 @@ module Lithic | :EXTERNAL_WIRE_SETTLED | :FINANCIAL_AUTHORIZATION | :FINANCIAL_CREDIT_AUTHORIZATION + | :INSTALLMENT_FEE + | :INSTALLMENT_FEE_REVERSAL | :INTEREST | :INTEREST_REVERSAL | :INTERNAL_ADJUSTMENT @@ -237,6 +239,8 @@ module Lithic EXTERNAL_WIRE_SETTLED: :EXTERNAL_WIRE_SETTLED FINANCIAL_AUTHORIZATION: :FINANCIAL_AUTHORIZATION FINANCIAL_CREDIT_AUTHORIZATION: :FINANCIAL_CREDIT_AUTHORIZATION + INSTALLMENT_FEE: :INSTALLMENT_FEE + INSTALLMENT_FEE_REVERSAL: :INSTALLMENT_FEE_REVERSAL INTEREST: :INTEREST INTEREST_REVERSAL: :INTEREST_REVERSAL INTERNAL_ADJUSTMENT: :INTERNAL_ADJUSTMENT diff --git a/sig/lithic/models/management_operation_create_params.rbs b/sig/lithic/models/management_operation_create_params.rbs index 3863796c..5e2bbce4 100644 --- a/sig/lithic/models/management_operation_create_params.rbs +++ b/sig/lithic/models/management_operation_create_params.rbs @@ -122,6 +122,8 @@ module Lithic | :CURRENCY_CONVERSION_REVERSAL | :INTEREST | :INTEREST_REVERSAL + | :INSTALLMENT_FEE + | :INSTALLMENT_FEE_REVERSAL | :LATE_PAYMENT | :LATE_PAYMENT_REVERSAL | :BILLING_ERROR @@ -151,6 +153,8 @@ module Lithic CURRENCY_CONVERSION_REVERSAL: :CURRENCY_CONVERSION_REVERSAL INTEREST: :INTEREST INTEREST_REVERSAL: :INTEREST_REVERSAL + INSTALLMENT_FEE: :INSTALLMENT_FEE + INSTALLMENT_FEE_REVERSAL: :INSTALLMENT_FEE_REVERSAL LATE_PAYMENT: :LATE_PAYMENT LATE_PAYMENT_REVERSAL: :LATE_PAYMENT_REVERSAL BILLING_ERROR: :BILLING_ERROR diff --git a/sig/lithic/models/management_operation_transaction.rbs b/sig/lithic/models/management_operation_transaction.rbs index c00b9577..762e67d6 100644 --- a/sig/lithic/models/management_operation_transaction.rbs +++ b/sig/lithic/models/management_operation_transaction.rbs @@ -251,6 +251,8 @@ module Lithic | :CURRENCY_CONVERSION_REVERSAL | :INTEREST | :INTEREST_REVERSAL + | :INSTALLMENT_FEE + | :INSTALLMENT_FEE_REVERSAL | :LATE_PAYMENT | :LATE_PAYMENT_REVERSAL | :BILLING_ERROR @@ -280,6 +282,8 @@ module Lithic CURRENCY_CONVERSION_REVERSAL: :CURRENCY_CONVERSION_REVERSAL INTEREST: :INTEREST INTEREST_REVERSAL: :INTEREST_REVERSAL + INSTALLMENT_FEE: :INSTALLMENT_FEE + INSTALLMENT_FEE_REVERSAL: :INSTALLMENT_FEE_REVERSAL LATE_PAYMENT: :LATE_PAYMENT LATE_PAYMENT_REVERSAL: :LATE_PAYMENT_REVERSAL BILLING_ERROR: :BILLING_ERROR From 3e8c0dcdaa7169ba0a47bea4493e71d778af8853 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 10 Sep 2026 17:58:58 +0000 Subject: [PATCH 05/14] feat: Add missing blockchain/stablecoin endpoints to the spec --- .stats.yml | 8 ++-- lib/lithic.rb | 1 + lib/lithic/models.rb | 2 + .../blockchain_recipient_retrieve_params.rb | 20 +++++++++ lib/lithic/resources/blockchain_recipients.rb | 23 +++++++++++ rbi/lithic/models.rbi | 3 ++ .../blockchain_recipient_retrieve_params.rbi | 41 +++++++++++++++++++ .../resources/blockchain_recipients.rbi | 14 +++++++ sig/lithic/models.rbs | 2 + .../blockchain_recipient_retrieve_params.rbs | 24 +++++++++++ .../resources/blockchain_recipients.rbs | 5 +++ .../resources/blockchain_recipients_test.rb | 26 ++++++++++++ 12 files changed, 165 insertions(+), 4 deletions(-) create mode 100644 lib/lithic/models/blockchain_recipient_retrieve_params.rb create mode 100644 rbi/lithic/models/blockchain_recipient_retrieve_params.rbi create mode 100644 sig/lithic/models/blockchain_recipient_retrieve_params.rbs diff --git a/.stats.yml b/.stats.yml index d5cfb794..a8ba0390 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ -configured_endpoints: 217 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-17e70cd484ec2fc2aca1243462ac8849153dbbe9b9245959ff51681b14f74024.yml -openapi_spec_hash: cc75e169c1c5ddc9ed619de07ee94d70 -config_hash: e95c2dda5d175f9316457e0a84e35dce +configured_endpoints: 218 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-c4c2ee9eddaa18ab29ef2d881e7c373d214d167b3eb7a74559f862ce36e95f74.yml +openapi_spec_hash: 3b1897cb075e1f19e2ce33e95781656a +config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 diff --git a/lib/lithic.rb b/lib/lithic.rb index ec6e7ccb..6f71c76e 100644 --- a/lib/lithic.rb +++ b/lib/lithic.rb @@ -169,6 +169,7 @@ require_relative "lithic/models/balance_updated_webhook_event" require_relative "lithic/models/blockchain_recipient" require_relative "lithic/models/blockchain_recipient_create_params" +require_relative "lithic/models/blockchain_recipient_retrieve_params" require_relative "lithic/models/book_transfer_create_params" require_relative "lithic/models/book_transfer_list_params" require_relative "lithic/models/book_transfer_retrieve_params" diff --git a/lib/lithic/models.rb b/lib/lithic/models.rb index 2691fcb7..926d3910 100644 --- a/lib/lithic/models.rb +++ b/lib/lithic/models.rb @@ -116,6 +116,8 @@ module Lithic BlockchainRecipientCreateParams = Lithic::Models::BlockchainRecipientCreateParams + BlockchainRecipientRetrieveParams = Lithic::Models::BlockchainRecipientRetrieveParams + BookTransferCreateParams = Lithic::Models::BookTransferCreateParams BookTransferListParams = Lithic::Models::BookTransferListParams diff --git a/lib/lithic/models/blockchain_recipient_retrieve_params.rb b/lib/lithic/models/blockchain_recipient_retrieve_params.rb new file mode 100644 index 00000000..1dad921b --- /dev/null +++ b/lib/lithic/models/blockchain_recipient_retrieve_params.rb @@ -0,0 +1,20 @@ +# frozen_string_literal: true + +module Lithic + module Models + # @see Lithic::Resources::BlockchainRecipients#retrieve + class BlockchainRecipientRetrieveParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + # @!attribute blockchain_recipient_token + # + # @return [String] + required :blockchain_recipient_token, String + + # @!method initialize(blockchain_recipient_token:, request_options: {}) + # @param blockchain_recipient_token [String] + # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}] + end + end +end diff --git a/lib/lithic/resources/blockchain_recipients.rb b/lib/lithic/resources/blockchain_recipients.rb index e44883c4..b3a349ec 100644 --- a/lib/lithic/resources/blockchain_recipients.rb +++ b/lib/lithic/resources/blockchain_recipients.rb @@ -46,6 +46,29 @@ def create(params) ) end + # Get a blockchain recipient by token + # + # Use this to poll the `verification_state` after registering an address: a + # recipient cannot receive a payout until screening completes and moves it out of + # `PENDING` + # + # @overload retrieve(blockchain_recipient_token, request_options: {}) + # + # @param blockchain_recipient_token [String] + # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}, nil] + # + # @return [Lithic::Models::BlockchainRecipient] + # + # @see Lithic::Models::BlockchainRecipientRetrieveParams + def retrieve(blockchain_recipient_token, params = {}) + @client.request( + method: :get, + path: ["v1/blockchain_recipients/%1$s", blockchain_recipient_token], + model: Lithic::BlockchainRecipient, + options: params[:request_options] + ) + end + # @api private # # @param client [Lithic::Client] diff --git a/rbi/lithic/models.rbi b/rbi/lithic/models.rbi index 5eb02609..e322a004 100644 --- a/rbi/lithic/models.rbi +++ b/rbi/lithic/models.rbi @@ -92,6 +92,9 @@ module Lithic BlockchainRecipientCreateParams = Lithic::Models::BlockchainRecipientCreateParams + BlockchainRecipientRetrieveParams = + Lithic::Models::BlockchainRecipientRetrieveParams + BookTransferCreateParams = Lithic::Models::BookTransferCreateParams BookTransferListParams = Lithic::Models::BookTransferListParams diff --git a/rbi/lithic/models/blockchain_recipient_retrieve_params.rbi b/rbi/lithic/models/blockchain_recipient_retrieve_params.rbi new file mode 100644 index 00000000..5c8a9dfb --- /dev/null +++ b/rbi/lithic/models/blockchain_recipient_retrieve_params.rbi @@ -0,0 +1,41 @@ +# typed: strong + +module Lithic + module Models + class BlockchainRecipientRetrieveParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + OrHash = + T.type_alias do + T.any( + Lithic::BlockchainRecipientRetrieveParams, + Lithic::Internal::AnyHash + ) + end + + sig { returns(String) } + attr_accessor :blockchain_recipient_token + + sig do + params( + blockchain_recipient_token: String, + request_options: Lithic::RequestOptions::OrHash + ).returns(T.attached_class) + end + def self.new(blockchain_recipient_token:, request_options: {}) + end + + sig do + override.returns( + { + blockchain_recipient_token: String, + request_options: Lithic::RequestOptions + } + ) + end + def to_hash + end + end + end +end diff --git a/rbi/lithic/resources/blockchain_recipients.rbi b/rbi/lithic/resources/blockchain_recipients.rbi index 5a4926c4..5b8f6400 100644 --- a/rbi/lithic/resources/blockchain_recipients.rbi +++ b/rbi/lithic/resources/blockchain_recipients.rbi @@ -42,6 +42,20 @@ module Lithic ) end + # Get a blockchain recipient by token + # + # Use this to poll the `verification_state` after registering an address: a + # recipient cannot receive a payout until screening completes and moves it out of + # `PENDING` + sig do + params( + blockchain_recipient_token: String, + request_options: Lithic::RequestOptions::OrHash + ).returns(Lithic::BlockchainRecipient) + end + def retrieve(blockchain_recipient_token, request_options: {}) + end + # @api private sig { params(client: Lithic::Client).returns(T.attached_class) } def self.new(client:) diff --git a/sig/lithic/models.rbs b/sig/lithic/models.rbs index c1c531fc..58bd41e9 100644 --- a/sig/lithic/models.rbs +++ b/sig/lithic/models.rbs @@ -75,6 +75,8 @@ module Lithic class BlockchainRecipientCreateParams = Lithic::Models::BlockchainRecipientCreateParams + class BlockchainRecipientRetrieveParams = Lithic::Models::BlockchainRecipientRetrieveParams + class BookTransferCreateParams = Lithic::Models::BookTransferCreateParams class BookTransferListParams = Lithic::Models::BookTransferListParams diff --git a/sig/lithic/models/blockchain_recipient_retrieve_params.rbs b/sig/lithic/models/blockchain_recipient_retrieve_params.rbs new file mode 100644 index 00000000..d1c60138 --- /dev/null +++ b/sig/lithic/models/blockchain_recipient_retrieve_params.rbs @@ -0,0 +1,24 @@ +module Lithic + module Models + type blockchain_recipient_retrieve_params = + { blockchain_recipient_token: String } + & Lithic::Internal::Type::request_parameters + + class BlockchainRecipientRetrieveParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + attr_accessor blockchain_recipient_token: String + + def initialize: ( + blockchain_recipient_token: String, + ?request_options: Lithic::request_opts + ) -> void + + def to_hash: -> { + blockchain_recipient_token: String, + request_options: Lithic::RequestOptions + } + end + end +end diff --git a/sig/lithic/resources/blockchain_recipients.rbs b/sig/lithic/resources/blockchain_recipients.rbs index e14f8c77..a599b165 100644 --- a/sig/lithic/resources/blockchain_recipients.rbs +++ b/sig/lithic/resources/blockchain_recipients.rbs @@ -12,6 +12,11 @@ module Lithic ?request_options: Lithic::request_opts ) -> Lithic::BlockchainRecipient + def retrieve: ( + String blockchain_recipient_token, + ?request_options: Lithic::request_opts + ) -> Lithic::BlockchainRecipient + def initialize: (client: Lithic::Client) -> void end end diff --git a/test/lithic/resources/blockchain_recipients_test.rb b/test/lithic/resources/blockchain_recipients_test.rb index ba7cce4f..28d214db 100644 --- a/test/lithic/resources/blockchain_recipients_test.rb +++ b/test/lithic/resources/blockchain_recipients_test.rb @@ -35,4 +35,30 @@ def test_create_required_params } end end + + def test_retrieve + response = @lithic.blockchain_recipients.retrieve("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e") + + assert_pattern do + response => Lithic::BlockchainRecipient + end + + assert_pattern do + response => { + token: String, + account_token: String | nil, + address_tag: String | nil, + chain: String, + created: Time, + external_id: String | nil, + name: String | nil, + owner: String, + owner_type: Lithic::OwnerType, + program_id: String, + state: Lithic::BlockchainRecipient::State, + updated: Time, + verification_state: Lithic::BlockchainRecipient::VerificationState + } + end + end end From b96e92e36fa4ae4dab543d1cc639d807f810b967 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 11 Sep 2026 16:14:45 +0000 Subject: [PATCH 06/14] docs: Document the card.pin_updated webhook --- .stats.yml | 4 +- lib/lithic.rb | 1 + lib/lithic/models.rb | 2 + .../models/card_pin_updated_webhook_event.rb | 87 +++++++++ lib/lithic/models/event.rb | 5 + lib/lithic/models/event_list_params.rb | 3 + lib/lithic/models/event_subscription.rb | 3 + .../events/subscription_create_params.rb | 3 + ...scription_send_simulated_example_params.rb | 1 + .../events/subscription_update_params.rb | 3 + lib/lithic/models/parsed_webhook_event.rb | 4 +- rbi/lithic/models.rbi | 2 + .../models/card_pin_updated_webhook_event.rbi | 166 ++++++++++++++++++ rbi/lithic/models/event.rbi | 8 + rbi/lithic/models/event_list_params.rbi | 7 + rbi/lithic/models/event_subscription.rbi | 7 + .../events/subscription_create_params.rbi | 7 + ...cription_send_simulated_example_params.rbi | 5 + .../events/subscription_update_params.rbi | 7 + rbi/lithic/models/parsed_webhook_event.rbi | 1 + rbi/lithic/resources/webhooks.rbi | 1 + sig/lithic/models.rbs | 2 + .../models/card_pin_updated_webhook_event.rbs | 60 +++++++ sig/lithic/models/event.rbs | 2 + sig/lithic/models/event_list_params.rbs | 2 + sig/lithic/models/event_subscription.rbs | 2 + .../events/subscription_create_params.rbs | 2 + ...cription_send_simulated_example_params.rbs | 2 + .../events/subscription_update_params.rbs | 2 + sig/lithic/models/parsed_webhook_event.rbs | 1 + sig/lithic/resources/webhooks.rbs | 1 + 31 files changed, 400 insertions(+), 3 deletions(-) create mode 100644 lib/lithic/models/card_pin_updated_webhook_event.rb create mode 100644 rbi/lithic/models/card_pin_updated_webhook_event.rbi create mode 100644 sig/lithic/models/card_pin_updated_webhook_event.rbs diff --git a/.stats.yml b/.stats.yml index a8ba0390..848bba66 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 218 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-c4c2ee9eddaa18ab29ef2d881e7c373d214d167b3eb7a74559f862ce36e95f74.yml -openapi_spec_hash: 3b1897cb075e1f19e2ce33e95781656a +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-6acbf033ded2c03ed5d5c64b6bea9f3250323bf7879a11e9c545aa30e65b3cca.yml +openapi_spec_hash: c6007083223ccff12c5c15bc9e531b41 config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 diff --git a/lib/lithic.rb b/lib/lithic.rb index 6f71c76e..2f7b5acf 100644 --- a/lib/lithic.rb +++ b/lib/lithic.rb @@ -195,6 +195,7 @@ require_relative "lithic/models/card_embed_response" require_relative "lithic/models/cardholder_authentication" require_relative "lithic/models/card_list_params" +require_relative "lithic/models/card_pin_updated_webhook_event" require_relative "lithic/models/card_program" require_relative "lithic/models/card_program_list_params" require_relative "lithic/models/card_program_retrieve_params" diff --git a/lib/lithic/models.rb b/lib/lithic/models.rb index 926d3910..866da5fb 100644 --- a/lib/lithic/models.rb +++ b/lib/lithic/models.rb @@ -172,6 +172,8 @@ module Lithic CardListParams = Lithic::Models::CardListParams + CardPinUpdatedWebhookEvent = Lithic::Models::CardPinUpdatedWebhookEvent + CardProgram = Lithic::Models::CardProgram CardProgramListParams = Lithic::Models::CardProgramListParams diff --git a/lib/lithic/models/card_pin_updated_webhook_event.rb b/lib/lithic/models/card_pin_updated_webhook_event.rb new file mode 100644 index 00000000..2ccf2a19 --- /dev/null +++ b/lib/lithic/models/card_pin_updated_webhook_event.rb @@ -0,0 +1,87 @@ +# frozen_string_literal: true + +module Lithic + module Models + class CardPinUpdatedWebhookEvent < Lithic::Internal::Type::BaseModel + # @!attribute card_token + # The token of the card whose PIN or PIN status was updated + # + # @return [String] + required :card_token, String + + # @!attribute event_type + # The type of event that occurred. + # + # @return [Symbol, :"card.pin_updated"] + required :event_type, const: :"card.pin_updated" + + # @!attribute pin_status + # The card's PIN status after the update + # + # @return [Symbol, Lithic::Models::CardPinUpdatedWebhookEvent::PinStatus] + required :pin_status, enum: -> { Lithic::CardPinUpdatedWebhookEvent::PinStatus } + + # @!attribute status_reason + # The reason for the PIN update: + # + # - `PIN_SET` - The PIN was set for the first time; `pin_status` is `OK` + # - `PIN_CHANGED` - The PIN was changed, including when changing a blocked PIN; + # `pin_status` is `OK` + # - `PIN_UNBLOCKED` - The PIN was unblocked without changing it; `pin_status` is + # `OK` + # - `EXCESSIVE_PIN_ATTEMPTS` - The PIN was blocked due to excessive incorrect PIN + # attempts; `pin_status` is `BLOCKED` + # + # @return [Symbol, Lithic::Models::CardPinUpdatedWebhookEvent::StatusReason] + required :status_reason, enum: -> { Lithic::CardPinUpdatedWebhookEvent::StatusReason } + + # @!method initialize(card_token:, pin_status:, status_reason:, event_type: :"card.pin_updated") + # Some parameter documentations has been truncated, see + # {Lithic::Models::CardPinUpdatedWebhookEvent} for more details. + # + # @param card_token [String] The token of the card whose PIN or PIN status was updated + # + # @param pin_status [Symbol, Lithic::Models::CardPinUpdatedWebhookEvent::PinStatus] The card's PIN status after the update + # + # @param status_reason [Symbol, Lithic::Models::CardPinUpdatedWebhookEvent::StatusReason] The reason for the PIN update: + # + # @param event_type [Symbol, :"card.pin_updated"] The type of event that occurred. + + # The card's PIN status after the update + # + # @see Lithic::Models::CardPinUpdatedWebhookEvent#pin_status + module PinStatus + extend Lithic::Internal::Type::Enum + + OK = :OK + BLOCKED = :BLOCKED + + # @!method self.values + # @return [Array] + end + + # The reason for the PIN update: + # + # - `PIN_SET` - The PIN was set for the first time; `pin_status` is `OK` + # - `PIN_CHANGED` - The PIN was changed, including when changing a blocked PIN; + # `pin_status` is `OK` + # - `PIN_UNBLOCKED` - The PIN was unblocked without changing it; `pin_status` is + # `OK` + # - `EXCESSIVE_PIN_ATTEMPTS` - The PIN was blocked due to excessive incorrect PIN + # attempts; `pin_status` is `BLOCKED` + # + # @see Lithic::Models::CardPinUpdatedWebhookEvent#status_reason + module StatusReason + extend Lithic::Internal::Type::Enum + + PIN_SET = :PIN_SET + PIN_CHANGED = :PIN_CHANGED + PIN_UNBLOCKED = :PIN_UNBLOCKED + EXCESSIVE_PIN_ATTEMPTS = :EXCESSIVE_PIN_ATTEMPTS + + # @!method self.values + # @return [Array] + end + end + end +end diff --git a/lib/lithic/models/event.rb b/lib/lithic/models/event.rb index ded0b720..993ed207 100644 --- a/lib/lithic/models/event.rb +++ b/lib/lithic/models/event.rb @@ -47,6 +47,8 @@ class Event < Lithic::Internal::Type::BaseModel # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -198,6 +200,8 @@ class Event < Lithic::Internal::Type::BaseModel # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -318,6 +322,7 @@ module EventType CARD_TRANSACTION_UPDATED = :"card_transaction.updated" CARD_CONVERTED = :"card.converted" CARD_CREATED = :"card.created" + CARD_PIN_UPDATED = :"card.pin_updated" CARD_REISSUED = :"card.reissued" CARD_RENEWED = :"card.renewed" CARD_SHIPPED = :"card.shipped" diff --git a/lib/lithic/models/event_list_params.rb b/lib/lithic/models/event_list_params.rb index 982d688b..8b01cdc3 100644 --- a/lib/lithic/models/event_list_params.rb +++ b/lib/lithic/models/event_list_params.rb @@ -101,6 +101,8 @@ class EventListParams < Lithic::Internal::Type::BaseModel # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -219,6 +221,7 @@ module EventType CARD_TRANSACTION_UPDATED = :"card_transaction.updated" CARD_CONVERTED = :"card.converted" CARD_CREATED = :"card.created" + CARD_PIN_UPDATED = :"card.pin_updated" CARD_REISSUED = :"card.reissued" CARD_RENEWED = :"card.renewed" CARD_SHIPPED = :"card.shipped" diff --git a/lib/lithic/models/event_subscription.rb b/lib/lithic/models/event_subscription.rb index cad4b296..e70607c4 100644 --- a/lib/lithic/models/event_subscription.rb +++ b/lib/lithic/models/event_subscription.rb @@ -74,6 +74,8 @@ class EventSubscription < Lithic::Internal::Type::BaseModel # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -192,6 +194,7 @@ module EventType CARD_TRANSACTION_UPDATED = :"card_transaction.updated" CARD_CONVERTED = :"card.converted" CARD_CREATED = :"card.created" + CARD_PIN_UPDATED = :"card.pin_updated" CARD_REISSUED = :"card.reissued" CARD_RENEWED = :"card.renewed" CARD_SHIPPED = :"card.shipped" diff --git a/lib/lithic/models/events/subscription_create_params.rb b/lib/lithic/models/events/subscription_create_params.rb index 2fc41689..011a315a 100644 --- a/lib/lithic/models/events/subscription_create_params.rb +++ b/lib/lithic/models/events/subscription_create_params.rb @@ -76,6 +76,8 @@ class SubscriptionCreateParams < Lithic::Internal::Type::BaseModel # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -194,6 +196,7 @@ module EventType CARD_TRANSACTION_UPDATED = :"card_transaction.updated" CARD_CONVERTED = :"card.converted" CARD_CREATED = :"card.created" + CARD_PIN_UPDATED = :"card.pin_updated" CARD_REISSUED = :"card.reissued" CARD_RENEWED = :"card.renewed" CARD_SHIPPED = :"card.shipped" diff --git a/lib/lithic/models/events/subscription_send_simulated_example_params.rb b/lib/lithic/models/events/subscription_send_simulated_example_params.rb index 82e616cc..0a02d874 100644 --- a/lib/lithic/models/events/subscription_send_simulated_example_params.rb +++ b/lib/lithic/models/events/subscription_send_simulated_example_params.rb @@ -45,6 +45,7 @@ module EventType CARD_TRANSACTION_UPDATED = :"card_transaction.updated" CARD_CONVERTED = :"card.converted" CARD_CREATED = :"card.created" + CARD_PIN_UPDATED = :"card.pin_updated" CARD_REISSUED = :"card.reissued" CARD_RENEWED = :"card.renewed" CARD_SHIPPED = :"card.shipped" diff --git a/lib/lithic/models/events/subscription_update_params.rb b/lib/lithic/models/events/subscription_update_params.rb index f60af3a0..011ca8e8 100644 --- a/lib/lithic/models/events/subscription_update_params.rb +++ b/lib/lithic/models/events/subscription_update_params.rb @@ -83,6 +83,8 @@ class SubscriptionUpdateParams < Lithic::Internal::Type::BaseModel # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -201,6 +203,7 @@ module EventType CARD_TRANSACTION_UPDATED = :"card_transaction.updated" CARD_CONVERTED = :"card.converted" CARD_CREATED = :"card.created" + CARD_PIN_UPDATED = :"card.pin_updated" CARD_REISSUED = :"card.reissued" CARD_RENEWED = :"card.renewed" CARD_SHIPPED = :"card.shipped" diff --git a/lib/lithic/models/parsed_webhook_event.rb b/lib/lithic/models/parsed_webhook_event.rb index 60479516..6c6f9db8 100644 --- a/lib/lithic/models/parsed_webhook_event.rb +++ b/lib/lithic/models/parsed_webhook_event.rb @@ -42,6 +42,8 @@ module ParsedWebhookEvent variant -> { Lithic::CardConvertedWebhookEvent } + variant -> { Lithic::CardPinUpdatedWebhookEvent } + variant -> { Lithic::CardRenewedWebhookEvent } variant -> { Lithic::CardReissuedWebhookEvent } @@ -830,7 +832,7 @@ module EventType end # @!method self.variants - # @return [Array(Lithic::Models::AccountHolderCreatedWebhookEvent, Lithic::Models::ParsedWebhookEvent::KYBPayload, Lithic::Models::ParsedWebhookEvent::KYCPayload, Lithic::Models::ParsedWebhookEvent::LegacyPayload, Lithic::Models::AccountHolderVerificationWebhookEvent, Lithic::Models::AccountHolderDocumentUpdatedWebhookEvent, Lithic::Models::CardAuthorizationApprovalRequestWebhookEvent, Lithic::Models::CardAuthorizationChallengeWebhookEvent, Lithic::Models::CardAuthorizationChallengeResponseWebhookEvent, Lithic::Models::AuthRulesBacktestReportCreatedWebhookEvent, Lithic::Models::BalanceUpdatedWebhookEvent, Lithic::Models::BookTransferTransactionCreatedWebhookEvent, Lithic::Models::BookTransferTransactionUpdatedWebhookEvent, Lithic::Models::CardCreatedWebhookEvent, Lithic::Models::CardConvertedWebhookEvent, Lithic::Models::CardRenewedWebhookEvent, Lithic::Models::CardReissuedWebhookEvent, Lithic::Models::CardShippedWebhookEvent, Lithic::Models::CardUpdatedWebhookEvent, Lithic::Models::CardTransactionUpdatedWebhookEvent, Lithic::Models::CardTransactionEnhancedDataCreatedWebhookEvent, Lithic::Models::CardTransactionEnhancedDataUpdatedWebhookEvent, Lithic::Models::ClaimCreatedWebhookEvent, Lithic::Models::ClaimUpdatedWebhookEvent, Lithic::Models::ClaimDocumentUploadedWebhookEvent, Lithic::Models::ClaimDocumentAcceptedWebhookEvent, Lithic::Models::ClaimDocumentRejectedWebhookEvent, Lithic::Models::DigitalWalletTokenizationApprovalRequestWebhookEvent, Lithic::Models::DigitalWalletTokenizationResultWebhookEvent, Lithic::Models::DigitalWalletTokenizationTwoFactorAuthenticationCodeWebhookEvent, Lithic::Models::DigitalWalletTokenizationTwoFactorAuthenticationCodeSentWebhookEvent, Lithic::Models::DigitalWalletTokenizationUpdatedWebhookEvent, Lithic::Models::DisputeUpdatedWebhookEvent, Lithic::Models::DisputeEvidenceUploadFailedWebhookEvent, Lithic::Models::EmbedSessionGeneratedWebhookEvent, Lithic::Models::EmbedViewedWebhookEvent, Lithic::Models::ExternalBankAccountCreatedWebhookEvent, Lithic::Models::ExternalBankAccountUpdatedWebhookEvent, Lithic::Models::ExternalPaymentCreatedWebhookEvent, Lithic::Models::ExternalPaymentUpdatedWebhookEvent, Lithic::Models::FinancialAccountCreatedWebhookEvent, Lithic::Models::FinancialAccountUpdatedWebhookEvent, Lithic::Models::FundingEventCreatedWebhookEvent, Lithic::Models::LoanTapeCreatedWebhookEvent, Lithic::Models::LoanTapeUpdatedWebhookEvent, Lithic::Models::ManagementOperationCreatedWebhookEvent, Lithic::Models::ManagementOperationUpdatedWebhookEvent, Lithic::Models::InternalTransactionCreatedWebhookEvent, Lithic::Models::InternalTransactionUpdatedWebhookEvent, Lithic::Models::NetworkTotalCreatedWebhookEvent, Lithic::Models::NetworkTotalUpdatedWebhookEvent, Lithic::Models::PaymentTransactionCreatedWebhookEvent, Lithic::Models::PaymentTransactionUpdatedWebhookEvent, Lithic::Models::SettlementReportUpdatedWebhookEvent, Lithic::Models::StatementsCreatedWebhookEvent, Lithic::Models::ThreeDSAuthenticationCreatedWebhookEvent, Lithic::Models::ThreeDSAuthenticationUpdatedWebhookEvent, Lithic::Models::ThreeDSAuthenticationChallengeWebhookEvent, Lithic::Models::TokenizationApprovalRequestWebhookEvent, Lithic::Models::TokenizationResultWebhookEvent, Lithic::Models::TokenizationTwoFactorAuthenticationCodeWebhookEvent, Lithic::Models::TokenizationTwoFactorAuthenticationCodeSentWebhookEvent, Lithic::Models::TokenizationUpdatedWebhookEvent, Lithic::Models::ThreeDSAuthenticationApprovalRequestWebhookEvent, Lithic::Models::DisputeTransactionCreatedWebhookEvent, Lithic::Models::DisputeTransactionUpdatedWebhookEvent)] + # @return [Array(Lithic::Models::AccountHolderCreatedWebhookEvent, Lithic::Models::ParsedWebhookEvent::KYBPayload, Lithic::Models::ParsedWebhookEvent::KYCPayload, Lithic::Models::ParsedWebhookEvent::LegacyPayload, Lithic::Models::AccountHolderVerificationWebhookEvent, Lithic::Models::AccountHolderDocumentUpdatedWebhookEvent, Lithic::Models::CardAuthorizationApprovalRequestWebhookEvent, Lithic::Models::CardAuthorizationChallengeWebhookEvent, Lithic::Models::CardAuthorizationChallengeResponseWebhookEvent, Lithic::Models::AuthRulesBacktestReportCreatedWebhookEvent, Lithic::Models::BalanceUpdatedWebhookEvent, Lithic::Models::BookTransferTransactionCreatedWebhookEvent, Lithic::Models::BookTransferTransactionUpdatedWebhookEvent, Lithic::Models::CardCreatedWebhookEvent, Lithic::Models::CardConvertedWebhookEvent, Lithic::Models::CardPinUpdatedWebhookEvent, Lithic::Models::CardRenewedWebhookEvent, Lithic::Models::CardReissuedWebhookEvent, Lithic::Models::CardShippedWebhookEvent, Lithic::Models::CardUpdatedWebhookEvent, Lithic::Models::CardTransactionUpdatedWebhookEvent, Lithic::Models::CardTransactionEnhancedDataCreatedWebhookEvent, Lithic::Models::CardTransactionEnhancedDataUpdatedWebhookEvent, Lithic::Models::ClaimCreatedWebhookEvent, Lithic::Models::ClaimUpdatedWebhookEvent, Lithic::Models::ClaimDocumentUploadedWebhookEvent, Lithic::Models::ClaimDocumentAcceptedWebhookEvent, Lithic::Models::ClaimDocumentRejectedWebhookEvent, Lithic::Models::DigitalWalletTokenizationApprovalRequestWebhookEvent, Lithic::Models::DigitalWalletTokenizationResultWebhookEvent, Lithic::Models::DigitalWalletTokenizationTwoFactorAuthenticationCodeWebhookEvent, Lithic::Models::DigitalWalletTokenizationTwoFactorAuthenticationCodeSentWebhookEvent, Lithic::Models::DigitalWalletTokenizationUpdatedWebhookEvent, Lithic::Models::DisputeUpdatedWebhookEvent, Lithic::Models::DisputeEvidenceUploadFailedWebhookEvent, Lithic::Models::EmbedSessionGeneratedWebhookEvent, Lithic::Models::EmbedViewedWebhookEvent, Lithic::Models::ExternalBankAccountCreatedWebhookEvent, Lithic::Models::ExternalBankAccountUpdatedWebhookEvent, Lithic::Models::ExternalPaymentCreatedWebhookEvent, Lithic::Models::ExternalPaymentUpdatedWebhookEvent, Lithic::Models::FinancialAccountCreatedWebhookEvent, Lithic::Models::FinancialAccountUpdatedWebhookEvent, Lithic::Models::FundingEventCreatedWebhookEvent, Lithic::Models::LoanTapeCreatedWebhookEvent, Lithic::Models::LoanTapeUpdatedWebhookEvent, Lithic::Models::ManagementOperationCreatedWebhookEvent, Lithic::Models::ManagementOperationUpdatedWebhookEvent, Lithic::Models::InternalTransactionCreatedWebhookEvent, Lithic::Models::InternalTransactionUpdatedWebhookEvent, Lithic::Models::NetworkTotalCreatedWebhookEvent, Lithic::Models::NetworkTotalUpdatedWebhookEvent, Lithic::Models::PaymentTransactionCreatedWebhookEvent, Lithic::Models::PaymentTransactionUpdatedWebhookEvent, Lithic::Models::SettlementReportUpdatedWebhookEvent, Lithic::Models::StatementsCreatedWebhookEvent, Lithic::Models::ThreeDSAuthenticationCreatedWebhookEvent, Lithic::Models::ThreeDSAuthenticationUpdatedWebhookEvent, Lithic::Models::ThreeDSAuthenticationChallengeWebhookEvent, Lithic::Models::TokenizationApprovalRequestWebhookEvent, Lithic::Models::TokenizationResultWebhookEvent, Lithic::Models::TokenizationTwoFactorAuthenticationCodeWebhookEvent, Lithic::Models::TokenizationTwoFactorAuthenticationCodeSentWebhookEvent, Lithic::Models::TokenizationUpdatedWebhookEvent, Lithic::Models::ThreeDSAuthenticationApprovalRequestWebhookEvent, Lithic::Models::DisputeTransactionCreatedWebhookEvent, Lithic::Models::DisputeTransactionUpdatedWebhookEvent)] end end end diff --git a/rbi/lithic/models.rbi b/rbi/lithic/models.rbi index e322a004..d995cfa1 100644 --- a/rbi/lithic/models.rbi +++ b/rbi/lithic/models.rbi @@ -153,6 +153,8 @@ module Lithic CardListParams = Lithic::Models::CardListParams + CardPinUpdatedWebhookEvent = Lithic::Models::CardPinUpdatedWebhookEvent + CardProgram = Lithic::Models::CardProgram CardProgramListParams = Lithic::Models::CardProgramListParams diff --git a/rbi/lithic/models/card_pin_updated_webhook_event.rbi b/rbi/lithic/models/card_pin_updated_webhook_event.rbi new file mode 100644 index 00000000..99afed5f --- /dev/null +++ b/rbi/lithic/models/card_pin_updated_webhook_event.rbi @@ -0,0 +1,166 @@ +# typed: strong + +module Lithic + module Models + class CardPinUpdatedWebhookEvent < Lithic::Internal::Type::BaseModel + OrHash = + T.type_alias do + T.any(Lithic::CardPinUpdatedWebhookEvent, Lithic::Internal::AnyHash) + end + + # The token of the card whose PIN or PIN status was updated + sig { returns(String) } + attr_accessor :card_token + + # The type of event that occurred. + sig { returns(Symbol) } + attr_accessor :event_type + + # The card's PIN status after the update + sig do + returns(Lithic::CardPinUpdatedWebhookEvent::PinStatus::TaggedSymbol) + end + attr_accessor :pin_status + + # The reason for the PIN update: + # + # - `PIN_SET` - The PIN was set for the first time; `pin_status` is `OK` + # - `PIN_CHANGED` - The PIN was changed, including when changing a blocked PIN; + # `pin_status` is `OK` + # - `PIN_UNBLOCKED` - The PIN was unblocked without changing it; `pin_status` is + # `OK` + # - `EXCESSIVE_PIN_ATTEMPTS` - The PIN was blocked due to excessive incorrect PIN + # attempts; `pin_status` is `BLOCKED` + sig do + returns(Lithic::CardPinUpdatedWebhookEvent::StatusReason::TaggedSymbol) + end + attr_accessor :status_reason + + sig do + params( + card_token: String, + pin_status: Lithic::CardPinUpdatedWebhookEvent::PinStatus::OrSymbol, + status_reason: + Lithic::CardPinUpdatedWebhookEvent::StatusReason::OrSymbol, + event_type: Symbol + ).returns(T.attached_class) + end + def self.new( + # The token of the card whose PIN or PIN status was updated + card_token:, + # The card's PIN status after the update + pin_status:, + # The reason for the PIN update: + # + # - `PIN_SET` - The PIN was set for the first time; `pin_status` is `OK` + # - `PIN_CHANGED` - The PIN was changed, including when changing a blocked PIN; + # `pin_status` is `OK` + # - `PIN_UNBLOCKED` - The PIN was unblocked without changing it; `pin_status` is + # `OK` + # - `EXCESSIVE_PIN_ATTEMPTS` - The PIN was blocked due to excessive incorrect PIN + # attempts; `pin_status` is `BLOCKED` + status_reason:, + # The type of event that occurred. + event_type: :"card.pin_updated" + ) + end + + sig do + override.returns( + { + card_token: String, + event_type: Symbol, + pin_status: + Lithic::CardPinUpdatedWebhookEvent::PinStatus::TaggedSymbol, + status_reason: + Lithic::CardPinUpdatedWebhookEvent::StatusReason::TaggedSymbol + } + ) + end + def to_hash + end + + # The card's PIN status after the update + module PinStatus + extend Lithic::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all(Symbol, Lithic::CardPinUpdatedWebhookEvent::PinStatus) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + OK = + T.let( + :OK, + Lithic::CardPinUpdatedWebhookEvent::PinStatus::TaggedSymbol + ) + BLOCKED = + T.let( + :BLOCKED, + Lithic::CardPinUpdatedWebhookEvent::PinStatus::TaggedSymbol + ) + + sig do + override.returns( + T::Array[ + Lithic::CardPinUpdatedWebhookEvent::PinStatus::TaggedSymbol + ] + ) + end + def self.values + end + end + + # The reason for the PIN update: + # + # - `PIN_SET` - The PIN was set for the first time; `pin_status` is `OK` + # - `PIN_CHANGED` - The PIN was changed, including when changing a blocked PIN; + # `pin_status` is `OK` + # - `PIN_UNBLOCKED` - The PIN was unblocked without changing it; `pin_status` is + # `OK` + # - `EXCESSIVE_PIN_ATTEMPTS` - The PIN was blocked due to excessive incorrect PIN + # attempts; `pin_status` is `BLOCKED` + module StatusReason + extend Lithic::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all(Symbol, Lithic::CardPinUpdatedWebhookEvent::StatusReason) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + PIN_SET = + T.let( + :PIN_SET, + Lithic::CardPinUpdatedWebhookEvent::StatusReason::TaggedSymbol + ) + PIN_CHANGED = + T.let( + :PIN_CHANGED, + Lithic::CardPinUpdatedWebhookEvent::StatusReason::TaggedSymbol + ) + PIN_UNBLOCKED = + T.let( + :PIN_UNBLOCKED, + Lithic::CardPinUpdatedWebhookEvent::StatusReason::TaggedSymbol + ) + EXCESSIVE_PIN_ATTEMPTS = + T.let( + :EXCESSIVE_PIN_ATTEMPTS, + Lithic::CardPinUpdatedWebhookEvent::StatusReason::TaggedSymbol + ) + + sig do + override.returns( + T::Array[ + Lithic::CardPinUpdatedWebhookEvent::StatusReason::TaggedSymbol + ] + ) + end + def self.values + end + end + end + end +end diff --git a/rbi/lithic/models/event.rbi b/rbi/lithic/models/event.rbi index c45e6def..1cad51f6 100644 --- a/rbi/lithic/models/event.rbi +++ b/rbi/lithic/models/event.rbi @@ -43,6 +43,8 @@ module Lithic # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -193,6 +195,8 @@ module Lithic # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -339,6 +343,8 @@ module Lithic # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -511,6 +517,8 @@ module Lithic T.let(:"card.converted", Lithic::Event::EventType::TaggedSymbol) CARD_CREATED = T.let(:"card.created", Lithic::Event::EventType::TaggedSymbol) + CARD_PIN_UPDATED = + T.let(:"card.pin_updated", Lithic::Event::EventType::TaggedSymbol) CARD_REISSUED = T.let(:"card.reissued", Lithic::Event::EventType::TaggedSymbol) CARD_RENEWED = diff --git a/rbi/lithic/models/event_list_params.rbi b/rbi/lithic/models/event_list_params.rbi index 58b62f1a..8ce140ed 100644 --- a/rbi/lithic/models/event_list_params.rbi +++ b/rbi/lithic/models/event_list_params.rbi @@ -152,6 +152,8 @@ module Lithic # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -334,6 +336,11 @@ module Lithic :"card.created", Lithic::EventListParams::EventType::TaggedSymbol ) + CARD_PIN_UPDATED = + T.let( + :"card.pin_updated", + Lithic::EventListParams::EventType::TaggedSymbol + ) CARD_REISSUED = T.let( :"card.reissued", diff --git a/rbi/lithic/models/event_subscription.rbi b/rbi/lithic/models/event_subscription.rbi index f82f9ffb..715a15a0 100644 --- a/rbi/lithic/models/event_subscription.rbi +++ b/rbi/lithic/models/event_subscription.rbi @@ -100,6 +100,8 @@ module Lithic # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -282,6 +284,11 @@ module Lithic :"card.created", Lithic::EventSubscription::EventType::TaggedSymbol ) + CARD_PIN_UPDATED = + T.let( + :"card.pin_updated", + Lithic::EventSubscription::EventType::TaggedSymbol + ) CARD_REISSUED = T.let( :"card.reissued", diff --git a/rbi/lithic/models/events/subscription_create_params.rbi b/rbi/lithic/models/events/subscription_create_params.rbi index 14cb5824..e77f8c61 100644 --- a/rbi/lithic/models/events/subscription_create_params.rbi +++ b/rbi/lithic/models/events/subscription_create_params.rbi @@ -127,6 +127,8 @@ module Lithic # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -311,6 +313,11 @@ module Lithic :"card.created", Lithic::Events::SubscriptionCreateParams::EventType::TaggedSymbol ) + CARD_PIN_UPDATED = + T.let( + :"card.pin_updated", + Lithic::Events::SubscriptionCreateParams::EventType::TaggedSymbol + ) CARD_REISSUED = T.let( :"card.reissued", diff --git a/rbi/lithic/models/events/subscription_send_simulated_example_params.rbi b/rbi/lithic/models/events/subscription_send_simulated_example_params.rbi index 0e38f181..d435367a 100644 --- a/rbi/lithic/models/events/subscription_send_simulated_example_params.rbi +++ b/rbi/lithic/models/events/subscription_send_simulated_example_params.rbi @@ -153,6 +153,11 @@ module Lithic :"card.created", Lithic::Events::SubscriptionSendSimulatedExampleParams::EventType::TaggedSymbol ) + CARD_PIN_UPDATED = + T.let( + :"card.pin_updated", + Lithic::Events::SubscriptionSendSimulatedExampleParams::EventType::TaggedSymbol + ) CARD_REISSUED = T.let( :"card.reissued", diff --git a/rbi/lithic/models/events/subscription_update_params.rbi b/rbi/lithic/models/events/subscription_update_params.rbi index f53db066..07623514 100644 --- a/rbi/lithic/models/events/subscription_update_params.rbi +++ b/rbi/lithic/models/events/subscription_update_params.rbi @@ -133,6 +133,8 @@ module Lithic # - card.converted: Occurs when a card is converted from virtual to physical # cards. # - card.created: Occurs when a new card is created. + # - card.pin_updated: Occurs when a card's PIN is set, changed, unblocked, or + # blocked due to excessive incorrect PIN attempts. # - card.reissued: Occurs when a card is reissued. # - card.renewed: Occurs when a card is renewed. # - card.shipped: Occurs when a card is shipped. @@ -317,6 +319,11 @@ module Lithic :"card.created", Lithic::Events::SubscriptionUpdateParams::EventType::TaggedSymbol ) + CARD_PIN_UPDATED = + T.let( + :"card.pin_updated", + Lithic::Events::SubscriptionUpdateParams::EventType::TaggedSymbol + ) CARD_REISSUED = T.let( :"card.reissued", diff --git a/rbi/lithic/models/parsed_webhook_event.rbi b/rbi/lithic/models/parsed_webhook_event.rbi index 01b23685..daf29c62 100644 --- a/rbi/lithic/models/parsed_webhook_event.rbi +++ b/rbi/lithic/models/parsed_webhook_event.rbi @@ -24,6 +24,7 @@ module Lithic Lithic::BookTransferTransactionUpdatedWebhookEvent, Lithic::CardCreatedWebhookEvent, Lithic::CardConvertedWebhookEvent, + Lithic::CardPinUpdatedWebhookEvent, Lithic::CardRenewedWebhookEvent, Lithic::CardReissuedWebhookEvent, Lithic::CardShippedWebhookEvent, diff --git a/rbi/lithic/resources/webhooks.rbi b/rbi/lithic/resources/webhooks.rbi index 4a974358..a0d8eedf 100644 --- a/rbi/lithic/resources/webhooks.rbi +++ b/rbi/lithic/resources/webhooks.rbi @@ -25,6 +25,7 @@ module Lithic Lithic::BookTransferTransactionUpdatedWebhookEvent, Lithic::CardCreatedWebhookEvent, Lithic::CardConvertedWebhookEvent, + Lithic::CardPinUpdatedWebhookEvent, Lithic::CardRenewedWebhookEvent, Lithic::CardReissuedWebhookEvent, Lithic::CardShippedWebhookEvent, diff --git a/sig/lithic/models.rbs b/sig/lithic/models.rbs index 58bd41e9..957c2aa8 100644 --- a/sig/lithic/models.rbs +++ b/sig/lithic/models.rbs @@ -129,6 +129,8 @@ module Lithic class CardListParams = Lithic::Models::CardListParams + class CardPinUpdatedWebhookEvent = Lithic::Models::CardPinUpdatedWebhookEvent + class CardProgram = Lithic::Models::CardProgram class CardProgramListParams = Lithic::Models::CardProgramListParams diff --git a/sig/lithic/models/card_pin_updated_webhook_event.rbs b/sig/lithic/models/card_pin_updated_webhook_event.rbs new file mode 100644 index 00000000..f3209c0e --- /dev/null +++ b/sig/lithic/models/card_pin_updated_webhook_event.rbs @@ -0,0 +1,60 @@ +module Lithic + module Models + type card_pin_updated_webhook_event = + { + card_token: String, + event_type: :"card.pin_updated", + pin_status: Lithic::Models::CardPinUpdatedWebhookEvent::pin_status, + status_reason: Lithic::Models::CardPinUpdatedWebhookEvent::status_reason + } + + class CardPinUpdatedWebhookEvent < Lithic::Internal::Type::BaseModel + attr_accessor card_token: String + + attr_accessor event_type: :"card.pin_updated" + + attr_accessor pin_status: Lithic::Models::CardPinUpdatedWebhookEvent::pin_status + + attr_accessor status_reason: Lithic::Models::CardPinUpdatedWebhookEvent::status_reason + + def initialize: ( + card_token: String, + pin_status: Lithic::Models::CardPinUpdatedWebhookEvent::pin_status, + status_reason: Lithic::Models::CardPinUpdatedWebhookEvent::status_reason, + ?event_type: :"card.pin_updated" + ) -> void + + def to_hash: -> { + card_token: String, + event_type: :"card.pin_updated", + pin_status: Lithic::Models::CardPinUpdatedWebhookEvent::pin_status, + status_reason: Lithic::Models::CardPinUpdatedWebhookEvent::status_reason + } + + type pin_status = :OK | :BLOCKED + + module PinStatus + extend Lithic::Internal::Type::Enum + + OK: :OK + BLOCKED: :BLOCKED + + def self?.values: -> ::Array[Lithic::Models::CardPinUpdatedWebhookEvent::pin_status] + end + + type status_reason = + :PIN_SET | :PIN_CHANGED | :PIN_UNBLOCKED | :EXCESSIVE_PIN_ATTEMPTS + + module StatusReason + extend Lithic::Internal::Type::Enum + + PIN_SET: :PIN_SET + PIN_CHANGED: :PIN_CHANGED + PIN_UNBLOCKED: :PIN_UNBLOCKED + EXCESSIVE_PIN_ATTEMPTS: :EXCESSIVE_PIN_ATTEMPTS + + def self?.values: -> ::Array[Lithic::Models::CardPinUpdatedWebhookEvent::status_reason] + end + end + end +end diff --git a/sig/lithic/models/event.rbs b/sig/lithic/models/event.rbs index 91af1586..688e7427 100644 --- a/sig/lithic/models/event.rbs +++ b/sig/lithic/models/event.rbs @@ -47,6 +47,7 @@ module Lithic | :"card_transaction.updated" | :"card.converted" | :"card.created" + | :"card.pin_updated" | :"card.reissued" | :"card.renewed" | :"card.shipped" @@ -112,6 +113,7 @@ module Lithic CARD_TRANSACTION_UPDATED: :"card_transaction.updated" CARD_CONVERTED: :"card.converted" CARD_CREATED: :"card.created" + CARD_PIN_UPDATED: :"card.pin_updated" CARD_REISSUED: :"card.reissued" CARD_RENEWED: :"card.renewed" CARD_SHIPPED: :"card.shipped" diff --git a/sig/lithic/models/event_list_params.rbs b/sig/lithic/models/event_list_params.rbs index c41a5477..c186eb47 100644 --- a/sig/lithic/models/event_list_params.rbs +++ b/sig/lithic/models/event_list_params.rbs @@ -84,6 +84,7 @@ module Lithic | :"card_transaction.updated" | :"card.converted" | :"card.created" + | :"card.pin_updated" | :"card.reissued" | :"card.renewed" | :"card.shipped" @@ -149,6 +150,7 @@ module Lithic CARD_TRANSACTION_UPDATED: :"card_transaction.updated" CARD_CONVERTED: :"card.converted" CARD_CREATED: :"card.created" + CARD_PIN_UPDATED: :"card.pin_updated" CARD_REISSUED: :"card.reissued" CARD_RENEWED: :"card.renewed" CARD_SHIPPED: :"card.shipped" diff --git a/sig/lithic/models/event_subscription.rbs b/sig/lithic/models/event_subscription.rbs index f47b795e..782b54f9 100644 --- a/sig/lithic/models/event_subscription.rbs +++ b/sig/lithic/models/event_subscription.rbs @@ -52,6 +52,7 @@ module Lithic | :"card_transaction.updated" | :"card.converted" | :"card.created" + | :"card.pin_updated" | :"card.reissued" | :"card.renewed" | :"card.shipped" @@ -117,6 +118,7 @@ module Lithic CARD_TRANSACTION_UPDATED: :"card_transaction.updated" CARD_CONVERTED: :"card.converted" CARD_CREATED: :"card.created" + CARD_PIN_UPDATED: :"card.pin_updated" CARD_REISSUED: :"card.reissued" CARD_RENEWED: :"card.renewed" CARD_SHIPPED: :"card.shipped" diff --git a/sig/lithic/models/events/subscription_create_params.rbs b/sig/lithic/models/events/subscription_create_params.rbs index 8afcfd98..439f522d 100644 --- a/sig/lithic/models/events/subscription_create_params.rbs +++ b/sig/lithic/models/events/subscription_create_params.rbs @@ -62,6 +62,7 @@ module Lithic | :"card_transaction.updated" | :"card.converted" | :"card.created" + | :"card.pin_updated" | :"card.reissued" | :"card.renewed" | :"card.shipped" @@ -127,6 +128,7 @@ module Lithic CARD_TRANSACTION_UPDATED: :"card_transaction.updated" CARD_CONVERTED: :"card.converted" CARD_CREATED: :"card.created" + CARD_PIN_UPDATED: :"card.pin_updated" CARD_REISSUED: :"card.reissued" CARD_RENEWED: :"card.renewed" CARD_SHIPPED: :"card.shipped" diff --git a/sig/lithic/models/events/subscription_send_simulated_example_params.rbs b/sig/lithic/models/events/subscription_send_simulated_example_params.rbs index dfb3a7cc..724d754e 100644 --- a/sig/lithic/models/events/subscription_send_simulated_example_params.rbs +++ b/sig/lithic/models/events/subscription_send_simulated_example_params.rbs @@ -48,6 +48,7 @@ module Lithic | :"card_transaction.updated" | :"card.converted" | :"card.created" + | :"card.pin_updated" | :"card.reissued" | :"card.renewed" | :"card.shipped" @@ -113,6 +114,7 @@ module Lithic CARD_TRANSACTION_UPDATED: :"card_transaction.updated" CARD_CONVERTED: :"card.converted" CARD_CREATED: :"card.created" + CARD_PIN_UPDATED: :"card.pin_updated" CARD_REISSUED: :"card.reissued" CARD_RENEWED: :"card.renewed" CARD_SHIPPED: :"card.shipped" diff --git a/sig/lithic/models/events/subscription_update_params.rbs b/sig/lithic/models/events/subscription_update_params.rbs index df5738ce..3b98abc9 100644 --- a/sig/lithic/models/events/subscription_update_params.rbs +++ b/sig/lithic/models/events/subscription_update_params.rbs @@ -67,6 +67,7 @@ module Lithic | :"card_transaction.updated" | :"card.converted" | :"card.created" + | :"card.pin_updated" | :"card.reissued" | :"card.renewed" | :"card.shipped" @@ -132,6 +133,7 @@ module Lithic CARD_TRANSACTION_UPDATED: :"card_transaction.updated" CARD_CONVERTED: :"card.converted" CARD_CREATED: :"card.created" + CARD_PIN_UPDATED: :"card.pin_updated" CARD_REISSUED: :"card.reissued" CARD_RENEWED: :"card.renewed" CARD_SHIPPED: :"card.shipped" diff --git a/sig/lithic/models/parsed_webhook_event.rbs b/sig/lithic/models/parsed_webhook_event.rbs index 78c3787a..683046b3 100644 --- a/sig/lithic/models/parsed_webhook_event.rbs +++ b/sig/lithic/models/parsed_webhook_event.rbs @@ -16,6 +16,7 @@ module Lithic | Lithic::BookTransferTransactionUpdatedWebhookEvent | Lithic::CardCreatedWebhookEvent | Lithic::CardConvertedWebhookEvent + | Lithic::CardPinUpdatedWebhookEvent | Lithic::CardRenewedWebhookEvent | Lithic::CardReissuedWebhookEvent | Lithic::CardShippedWebhookEvent diff --git a/sig/lithic/resources/webhooks.rbs b/sig/lithic/resources/webhooks.rbs index c5a4a0c1..ea4fb60f 100644 --- a/sig/lithic/resources/webhooks.rbs +++ b/sig/lithic/resources/webhooks.rbs @@ -20,6 +20,7 @@ module Lithic | Lithic::BookTransferTransactionUpdatedWebhookEvent | Lithic::CardCreatedWebhookEvent | Lithic::CardConvertedWebhookEvent + | Lithic::CardPinUpdatedWebhookEvent | Lithic::CardRenewedWebhookEvent | Lithic::CardReissuedWebhookEvent | Lithic::CardShippedWebhookEvent From 19e526e916227881e91ac1dac42e75d86132451e Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 11 Sep 2026 17:41:55 +0000 Subject: [PATCH 07/14] feat(api): add psd2_context field to three_ds_authentication --- .stats.yml | 4 +- lib/lithic/models/three_ds_authentication.rb | 127 +++++++- rbi/lithic/models/three_ds_authentication.rbi | 292 ++++++++++++++++++ sig/lithic/models/three_ds_authentication.rbs | 77 +++++ .../resources/three_ds/authentication_test.rb | 1 + 5 files changed, 498 insertions(+), 3 deletions(-) diff --git a/.stats.yml b/.stats.yml index 848bba66..36ae0494 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 218 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-6acbf033ded2c03ed5d5c64b6bea9f3250323bf7879a11e9c545aa30e65b3cca.yml -openapi_spec_hash: c6007083223ccff12c5c15bc9e531b41 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-e1085922e2d7ee4ce3122f1d9dfe675877f5551a591630592cfea38bd6fea9ed.yml +openapi_spec_hash: e9ca63bde70f9e3953e0a135e7daf185 config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 diff --git a/lib/lithic/models/three_ds_authentication.rb b/lib/lithic/models/three_ds_authentication.rb index a29ed789..58fd8e51 100644 --- a/lib/lithic/models/three_ds_authentication.rb +++ b/lib/lithic/models/three_ds_authentication.rb @@ -145,6 +145,14 @@ class ThreeDSAuthentication < Lithic::Internal::Type::BaseModel # @return [Symbol, Lithic::Models::ThreeDSAuthentication::DecisionMadeBy, nil] optional :decision_made_by, enum: -> { Lithic::ThreeDSAuthentication::DecisionMadeBy }, nil?: true + # @!attribute psd2_context + # PSD2/SCA context for EEA and UK transactions. Present when Lithic determines the + # transaction is in scope for PSD2 Strong Customer Authentication. Absent for + # out-of-scope transactions. + # + # @return [Lithic::Models::ThreeDSAuthentication::Psd2Context, nil] + optional :psd2_context, -> { Lithic::ThreeDSAuthentication::Psd2Context }, nil?: true + # @!attribute three_ri_request_type # Type of 3DS Requestor Initiated (3RI) request — i.e., a 3DS authentication that # takes place at the initiation of the merchant rather than the cardholder. The @@ -164,7 +172,7 @@ class ThreeDSAuthentication < Lithic::Internal::Type::BaseModel # @return [Lithic::Models::ThreeDSAuthentication::Transaction, nil] optional :transaction, -> { Lithic::ThreeDSAuthentication::Transaction }, nil?: true - # @!method initialize(token:, account_type:, authentication_result:, card_expiry_check:, card_token:, cardholder:, channel:, created:, merchant:, message_category:, three_ds_requestor_challenge_indicator:, additional_data: nil, app: nil, authentication_request_type: nil, browser: nil, challenge_metadata: nil, challenge_orchestrated_by: nil, decision_made_by: nil, three_ri_request_type: nil, transaction: nil) + # @!method initialize(token:, account_type:, authentication_result:, card_expiry_check:, card_token:, cardholder:, channel:, created:, merchant:, message_category:, three_ds_requestor_challenge_indicator:, additional_data: nil, app: nil, authentication_request_type: nil, browser: nil, challenge_metadata: nil, challenge_orchestrated_by: nil, decision_made_by: nil, psd2_context: nil, three_ri_request_type: nil, transaction: nil) # Some parameter documentations has been truncated, see # {Lithic::Models::ThreeDSAuthentication} for more details. # @@ -206,6 +214,8 @@ class ThreeDSAuthentication < Lithic::Internal::Type::BaseModel # # @param decision_made_by [Symbol, Lithic::Models::ThreeDSAuthentication::DecisionMadeBy, nil] Entity that made the authentication decision. This won't be set for authenticati # + # @param psd2_context [Lithic::Models::ThreeDSAuthentication::Psd2Context, nil] PSD2/SCA context for EEA and UK transactions. Present when Lithic determines the + # # @param three_ri_request_type [Symbol, Lithic::Models::ThreeDSAuthentication::ThreeRiRequestType, nil] Type of 3DS Requestor Initiated (3RI) request — i.e., a 3DS authentication that # # @param transaction [Lithic::Models::ThreeDSAuthentication::Transaction, nil] Object containing data about the e-commerce transaction for which the merchant i @@ -1142,6 +1152,121 @@ module DecisionMadeBy # @return [Array] end + # @see Lithic::Models::ThreeDSAuthentication#psd2_context + class Psd2Context < Lithic::Internal::Type::BaseModel + # @!attribute acquirer_exemption + # SCA exemption declared by the acquirer in the 3DS authentication request. + # + # - `NONE` - No exemption claimed + # - `TRANSACTION_RISK_ANALYSIS` - Transaction Risk Analysis (TRA) exemption; + # acquirer asserts low fraud risk + # - `LOW_VALUE` - Low-value payment exemption; transaction is below the EUR 30 + # threshold + # - `RECURRING_PAYMENT` - Recurring payment with a fixed amount to the same payee + # - `MERCHANT_INITIATED_TRANSACTION` - Merchant-initiated transaction (MIT); + # cardholder not present + # - `TRUSTED_BENEFICIARY` - Trusted beneficiary; merchant is on cardholder's + # whitelist + # - `STRONG_CUSTOMER_AUTHENTICATION_DELEGATION` - SCA already performed by a + # delegated third-party authenticator + # - `SECURE_CORPORATE_PAYMENT` - Secure corporate payment using a dedicated + # corporate card or process + # - `AUTHENTICATION_OUTAGE_EXCEPTION` - Authentication outage exception; + # scheme-level fallback during ACS downtime + # - `BUNDLED` - Mastercard only; bundled exemption code where the exact exemption + # type cannot be distinguished + # + # @return [Symbol, Lithic::Models::ThreeDSAuthentication::Psd2Context::AcquirerExemption, nil] + optional :acquirer_exemption, enum: -> { Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption } + + # @!attribute lithic_exemption_validation + # Lithic's validation of the acquirer-declared exemption. Absent when no acquirer + # exemption was declared. + # + # - `ACCEPTED` - Lithic signals support the acquirer's claim + # - `REJECTED` - Lithic signals contradict the claim, or a required signal is + # missing + # - `NOT_VALIDATED` - Exemption was declared but Lithic has no basis to evaluate + # it; treated as `REJECTED` for challenge purposes + # + # @return [Symbol, Lithic::Models::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation, nil] + optional :lithic_exemption_validation, + enum: -> { Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation } + + # @!method initialize(acquirer_exemption: nil, lithic_exemption_validation: nil) + # Some parameter documentations has been truncated, see + # {Lithic::Models::ThreeDSAuthentication::Psd2Context} for more details. + # + # PSD2/SCA context for EEA and UK transactions. Present when Lithic determines the + # transaction is in scope for PSD2 Strong Customer Authentication. Absent for + # out-of-scope transactions. + # + # @param acquirer_exemption [Symbol, Lithic::Models::ThreeDSAuthentication::Psd2Context::AcquirerExemption] SCA exemption declared by the acquirer in the 3DS authentication request. + # + # @param lithic_exemption_validation [Symbol, Lithic::Models::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation] Lithic's validation of the acquirer-declared exemption. Absent when no acquirer + + # SCA exemption declared by the acquirer in the 3DS authentication request. + # + # - `NONE` - No exemption claimed + # - `TRANSACTION_RISK_ANALYSIS` - Transaction Risk Analysis (TRA) exemption; + # acquirer asserts low fraud risk + # - `LOW_VALUE` - Low-value payment exemption; transaction is below the EUR 30 + # threshold + # - `RECURRING_PAYMENT` - Recurring payment with a fixed amount to the same payee + # - `MERCHANT_INITIATED_TRANSACTION` - Merchant-initiated transaction (MIT); + # cardholder not present + # - `TRUSTED_BENEFICIARY` - Trusted beneficiary; merchant is on cardholder's + # whitelist + # - `STRONG_CUSTOMER_AUTHENTICATION_DELEGATION` - SCA already performed by a + # delegated third-party authenticator + # - `SECURE_CORPORATE_PAYMENT` - Secure corporate payment using a dedicated + # corporate card or process + # - `AUTHENTICATION_OUTAGE_EXCEPTION` - Authentication outage exception; + # scheme-level fallback during ACS downtime + # - `BUNDLED` - Mastercard only; bundled exemption code where the exact exemption + # type cannot be distinguished + # + # @see Lithic::Models::ThreeDSAuthentication::Psd2Context#acquirer_exemption + module AcquirerExemption + extend Lithic::Internal::Type::Enum + + NONE = :NONE + TRANSACTION_RISK_ANALYSIS = :TRANSACTION_RISK_ANALYSIS + LOW_VALUE = :LOW_VALUE + RECURRING_PAYMENT = :RECURRING_PAYMENT + MERCHANT_INITIATED_TRANSACTION = :MERCHANT_INITIATED_TRANSACTION + TRUSTED_BENEFICIARY = :TRUSTED_BENEFICIARY + STRONG_CUSTOMER_AUTHENTICATION_DELEGATION = :STRONG_CUSTOMER_AUTHENTICATION_DELEGATION + SECURE_CORPORATE_PAYMENT = :SECURE_CORPORATE_PAYMENT + AUTHENTICATION_OUTAGE_EXCEPTION = :AUTHENTICATION_OUTAGE_EXCEPTION + BUNDLED = :BUNDLED + + # @!method self.values + # @return [Array] + end + + # Lithic's validation of the acquirer-declared exemption. Absent when no acquirer + # exemption was declared. + # + # - `ACCEPTED` - Lithic signals support the acquirer's claim + # - `REJECTED` - Lithic signals contradict the claim, or a required signal is + # missing + # - `NOT_VALIDATED` - Exemption was declared but Lithic has no basis to evaluate + # it; treated as `REJECTED` for challenge purposes + # + # @see Lithic::Models::ThreeDSAuthentication::Psd2Context#lithic_exemption_validation + module LithicExemptionValidation + extend Lithic::Internal::Type::Enum + + ACCEPTED = :ACCEPTED + REJECTED = :REJECTED + NOT_VALIDATED = :NOT_VALIDATED + + # @!method self.values + # @return [Array] + end + end + # Type of 3DS Requestor Initiated (3RI) request — i.e., a 3DS authentication that # takes place at the initiation of the merchant rather than the cardholder. The # most common example of this is where a merchant is authenticating before billing diff --git a/rbi/lithic/models/three_ds_authentication.rbi b/rbi/lithic/models/three_ds_authentication.rbi index 60250948..a8c1f9d1 100644 --- a/rbi/lithic/models/three_ds_authentication.rbi +++ b/rbi/lithic/models/three_ds_authentication.rbi @@ -183,6 +183,20 @@ module Lithic end attr_accessor :decision_made_by + # PSD2/SCA context for EEA and UK transactions. Present when Lithic determines the + # transaction is in scope for PSD2 Strong Customer Authentication. Absent for + # out-of-scope transactions. + sig { returns(T.nilable(Lithic::ThreeDSAuthentication::Psd2Context)) } + attr_reader :psd2_context + + sig do + params( + psd2_context: + T.nilable(Lithic::ThreeDSAuthentication::Psd2Context::OrHash) + ).void + end + attr_writer :psd2_context + # Type of 3DS Requestor Initiated (3RI) request — i.e., a 3DS authentication that # takes place at the initiation of the merchant rather than the cardholder. The # most common example of this is where a merchant is authenticating before billing @@ -245,6 +259,8 @@ module Lithic ), decision_made_by: T.nilable(Lithic::ThreeDSAuthentication::DecisionMadeBy::OrSymbol), + psd2_context: + T.nilable(Lithic::ThreeDSAuthentication::Psd2Context::OrHash), three_ri_request_type: T.nilable( Lithic::ThreeDSAuthentication::ThreeRiRequestType::OrSymbol @@ -319,6 +335,10 @@ module Lithic # authentications for which a decision has not yet been made (e.g. in-flight # customer decisioning request). decision_made_by: nil, + # PSD2/SCA context for EEA and UK transactions. Present when Lithic determines the + # transaction is in scope for PSD2 Strong Customer Authentication. Absent for + # out-of-scope transactions. + psd2_context: nil, # Type of 3DS Requestor Initiated (3RI) request — i.e., a 3DS authentication that # takes place at the initiation of the merchant rather than the cardholder. The # most common example of this is where a merchant is authenticating before billing @@ -370,6 +390,7 @@ module Lithic T.nilable( Lithic::ThreeDSAuthentication::DecisionMadeBy::TaggedSymbol ), + psd2_context: T.nilable(Lithic::ThreeDSAuthentication::Psd2Context), three_ri_request_type: T.nilable( Lithic::ThreeDSAuthentication::ThreeRiRequestType::TaggedSymbol @@ -2171,6 +2192,277 @@ module Lithic end end + class Psd2Context < Lithic::Internal::Type::BaseModel + OrHash = + T.type_alias do + T.any( + Lithic::ThreeDSAuthentication::Psd2Context, + Lithic::Internal::AnyHash + ) + end + + # SCA exemption declared by the acquirer in the 3DS authentication request. + # + # - `NONE` - No exemption claimed + # - `TRANSACTION_RISK_ANALYSIS` - Transaction Risk Analysis (TRA) exemption; + # acquirer asserts low fraud risk + # - `LOW_VALUE` - Low-value payment exemption; transaction is below the EUR 30 + # threshold + # - `RECURRING_PAYMENT` - Recurring payment with a fixed amount to the same payee + # - `MERCHANT_INITIATED_TRANSACTION` - Merchant-initiated transaction (MIT); + # cardholder not present + # - `TRUSTED_BENEFICIARY` - Trusted beneficiary; merchant is on cardholder's + # whitelist + # - `STRONG_CUSTOMER_AUTHENTICATION_DELEGATION` - SCA already performed by a + # delegated third-party authenticator + # - `SECURE_CORPORATE_PAYMENT` - Secure corporate payment using a dedicated + # corporate card or process + # - `AUTHENTICATION_OUTAGE_EXCEPTION` - Authentication outage exception; + # scheme-level fallback during ACS downtime + # - `BUNDLED` - Mastercard only; bundled exemption code where the exact exemption + # type cannot be distinguished + sig do + returns( + T.nilable( + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + ) + end + attr_reader :acquirer_exemption + + sig do + params( + acquirer_exemption: + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::OrSymbol + ).void + end + attr_writer :acquirer_exemption + + # Lithic's validation of the acquirer-declared exemption. Absent when no acquirer + # exemption was declared. + # + # - `ACCEPTED` - Lithic signals support the acquirer's claim + # - `REJECTED` - Lithic signals contradict the claim, or a required signal is + # missing + # - `NOT_VALIDATED` - Exemption was declared but Lithic has no basis to evaluate + # it; treated as `REJECTED` for challenge purposes + sig do + returns( + T.nilable( + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation::TaggedSymbol + ) + ) + end + attr_reader :lithic_exemption_validation + + sig do + params( + lithic_exemption_validation: + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation::OrSymbol + ).void + end + attr_writer :lithic_exemption_validation + + # PSD2/SCA context for EEA and UK transactions. Present when Lithic determines the + # transaction is in scope for PSD2 Strong Customer Authentication. Absent for + # out-of-scope transactions. + sig do + params( + acquirer_exemption: + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::OrSymbol, + lithic_exemption_validation: + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation::OrSymbol + ).returns(T.attached_class) + end + def self.new( + # SCA exemption declared by the acquirer in the 3DS authentication request. + # + # - `NONE` - No exemption claimed + # - `TRANSACTION_RISK_ANALYSIS` - Transaction Risk Analysis (TRA) exemption; + # acquirer asserts low fraud risk + # - `LOW_VALUE` - Low-value payment exemption; transaction is below the EUR 30 + # threshold + # - `RECURRING_PAYMENT` - Recurring payment with a fixed amount to the same payee + # - `MERCHANT_INITIATED_TRANSACTION` - Merchant-initiated transaction (MIT); + # cardholder not present + # - `TRUSTED_BENEFICIARY` - Trusted beneficiary; merchant is on cardholder's + # whitelist + # - `STRONG_CUSTOMER_AUTHENTICATION_DELEGATION` - SCA already performed by a + # delegated third-party authenticator + # - `SECURE_CORPORATE_PAYMENT` - Secure corporate payment using a dedicated + # corporate card or process + # - `AUTHENTICATION_OUTAGE_EXCEPTION` - Authentication outage exception; + # scheme-level fallback during ACS downtime + # - `BUNDLED` - Mastercard only; bundled exemption code where the exact exemption + # type cannot be distinguished + acquirer_exemption: nil, + # Lithic's validation of the acquirer-declared exemption. Absent when no acquirer + # exemption was declared. + # + # - `ACCEPTED` - Lithic signals support the acquirer's claim + # - `REJECTED` - Lithic signals contradict the claim, or a required signal is + # missing + # - `NOT_VALIDATED` - Exemption was declared but Lithic has no basis to evaluate + # it; treated as `REJECTED` for challenge purposes + lithic_exemption_validation: nil + ) + end + + sig do + override.returns( + { + acquirer_exemption: + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol, + lithic_exemption_validation: + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation::TaggedSymbol + } + ) + end + def to_hash + end + + # SCA exemption declared by the acquirer in the 3DS authentication request. + # + # - `NONE` - No exemption claimed + # - `TRANSACTION_RISK_ANALYSIS` - Transaction Risk Analysis (TRA) exemption; + # acquirer asserts low fraud risk + # - `LOW_VALUE` - Low-value payment exemption; transaction is below the EUR 30 + # threshold + # - `RECURRING_PAYMENT` - Recurring payment with a fixed amount to the same payee + # - `MERCHANT_INITIATED_TRANSACTION` - Merchant-initiated transaction (MIT); + # cardholder not present + # - `TRUSTED_BENEFICIARY` - Trusted beneficiary; merchant is on cardholder's + # whitelist + # - `STRONG_CUSTOMER_AUTHENTICATION_DELEGATION` - SCA already performed by a + # delegated third-party authenticator + # - `SECURE_CORPORATE_PAYMENT` - Secure corporate payment using a dedicated + # corporate card or process + # - `AUTHENTICATION_OUTAGE_EXCEPTION` - Authentication outage exception; + # scheme-level fallback during ACS downtime + # - `BUNDLED` - Mastercard only; bundled exemption code where the exact exemption + # type cannot be distinguished + module AcquirerExemption + extend Lithic::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all( + Symbol, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption + ) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + NONE = + T.let( + :NONE, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + TRANSACTION_RISK_ANALYSIS = + T.let( + :TRANSACTION_RISK_ANALYSIS, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + LOW_VALUE = + T.let( + :LOW_VALUE, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + RECURRING_PAYMENT = + T.let( + :RECURRING_PAYMENT, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + MERCHANT_INITIATED_TRANSACTION = + T.let( + :MERCHANT_INITIATED_TRANSACTION, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + TRUSTED_BENEFICIARY = + T.let( + :TRUSTED_BENEFICIARY, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + STRONG_CUSTOMER_AUTHENTICATION_DELEGATION = + T.let( + :STRONG_CUSTOMER_AUTHENTICATION_DELEGATION, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + SECURE_CORPORATE_PAYMENT = + T.let( + :SECURE_CORPORATE_PAYMENT, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + AUTHENTICATION_OUTAGE_EXCEPTION = + T.let( + :AUTHENTICATION_OUTAGE_EXCEPTION, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + BUNDLED = + T.let( + :BUNDLED, + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ) + + sig do + override.returns( + T::Array[ + Lithic::ThreeDSAuthentication::Psd2Context::AcquirerExemption::TaggedSymbol + ] + ) + end + def self.values + end + end + + # Lithic's validation of the acquirer-declared exemption. Absent when no acquirer + # exemption was declared. + # + # - `ACCEPTED` - Lithic signals support the acquirer's claim + # - `REJECTED` - Lithic signals contradict the claim, or a required signal is + # missing + # - `NOT_VALIDATED` - Exemption was declared but Lithic has no basis to evaluate + # it; treated as `REJECTED` for challenge purposes + module LithicExemptionValidation + extend Lithic::Internal::Type::Enum + + TaggedSymbol = + T.type_alias do + T.all( + Symbol, + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation + ) + end + OrSymbol = T.type_alias { T.any(Symbol, String) } + + ACCEPTED = + T.let( + :ACCEPTED, + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation::TaggedSymbol + ) + REJECTED = + T.let( + :REJECTED, + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation::TaggedSymbol + ) + NOT_VALIDATED = + T.let( + :NOT_VALIDATED, + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation::TaggedSymbol + ) + + sig do + override.returns( + T::Array[ + Lithic::ThreeDSAuthentication::Psd2Context::LithicExemptionValidation::TaggedSymbol + ] + ) + end + def self.values + end + end + end + # Type of 3DS Requestor Initiated (3RI) request — i.e., a 3DS authentication that # takes place at the initiation of the merchant rather than the cardholder. The # most common example of this is where a merchant is authenticating before billing diff --git a/sig/lithic/models/three_ds_authentication.rbs b/sig/lithic/models/three_ds_authentication.rbs index 844c69db..223ab4e3 100644 --- a/sig/lithic/models/three_ds_authentication.rbs +++ b/sig/lithic/models/three_ds_authentication.rbs @@ -20,6 +20,7 @@ module Lithic challenge_metadata: Lithic::ThreeDSAuthentication::ChallengeMetadata?, challenge_orchestrated_by: Lithic::Models::ThreeDSAuthentication::challenge_orchestrated_by?, decision_made_by: Lithic::Models::ThreeDSAuthentication::decision_made_by?, + :psd2_context => Lithic::ThreeDSAuthentication::Psd2Context?, three_ri_request_type: Lithic::Models::ThreeDSAuthentication::three_ri_request_type?, transaction: Lithic::ThreeDSAuthentication::Transaction? } @@ -61,6 +62,8 @@ module Lithic attr_accessor decision_made_by: Lithic::Models::ThreeDSAuthentication::decision_made_by? + attr_accessor psd2_context: Lithic::ThreeDSAuthentication::Psd2Context? + attr_accessor three_ri_request_type: Lithic::Models::ThreeDSAuthentication::three_ri_request_type? attr_accessor transaction: Lithic::ThreeDSAuthentication::Transaction? @@ -84,6 +87,7 @@ module Lithic ?challenge_metadata: Lithic::ThreeDSAuthentication::ChallengeMetadata?, ?challenge_orchestrated_by: Lithic::Models::ThreeDSAuthentication::challenge_orchestrated_by?, ?decision_made_by: Lithic::Models::ThreeDSAuthentication::decision_made_by?, + ?psd2_context: Lithic::ThreeDSAuthentication::Psd2Context?, ?three_ri_request_type: Lithic::Models::ThreeDSAuthentication::three_ri_request_type?, ?transaction: Lithic::ThreeDSAuthentication::Transaction? ) -> void @@ -107,6 +111,7 @@ module Lithic challenge_metadata: Lithic::ThreeDSAuthentication::ChallengeMetadata?, challenge_orchestrated_by: Lithic::Models::ThreeDSAuthentication::challenge_orchestrated_by?, decision_made_by: Lithic::Models::ThreeDSAuthentication::decision_made_by?, + :psd2_context => Lithic::ThreeDSAuthentication::Psd2Context?, three_ri_request_type: Lithic::Models::ThreeDSAuthentication::three_ri_request_type?, transaction: Lithic::ThreeDSAuthentication::Transaction? } @@ -805,6 +810,78 @@ module Lithic def self?.values: -> ::Array[Lithic::Models::ThreeDSAuthentication::decision_made_by] end + type psd2_context = + { + acquirer_exemption: Lithic::Models::ThreeDSAuthentication::Psd2Context::acquirer_exemption, + lithic_exemption_validation: Lithic::Models::ThreeDSAuthentication::Psd2Context::lithic_exemption_validation + } + + class Psd2Context < Lithic::Internal::Type::BaseModel + attr_reader acquirer_exemption: Lithic::Models::ThreeDSAuthentication::Psd2Context::acquirer_exemption? + + def acquirer_exemption=: ( + Lithic::Models::ThreeDSAuthentication::Psd2Context::acquirer_exemption + ) -> Lithic::Models::ThreeDSAuthentication::Psd2Context::acquirer_exemption + + attr_reader lithic_exemption_validation: Lithic::Models::ThreeDSAuthentication::Psd2Context::lithic_exemption_validation? + + def lithic_exemption_validation=: ( + Lithic::Models::ThreeDSAuthentication::Psd2Context::lithic_exemption_validation + ) -> Lithic::Models::ThreeDSAuthentication::Psd2Context::lithic_exemption_validation + + def initialize: ( + ?acquirer_exemption: Lithic::Models::ThreeDSAuthentication::Psd2Context::acquirer_exemption, + ?lithic_exemption_validation: Lithic::Models::ThreeDSAuthentication::Psd2Context::lithic_exemption_validation + ) -> void + + def to_hash: -> { + acquirer_exemption: Lithic::Models::ThreeDSAuthentication::Psd2Context::acquirer_exemption, + lithic_exemption_validation: Lithic::Models::ThreeDSAuthentication::Psd2Context::lithic_exemption_validation + } + + type acquirer_exemption = + :NONE + | :TRANSACTION_RISK_ANALYSIS + | :LOW_VALUE + | :RECURRING_PAYMENT + | :MERCHANT_INITIATED_TRANSACTION + | :TRUSTED_BENEFICIARY + | :STRONG_CUSTOMER_AUTHENTICATION_DELEGATION + | :SECURE_CORPORATE_PAYMENT + | :AUTHENTICATION_OUTAGE_EXCEPTION + | :BUNDLED + + module AcquirerExemption + extend Lithic::Internal::Type::Enum + + NONE: :NONE + TRANSACTION_RISK_ANALYSIS: :TRANSACTION_RISK_ANALYSIS + LOW_VALUE: :LOW_VALUE + RECURRING_PAYMENT: :RECURRING_PAYMENT + MERCHANT_INITIATED_TRANSACTION: :MERCHANT_INITIATED_TRANSACTION + TRUSTED_BENEFICIARY: :TRUSTED_BENEFICIARY + STRONG_CUSTOMER_AUTHENTICATION_DELEGATION: :STRONG_CUSTOMER_AUTHENTICATION_DELEGATION + SECURE_CORPORATE_PAYMENT: :SECURE_CORPORATE_PAYMENT + AUTHENTICATION_OUTAGE_EXCEPTION: :AUTHENTICATION_OUTAGE_EXCEPTION + BUNDLED: :BUNDLED + + def self?.values: -> ::Array[Lithic::Models::ThreeDSAuthentication::Psd2Context::acquirer_exemption] + end + + type lithic_exemption_validation = + :ACCEPTED | :REJECTED | :NOT_VALIDATED + + module LithicExemptionValidation + extend Lithic::Internal::Type::Enum + + ACCEPTED: :ACCEPTED + REJECTED: :REJECTED + NOT_VALIDATED: :NOT_VALIDATED + + def self?.values: -> ::Array[Lithic::Models::ThreeDSAuthentication::Psd2Context::lithic_exemption_validation] + end + end + type three_ri_request_type = :ACCOUNT_VERIFICATION | :ADD_CARD diff --git a/test/lithic/resources/three_ds/authentication_test.rb b/test/lithic/resources/three_ds/authentication_test.rb index db205363..0458458d 100644 --- a/test/lithic/resources/three_ds/authentication_test.rb +++ b/test/lithic/resources/three_ds/authentication_test.rb @@ -30,6 +30,7 @@ def test_retrieve challenge_metadata: Lithic::ThreeDSAuthentication::ChallengeMetadata | nil, challenge_orchestrated_by: Lithic::ThreeDSAuthentication::ChallengeOrchestratedBy | nil, decision_made_by: Lithic::ThreeDSAuthentication::DecisionMadeBy | nil, + psd2_context: Lithic::ThreeDSAuthentication::Psd2Context | nil, three_ri_request_type: Lithic::ThreeDSAuthentication::ThreeRiRequestType | nil, transaction: Lithic::ThreeDSAuthentication::Transaction | nil } From 2fc8f3b93ff2e392d8eda8e343d21e423c214191 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 15 Sep 2026 18:00:20 +0000 Subject: [PATCH 08/14] feat: [CARDS-5174] Add reiusse/renew 409 error --- .stats.yml | 4 ++-- lib/lithic/resources/cards.rb | 6 ++++-- rbi/lithic/resources/cards.rbi | 6 ++++-- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/.stats.yml b/.stats.yml index 36ae0494..c5508542 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 218 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-e1085922e2d7ee4ce3122f1d9dfe675877f5551a591630592cfea38bd6fea9ed.yml -openapi_spec_hash: e9ca63bde70f9e3953e0a135e7daf185 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-d25e38eb235b2a76fb0920a6316f134eeb541476224cf9d2b8bf7e899d06f9f4.yml +openapi_spec_hash: 7b64684e889ae161a1354dc34f3499dd config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 diff --git a/lib/lithic/resources/cards.rb b/lib/lithic/resources/cards.rb index 41dccc8c..b50fe370 100644 --- a/lib/lithic/resources/cards.rb +++ b/lib/lithic/resources/cards.rb @@ -361,7 +361,8 @@ def reassign_account(card_token, params) # physically damaged). The PAN, expiry, and CVC2 will remain the same and the # original card can continue to be used until the new card is activated. Only # applies to cards of type `PHYSICAL`. A card can be reissued or renewed a total - # of 8 times. + # of 8 times. Returns `409` if the card is still ongoing manufacturing when using + # Thales as a manufacturer. # # @overload reissue(card_token, carrier: nil, product_id: nil, shipping_address: nil, shipping_method: nil, request_options: {}) # @@ -402,7 +403,8 @@ def reissue(card_token, params = {}) # `PHYSICAL` card can be reissued or renewed a total of 8 times. For `VIRTUAL`, # the card will retain the same card token and PAN and receive an updated expiry # and CVC2 code. `product_id`, `shipping_method`, `shipping_address`, `carrier` - # are only relevant for renewing `PHYSICAL` cards. + # are only relevant for renewing `PHYSICAL` cards. Returns `409` if the card is + # still ongoing manufacturing when using Thales as a manufacturer. # # @overload renew(card_token, shipping_address:, carrier: nil, exp_month: nil, exp_year: nil, product_id: nil, shipping_method: nil, request_options: {}) # diff --git a/rbi/lithic/resources/cards.rbi b/rbi/lithic/resources/cards.rbi index f1a6a6ac..b64f989a 100644 --- a/rbi/lithic/resources/cards.rbi +++ b/rbi/lithic/resources/cards.rbi @@ -512,7 +512,8 @@ module Lithic # physically damaged). The PAN, expiry, and CVC2 will remain the same and the # original card can continue to be used until the new card is activated. Only # applies to cards of type `PHYSICAL`. A card can be reissued or renewed a total - # of 8 times. + # of 8 times. Returns `409` if the card is still ongoing manufacturing when using + # Thales as a manufacturer. sig do params( card_token: String, @@ -562,7 +563,8 @@ module Lithic # `PHYSICAL` card can be reissued or renewed a total of 8 times. For `VIRTUAL`, # the card will retain the same card token and PAN and receive an updated expiry # and CVC2 code. `product_id`, `shipping_method`, `shipping_address`, `carrier` - # are only relevant for renewing `PHYSICAL` cards. + # are only relevant for renewing `PHYSICAL` cards. Returns `409` if the card is + # still ongoing manufacturing when using Thales as a manufacturer. sig do params( card_token: String, From 766c658645a79accfca85707ce6d5c087d93959e Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 15 Sep 2026 18:30:32 +0000 Subject: [PATCH 09/14] feat(api): add STABLECOIN_REVIEWED event type to payment simulate action --- .stats.yml | 4 ++-- lib/lithic/models/payment_simulate_action_params.rb | 1 + rbi/lithic/models/payment_simulate_action_params.rbi | 5 +++++ sig/lithic/models/payment_simulate_action_params.rbs | 2 ++ 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index c5508542..50c924c0 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 218 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-d25e38eb235b2a76fb0920a6316f134eeb541476224cf9d2b8bf7e899d06f9f4.yml -openapi_spec_hash: 7b64684e889ae161a1354dc34f3499dd +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-da0eed08089ca63f636cb174cdabe65591f65bb8a16bd5db94439834cc509044.yml +openapi_spec_hash: 2f7de4d9c35540a1d0163b75b4c08f6d config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 diff --git a/lib/lithic/models/payment_simulate_action_params.rb b/lib/lithic/models/payment_simulate_action_params.rb index defe97db..a70272d1 100644 --- a/lib/lithic/models/payment_simulate_action_params.rb +++ b/lib/lithic/models/payment_simulate_action_params.rb @@ -71,6 +71,7 @@ module EventType ACH_RETURN_INITIATED = :ACH_RETURN_INITIATED ACH_RETURN_PROCESSED = :ACH_RETURN_PROCESSED ACH_RETURN_SETTLED = :ACH_RETURN_SETTLED + STABLECOIN_REVIEWED = :STABLECOIN_REVIEWED # @!method self.values # @return [Array] diff --git a/rbi/lithic/models/payment_simulate_action_params.rbi b/rbi/lithic/models/payment_simulate_action_params.rbi index d3790ffc..15c65e3a 100644 --- a/rbi/lithic/models/payment_simulate_action_params.rbi +++ b/rbi/lithic/models/payment_simulate_action_params.rbi @@ -163,6 +163,11 @@ module Lithic :ACH_RETURN_SETTLED, Lithic::PaymentSimulateActionParams::EventType::TaggedSymbol ) + STABLECOIN_REVIEWED = + T.let( + :STABLECOIN_REVIEWED, + Lithic::PaymentSimulateActionParams::EventType::TaggedSymbol + ) sig do override.returns( diff --git a/sig/lithic/models/payment_simulate_action_params.rbs b/sig/lithic/models/payment_simulate_action_params.rbs index c1823c6d..ba7eedb7 100644 --- a/sig/lithic/models/payment_simulate_action_params.rbs +++ b/sig/lithic/models/payment_simulate_action_params.rbs @@ -68,6 +68,7 @@ module Lithic | :ACH_RETURN_INITIATED | :ACH_RETURN_PROCESSED | :ACH_RETURN_SETTLED + | :STABLECOIN_REVIEWED module EventType extend Lithic::Internal::Type::Enum @@ -82,6 +83,7 @@ module Lithic ACH_RETURN_INITIATED: :ACH_RETURN_INITIATED ACH_RETURN_PROCESSED: :ACH_RETURN_PROCESSED ACH_RETURN_SETTLED: :ACH_RETURN_SETTLED + STABLECOIN_REVIEWED: :STABLECOIN_REVIEWED def self?.values: -> ::Array[Lithic::Models::PaymentSimulateActionParams::event_type] end From e784b275c2690eb0d2ab4a36a3ee9f5af2f79b0b Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Tue, 15 Sep 2026 19:22:58 +0000 Subject: [PATCH 10/14] feat: AUTH-3759: Add DECLINE_SCA_REQUIRED and SCA_REQUIRED enum entries --- .stats.yml | 4 ++-- lib/lithic/models/auth_rules/report_stats.rb | 1 + .../models/auth_rules/v2_list_results_response.rb | 1 + lib/lithic/models/transaction.rb | 2 ++ rbi/lithic/models/auth_rules/report_stats.rbi | 5 +++++ .../models/auth_rules/v2_list_results_response.rbi | 5 +++++ rbi/lithic/models/transaction.rbi | 10 ++++++++++ sig/lithic/models/auth_rules/report_stats.rbs | 2 ++ .../models/auth_rules/v2_list_results_response.rbs | 2 ++ sig/lithic/models/transaction.rbs | 4 ++++ 10 files changed, 34 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index 50c924c0..d986b031 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 218 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-da0eed08089ca63f636cb174cdabe65591f65bb8a16bd5db94439834cc509044.yml -openapi_spec_hash: 2f7de4d9c35540a1d0163b75b4c08f6d +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-22e6715ab0428fcbda66e78f701a4324634ac8934106a450c50a341a4ad75a39.yml +openapi_spec_hash: 3c728da2d5bf1544686a6f09a0e3e393 config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 diff --git a/lib/lithic/models/auth_rules/report_stats.rb b/lib/lithic/models/auth_rules/report_stats.rb index 1898b0a9..0881a8c3 100644 --- a/lib/lithic/models/auth_rules/report_stats.rb +++ b/lib/lithic/models/auth_rules/report_stats.rb @@ -166,6 +166,7 @@ module Code PROGRAM_SUSPENDED = :PROGRAM_SUSPENDED PROGRAM_USAGE_RESTRICTION = :PROGRAM_USAGE_RESTRICTION REVERSAL_UNMATCHED = :REVERSAL_UNMATCHED + SCA_REQUIRED = :SCA_REQUIRED SECURITY_VIOLATION = :SECURITY_VIOLATION SINGLE_USE_CARD_REATTEMPTED = :SINGLE_USE_CARD_REATTEMPTED SUSPECTED_FRAUD = :SUSPECTED_FRAUD diff --git a/lib/lithic/models/auth_rules/v2_list_results_response.rb b/lib/lithic/models/auth_rules/v2_list_results_response.rb index f5721d2f..fdb24173 100644 --- a/lib/lithic/models/auth_rules/v2_list_results_response.rb +++ b/lib/lithic/models/auth_rules/v2_list_results_response.rb @@ -182,6 +182,7 @@ module Code PROGRAM_SUSPENDED = :PROGRAM_SUSPENDED PROGRAM_USAGE_RESTRICTION = :PROGRAM_USAGE_RESTRICTION REVERSAL_UNMATCHED = :REVERSAL_UNMATCHED + SCA_REQUIRED = :SCA_REQUIRED SECURITY_VIOLATION = :SECURITY_VIOLATION SINGLE_USE_CARD_REATTEMPTED = :SINGLE_USE_CARD_REATTEMPTED SUSPECTED_FRAUD = :SUSPECTED_FRAUD diff --git a/lib/lithic/models/transaction.rb b/lib/lithic/models/transaction.rb index 428527c0..1697476c 100644 --- a/lib/lithic/models/transaction.rb +++ b/lib/lithic/models/transaction.rb @@ -1060,6 +1060,7 @@ module DetailedResult PROGRAM_SUSPENDED = :PROGRAM_SUSPENDED PROGRAM_USAGE_RESTRICTION = :PROGRAM_USAGE_RESTRICTION REVERSAL_UNMATCHED = :REVERSAL_UNMATCHED + SCA_REQUIRED = :SCA_REQUIRED SECURITY_VIOLATION = :SECURITY_VIOLATION SINGLE_USE_CARD_REATTEMPTED = :SINGLE_USE_CARD_REATTEMPTED SUSPECTED_FRAUD = :SUSPECTED_FRAUD @@ -1390,6 +1391,7 @@ module Result PROGRAM_SUSPENDED = :PROGRAM_SUSPENDED PROGRAM_USAGE_RESTRICTION = :PROGRAM_USAGE_RESTRICTION REVERSAL_UNMATCHED = :REVERSAL_UNMATCHED + SCA_REQUIRED = :SCA_REQUIRED SECURITY_VIOLATION = :SECURITY_VIOLATION SINGLE_USE_CARD_REATTEMPTED = :SINGLE_USE_CARD_REATTEMPTED SUSPECTED_FRAUD = :SUSPECTED_FRAUD diff --git a/rbi/lithic/models/auth_rules/report_stats.rbi b/rbi/lithic/models/auth_rules/report_stats.rbi index 00452eba..e0ad7b70 100644 --- a/rbi/lithic/models/auth_rules/report_stats.rbi +++ b/rbi/lithic/models/auth_rules/report_stats.rbi @@ -453,6 +453,11 @@ module Lithic :REVERSAL_UNMATCHED, Lithic::AuthRules::ReportStats::Example::Action::DeclineActionAuthorization::Code::TaggedSymbol ) + SCA_REQUIRED = + T.let( + :SCA_REQUIRED, + Lithic::AuthRules::ReportStats::Example::Action::DeclineActionAuthorization::Code::TaggedSymbol + ) SECURITY_VIOLATION = T.let( :SECURITY_VIOLATION, diff --git a/rbi/lithic/models/auth_rules/v2_list_results_response.rbi b/rbi/lithic/models/auth_rules/v2_list_results_response.rbi index e8df13df..578b68dd 100644 --- a/rbi/lithic/models/auth_rules/v2_list_results_response.rbi +++ b/rbi/lithic/models/auth_rules/v2_list_results_response.rbi @@ -455,6 +455,11 @@ module Lithic :REVERSAL_UNMATCHED, Lithic::Models::AuthRules::V2ListResultsResponse::AuthorizationResult::Action::DeclineActionAuthorization::Code::TaggedSymbol ) + SCA_REQUIRED = + T.let( + :SCA_REQUIRED, + Lithic::Models::AuthRules::V2ListResultsResponse::AuthorizationResult::Action::DeclineActionAuthorization::Code::TaggedSymbol + ) SECURITY_VIOLATION = T.let( :SECURITY_VIOLATION, diff --git a/rbi/lithic/models/transaction.rbi b/rbi/lithic/models/transaction.rbi index 9878c97a..197f9527 100644 --- a/rbi/lithic/models/transaction.rbi +++ b/rbi/lithic/models/transaction.rbi @@ -2079,6 +2079,11 @@ module Lithic :REVERSAL_UNMATCHED, Lithic::Transaction::Event::DetailedResult::TaggedSymbol ) + SCA_REQUIRED = + T.let( + :SCA_REQUIRED, + Lithic::Transaction::Event::DetailedResult::TaggedSymbol + ) SECURITY_VIOLATION = T.let( :SECURITY_VIOLATION, @@ -2982,6 +2987,11 @@ module Lithic :REVERSAL_UNMATCHED, Lithic::Transaction::Event::RuleResult::Result::TaggedSymbol ) + SCA_REQUIRED = + T.let( + :SCA_REQUIRED, + Lithic::Transaction::Event::RuleResult::Result::TaggedSymbol + ) SECURITY_VIOLATION = T.let( :SECURITY_VIOLATION, diff --git a/sig/lithic/models/auth_rules/report_stats.rbs b/sig/lithic/models/auth_rules/report_stats.rbs index f2080b06..1a0d83a0 100644 --- a/sig/lithic/models/auth_rules/report_stats.rbs +++ b/sig/lithic/models/auth_rules/report_stats.rbs @@ -143,6 +143,7 @@ module Lithic | :PROGRAM_SUSPENDED | :PROGRAM_USAGE_RESTRICTION | :REVERSAL_UNMATCHED + | :SCA_REQUIRED | :SECURITY_VIOLATION | :SINGLE_USE_CARD_REATTEMPTED | :SUSPECTED_FRAUD @@ -204,6 +205,7 @@ module Lithic PROGRAM_SUSPENDED: :PROGRAM_SUSPENDED PROGRAM_USAGE_RESTRICTION: :PROGRAM_USAGE_RESTRICTION REVERSAL_UNMATCHED: :REVERSAL_UNMATCHED + SCA_REQUIRED: :SCA_REQUIRED SECURITY_VIOLATION: :SECURITY_VIOLATION SINGLE_USE_CARD_REATTEMPTED: :SINGLE_USE_CARD_REATTEMPTED SUSPECTED_FRAUD: :SUSPECTED_FRAUD diff --git a/sig/lithic/models/auth_rules/v2_list_results_response.rbs b/sig/lithic/models/auth_rules/v2_list_results_response.rbs index dd15bb09..069a322a 100644 --- a/sig/lithic/models/auth_rules/v2_list_results_response.rbs +++ b/sig/lithic/models/auth_rules/v2_list_results_response.rbs @@ -150,6 +150,7 @@ module Lithic | :PROGRAM_SUSPENDED | :PROGRAM_USAGE_RESTRICTION | :REVERSAL_UNMATCHED + | :SCA_REQUIRED | :SECURITY_VIOLATION | :SINGLE_USE_CARD_REATTEMPTED | :SUSPECTED_FRAUD @@ -211,6 +212,7 @@ module Lithic PROGRAM_SUSPENDED: :PROGRAM_SUSPENDED PROGRAM_USAGE_RESTRICTION: :PROGRAM_USAGE_RESTRICTION REVERSAL_UNMATCHED: :REVERSAL_UNMATCHED + SCA_REQUIRED: :SCA_REQUIRED SECURITY_VIOLATION: :SECURITY_VIOLATION SINGLE_USE_CARD_REATTEMPTED: :SINGLE_USE_CARD_REATTEMPTED SUSPECTED_FRAUD: :SUSPECTED_FRAUD diff --git a/sig/lithic/models/transaction.rbs b/sig/lithic/models/transaction.rbs index 9cbb5dc9..1a66a8da 100644 --- a/sig/lithic/models/transaction.rbs +++ b/sig/lithic/models/transaction.rbs @@ -892,6 +892,7 @@ module Lithic | :PROGRAM_SUSPENDED | :PROGRAM_USAGE_RESTRICTION | :REVERSAL_UNMATCHED + | :SCA_REQUIRED | :SECURITY_VIOLATION | :SINGLE_USE_CARD_REATTEMPTED | :SUSPECTED_FRAUD @@ -953,6 +954,7 @@ module Lithic PROGRAM_SUSPENDED: :PROGRAM_SUSPENDED PROGRAM_USAGE_RESTRICTION: :PROGRAM_USAGE_RESTRICTION REVERSAL_UNMATCHED: :REVERSAL_UNMATCHED + SCA_REQUIRED: :SCA_REQUIRED SECURITY_VIOLATION: :SECURITY_VIOLATION SINGLE_USE_CARD_REATTEMPTED: :SINGLE_USE_CARD_REATTEMPTED SUSPECTED_FRAUD: :SUSPECTED_FRAUD @@ -1240,6 +1242,7 @@ module Lithic | :PROGRAM_SUSPENDED | :PROGRAM_USAGE_RESTRICTION | :REVERSAL_UNMATCHED + | :SCA_REQUIRED | :SECURITY_VIOLATION | :SINGLE_USE_CARD_REATTEMPTED | :SUSPECTED_FRAUD @@ -1301,6 +1304,7 @@ module Lithic PROGRAM_SUSPENDED: :PROGRAM_SUSPENDED PROGRAM_USAGE_RESTRICTION: :PROGRAM_USAGE_RESTRICTION REVERSAL_UNMATCHED: :REVERSAL_UNMATCHED + SCA_REQUIRED: :SCA_REQUIRED SECURITY_VIOLATION: :SECURITY_VIOLATION SINGLE_USE_CARD_REATTEMPTED: :SINGLE_USE_CARD_REATTEMPTED SUSPECTED_FRAUD: :SUSPECTED_FRAUD From 04690f1542cb3f213da8695507a371c4f0a5aed4 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 16 Sep 2026 13:56:20 +0000 Subject: [PATCH 11/14] feat(api): add FEE/FEE_REVERSAL to financial_event, statement_line_items, management_operation --- .stats.yml | 4 ++-- .../statements/statement_line_items.rb | 2 ++ lib/lithic/models/financial_event.rb | 2 ++ .../models/management_operation_create_params.rb | 2 ++ lib/lithic/models/management_operation_transaction.rb | 2 ++ .../statements/statement_line_items.rbi | 10 ++++++++++ rbi/lithic/models/financial_event.rbi | 3 +++ .../models/management_operation_create_params.rbi | 10 ++++++++++ rbi/lithic/models/management_operation_transaction.rbi | 10 ++++++++++ .../statements/statement_line_items.rbs | 4 ++++ sig/lithic/models/financial_event.rbs | 4 ++++ .../models/management_operation_create_params.rbs | 4 ++++ sig/lithic/models/management_operation_transaction.rbs | 4 ++++ 13 files changed, 59 insertions(+), 2 deletions(-) diff --git a/.stats.yml b/.stats.yml index d986b031..50b5107a 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 218 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-22e6715ab0428fcbda66e78f701a4324634ac8934106a450c50a341a4ad75a39.yml -openapi_spec_hash: 3c728da2d5bf1544686a6f09a0e3e393 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-cc426da9e5047cbcd8e764a20ea1afd35c685ebaedc87128f0a22f9f05ae1537.yml +openapi_spec_hash: 731d6efde305387fde11ba31972f176b config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 diff --git a/lib/lithic/models/financial_accounts/statements/statement_line_items.rb b/lib/lithic/models/financial_accounts/statements/statement_line_items.rb index 7dda6b61..d16f2f9a 100644 --- a/lib/lithic/models/financial_accounts/statements/statement_line_items.rb +++ b/lib/lithic/models/financial_accounts/statements/statement_line_items.rb @@ -250,6 +250,8 @@ module EventType EXTERNAL_WIRE_RELEASED = :EXTERNAL_WIRE_RELEASED EXTERNAL_WIRE_REVERSED = :EXTERNAL_WIRE_REVERSED EXTERNAL_WIRE_SETTLED = :EXTERNAL_WIRE_SETTLED + FEE = :FEE + FEE_REVERSAL = :FEE_REVERSAL FINANCIAL_AUTHORIZATION = :FINANCIAL_AUTHORIZATION FINANCIAL_CREDIT_AUTHORIZATION = :FINANCIAL_CREDIT_AUTHORIZATION INSTALLMENT_FEE = :INSTALLMENT_FEE diff --git a/lib/lithic/models/financial_event.rb b/lib/lithic/models/financial_event.rb index 17fe92d7..a5d9ba34 100644 --- a/lib/lithic/models/financial_event.rb +++ b/lib/lithic/models/financial_event.rb @@ -136,6 +136,8 @@ module Type EXTERNAL_WIRE_RELEASED = :EXTERNAL_WIRE_RELEASED EXTERNAL_WIRE_REVERSED = :EXTERNAL_WIRE_REVERSED EXTERNAL_WIRE_SETTLED = :EXTERNAL_WIRE_SETTLED + FEE = :FEE + FEE_REVERSAL = :FEE_REVERSAL FINANCIAL_AUTHORIZATION = :FINANCIAL_AUTHORIZATION FINANCIAL_CREDIT_AUTHORIZATION = :FINANCIAL_CREDIT_AUTHORIZATION INSTALLMENT_FEE = :INSTALLMENT_FEE diff --git a/lib/lithic/models/management_operation_create_params.rb b/lib/lithic/models/management_operation_create_params.rb index 63304757..3b680580 100644 --- a/lib/lithic/models/management_operation_create_params.rb +++ b/lib/lithic/models/management_operation_create_params.rb @@ -146,6 +146,8 @@ module EventType QUARTERLY_REVERSAL = :QUARTERLY_REVERSAL MONTHLY = :MONTHLY MONTHLY_REVERSAL = :MONTHLY_REVERSAL + FEE = :FEE + FEE_REVERSAL = :FEE_REVERSAL # @!method self.values # @return [Array] diff --git a/lib/lithic/models/management_operation_transaction.rb b/lib/lithic/models/management_operation_transaction.rb index 129d198d..687be48c 100644 --- a/lib/lithic/models/management_operation_transaction.rb +++ b/lib/lithic/models/management_operation_transaction.rb @@ -279,6 +279,8 @@ module Type QUARTERLY_REVERSAL = :QUARTERLY_REVERSAL MONTHLY = :MONTHLY MONTHLY_REVERSAL = :MONTHLY_REVERSAL + FEE = :FEE + FEE_REVERSAL = :FEE_REVERSAL # @!method self.values # @return [Array] diff --git a/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi b/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi index 269f707c..85476545 100644 --- a/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi +++ b/rbi/lithic/models/financial_accounts/statements/statement_line_items.rbi @@ -712,6 +712,16 @@ module Lithic :EXTERNAL_WIRE_SETTLED, Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol ) + FEE = + T.let( + :FEE, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) + FEE_REVERSAL = + T.let( + :FEE_REVERSAL, + Lithic::FinancialAccounts::Statements::StatementLineItems::Data::EventType::TaggedSymbol + ) FINANCIAL_AUTHORIZATION = T.let( :FINANCIAL_AUTHORIZATION, diff --git a/rbi/lithic/models/financial_event.rbi b/rbi/lithic/models/financial_event.rbi index 2fb61a5f..35527736 100644 --- a/rbi/lithic/models/financial_event.rbi +++ b/rbi/lithic/models/financial_event.rbi @@ -416,6 +416,9 @@ module Lithic :EXTERNAL_WIRE_SETTLED, Lithic::FinancialEvent::Type::TaggedSymbol ) + FEE = T.let(:FEE, Lithic::FinancialEvent::Type::TaggedSymbol) + FEE_REVERSAL = + T.let(:FEE_REVERSAL, Lithic::FinancialEvent::Type::TaggedSymbol) FINANCIAL_AUTHORIZATION = T.let( :FINANCIAL_AUTHORIZATION, diff --git a/rbi/lithic/models/management_operation_create_params.rbi b/rbi/lithic/models/management_operation_create_params.rbi index 402cce6f..b3fff126 100644 --- a/rbi/lithic/models/management_operation_create_params.rbi +++ b/rbi/lithic/models/management_operation_create_params.rbi @@ -366,6 +366,16 @@ module Lithic :MONTHLY_REVERSAL, Lithic::ManagementOperationCreateParams::EventType::TaggedSymbol ) + FEE = + T.let( + :FEE, + Lithic::ManagementOperationCreateParams::EventType::TaggedSymbol + ) + FEE_REVERSAL = + T.let( + :FEE_REVERSAL, + Lithic::ManagementOperationCreateParams::EventType::TaggedSymbol + ) sig do override.returns( diff --git a/rbi/lithic/models/management_operation_transaction.rbi b/rbi/lithic/models/management_operation_transaction.rbi index f0eec44d..521173de 100644 --- a/rbi/lithic/models/management_operation_transaction.rbi +++ b/rbi/lithic/models/management_operation_transaction.rbi @@ -692,6 +692,16 @@ module Lithic :MONTHLY_REVERSAL, Lithic::ManagementOperationTransaction::Event::Type::TaggedSymbol ) + FEE = + T.let( + :FEE, + Lithic::ManagementOperationTransaction::Event::Type::TaggedSymbol + ) + FEE_REVERSAL = + T.let( + :FEE_REVERSAL, + Lithic::ManagementOperationTransaction::Event::Type::TaggedSymbol + ) sig do override.returns( diff --git a/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs b/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs index e8ea5871..b3163189 100644 --- a/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs +++ b/sig/lithic/models/financial_accounts/statements/statement_line_items.rbs @@ -236,6 +236,8 @@ module Lithic | :EXTERNAL_WIRE_RELEASED | :EXTERNAL_WIRE_REVERSED | :EXTERNAL_WIRE_SETTLED + | :FEE + | :FEE_REVERSAL | :FINANCIAL_AUTHORIZATION | :FINANCIAL_CREDIT_AUTHORIZATION | :INSTALLMENT_FEE @@ -343,6 +345,8 @@ module Lithic EXTERNAL_WIRE_RELEASED: :EXTERNAL_WIRE_RELEASED EXTERNAL_WIRE_REVERSED: :EXTERNAL_WIRE_REVERSED EXTERNAL_WIRE_SETTLED: :EXTERNAL_WIRE_SETTLED + FEE: :FEE + FEE_REVERSAL: :FEE_REVERSAL FINANCIAL_AUTHORIZATION: :FINANCIAL_AUTHORIZATION FINANCIAL_CREDIT_AUTHORIZATION: :FINANCIAL_CREDIT_AUTHORIZATION INSTALLMENT_FEE: :INSTALLMENT_FEE diff --git a/sig/lithic/models/financial_event.rbs b/sig/lithic/models/financial_event.rbs index c90157ef..53a1a8e9 100644 --- a/sig/lithic/models/financial_event.rbs +++ b/sig/lithic/models/financial_event.rbs @@ -130,6 +130,8 @@ module Lithic | :EXTERNAL_WIRE_RELEASED | :EXTERNAL_WIRE_REVERSED | :EXTERNAL_WIRE_SETTLED + | :FEE + | :FEE_REVERSAL | :FINANCIAL_AUTHORIZATION | :FINANCIAL_CREDIT_AUTHORIZATION | :INSTALLMENT_FEE @@ -237,6 +239,8 @@ module Lithic EXTERNAL_WIRE_RELEASED: :EXTERNAL_WIRE_RELEASED EXTERNAL_WIRE_REVERSED: :EXTERNAL_WIRE_REVERSED EXTERNAL_WIRE_SETTLED: :EXTERNAL_WIRE_SETTLED + FEE: :FEE + FEE_REVERSAL: :FEE_REVERSAL FINANCIAL_AUTHORIZATION: :FINANCIAL_AUTHORIZATION FINANCIAL_CREDIT_AUTHORIZATION: :FINANCIAL_CREDIT_AUTHORIZATION INSTALLMENT_FEE: :INSTALLMENT_FEE diff --git a/sig/lithic/models/management_operation_create_params.rbs b/sig/lithic/models/management_operation_create_params.rbs index 5e2bbce4..daa80f1e 100644 --- a/sig/lithic/models/management_operation_create_params.rbs +++ b/sig/lithic/models/management_operation_create_params.rbs @@ -142,6 +142,8 @@ module Lithic | :QUARTERLY_REVERSAL | :MONTHLY | :MONTHLY_REVERSAL + | :FEE + | :FEE_REVERSAL module EventType extend Lithic::Internal::Type::Enum @@ -173,6 +175,8 @@ module Lithic QUARTERLY_REVERSAL: :QUARTERLY_REVERSAL MONTHLY: :MONTHLY MONTHLY_REVERSAL: :MONTHLY_REVERSAL + FEE: :FEE + FEE_REVERSAL: :FEE_REVERSAL def self?.values: -> ::Array[Lithic::Models::ManagementOperationCreateParams::event_type] end diff --git a/sig/lithic/models/management_operation_transaction.rbs b/sig/lithic/models/management_operation_transaction.rbs index 762e67d6..dd811956 100644 --- a/sig/lithic/models/management_operation_transaction.rbs +++ b/sig/lithic/models/management_operation_transaction.rbs @@ -271,6 +271,8 @@ module Lithic | :QUARTERLY_REVERSAL | :MONTHLY | :MONTHLY_REVERSAL + | :FEE + | :FEE_REVERSAL module Type extend Lithic::Internal::Type::Enum @@ -302,6 +304,8 @@ module Lithic QUARTERLY_REVERSAL: :QUARTERLY_REVERSAL MONTHLY: :MONTHLY MONTHLY_REVERSAL: :MONTHLY_REVERSAL + FEE: :FEE + FEE_REVERSAL: :FEE_REVERSAL def self?.values: -> ::Array[Lithic::Models::ManagementOperationTransaction::Event::type_] end From 6031d6794afd8c3a4b121cf2f7368e0ac40867c0 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Wed, 16 Sep 2026 21:46:03 +0000 Subject: [PATCH 12/14] feat: [TRE-14464] Update /retry payments endpoint to accept method --- .stats.yml | 4 +- lib/lithic/models/payment_retry_params.rb | 29 ++++++++++++- lib/lithic/resources/payments.rb | 12 +++++- rbi/lithic/models/payment_retry_params.rbi | 49 +++++++++++++++++++++- rbi/lithic/resources/payments.rbi | 10 ++++- sig/lithic/models/payment_retry_params.rbs | 25 ++++++++++- sig/lithic/resources/payments.rbs | 1 + 7 files changed, 121 insertions(+), 9 deletions(-) diff --git a/.stats.yml b/.stats.yml index 50b5107a..ce934163 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 218 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-cc426da9e5047cbcd8e764a20ea1afd35c685ebaedc87128f0a22f9f05ae1537.yml -openapi_spec_hash: 731d6efde305387fde11ba31972f176b +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-701e31821e8acdd56e8afce852fd2207ef6962cc314fdc1e9d814adf8aae8e1f.yml +openapi_spec_hash: ddf405339b9f603c2ebc58a0a168bfbd config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 diff --git a/lib/lithic/models/payment_retry_params.rb b/lib/lithic/models/payment_retry_params.rb index a05f70db..58821faf 100644 --- a/lib/lithic/models/payment_retry_params.rb +++ b/lib/lithic/models/payment_retry_params.rb @@ -12,9 +12,36 @@ class PaymentRetryParams < Lithic::Internal::Type::BaseModel # @return [String] required :payment_token, String - # @!method initialize(payment_token:, request_options: {}) + # @!attribute method_ + # Settlement speed to retry the payment at. Defaults to the original payment's + # method. An `ACH_SAME_DAY` retry is rejected if the payment is for $1,000,000.00 + # or more, or if it is submitted after the same day ACH cutoff + # + # @return [Symbol, Lithic::Models::PaymentRetryParams::Method, nil] + optional :method_, enum: -> { Lithic::PaymentRetryParams::Method }, api_name: :method + + # @!method initialize(payment_token:, method_: nil, request_options: {}) + # Some parameter documentations has been truncated, see + # {Lithic::Models::PaymentRetryParams} for more details. + # # @param payment_token [String] + # + # @param method_ [Symbol, Lithic::Models::PaymentRetryParams::Method] Settlement speed to retry the payment at. Defaults to the original payment's met + # # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}] + + # Settlement speed to retry the payment at. Defaults to the original payment's + # method. An `ACH_SAME_DAY` retry is rejected if the payment is for $1,000,000.00 + # or more, or if it is submitted after the same day ACH cutoff + module Method + extend Lithic::Internal::Type::Enum + + ACH_NEXT_DAY = :ACH_NEXT_DAY + ACH_SAME_DAY = :ACH_SAME_DAY + + # @!method self.values + # @return [Array] + end end end end diff --git a/lib/lithic/resources/payments.rb b/lib/lithic/resources/payments.rb index b20ea1df..9c4f9bda 100644 --- a/lib/lithic/resources/payments.rb +++ b/lib/lithic/resources/payments.rb @@ -172,22 +172,30 @@ def create_stablecoin(params) ) end + # Some parameter documentations has been truncated, see + # {Lithic::Models::PaymentRetryParams} for more details. + # # Retry an origination which has been returned. # - # @overload retry_(payment_token, request_options: {}) + # @overload retry_(payment_token, method_: nil, request_options: {}) # # @param payment_token [String] + # + # @param method_ [Symbol, Lithic::Models::PaymentRetryParams::Method] Settlement speed to retry the payment at. Defaults to the original payment's met + # # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}, nil] # # @return [Lithic::Models::PaymentRetryResponse] # # @see Lithic::Models::PaymentRetryParams def retry_(payment_token, params = {}) + parsed, options = Lithic::PaymentRetryParams.dump_request(params) @client.request( method: :post, path: ["v1/payments/%1$s/retry", payment_token], + body: parsed, model: Lithic::Models::PaymentRetryResponse, - options: params[:request_options] + options: options ) end diff --git a/rbi/lithic/models/payment_retry_params.rbi b/rbi/lithic/models/payment_retry_params.rbi index 17c18453..3470d4bd 100644 --- a/rbi/lithic/models/payment_retry_params.rbi +++ b/rbi/lithic/models/payment_retry_params.rbi @@ -14,22 +14,67 @@ module Lithic sig { returns(String) } attr_accessor :payment_token + # Settlement speed to retry the payment at. Defaults to the original payment's + # method. An `ACH_SAME_DAY` retry is rejected if the payment is for $1,000,000.00 + # or more, or if it is submitted after the same day ACH cutoff + sig { returns(T.nilable(Lithic::PaymentRetryParams::Method::OrSymbol)) } + attr_reader :method_ + + sig { params(method_: Lithic::PaymentRetryParams::Method::OrSymbol).void } + attr_writer :method_ + sig do params( payment_token: String, + method_: Lithic::PaymentRetryParams::Method::OrSymbol, request_options: Lithic::RequestOptions::OrHash ).returns(T.attached_class) end - def self.new(payment_token:, request_options: {}) + def self.new( + payment_token:, + # Settlement speed to retry the payment at. Defaults to the original payment's + # method. An `ACH_SAME_DAY` retry is rejected if the payment is for $1,000,000.00 + # or more, or if it is submitted after the same day ACH cutoff + method_: nil, + request_options: {} + ) end sig do override.returns( - { payment_token: String, request_options: Lithic::RequestOptions } + { + payment_token: String, + method_: Lithic::PaymentRetryParams::Method::OrSymbol, + request_options: Lithic::RequestOptions + } ) end def to_hash end + + # Settlement speed to retry the payment at. Defaults to the original payment's + # method. An `ACH_SAME_DAY` retry is rejected if the payment is for $1,000,000.00 + # or more, or if it is submitted after the same day ACH cutoff + module Method + extend Lithic::Internal::Type::Enum + + TaggedSymbol = + T.type_alias { T.all(Symbol, Lithic::PaymentRetryParams::Method) } + OrSymbol = T.type_alias { T.any(Symbol, String) } + + ACH_NEXT_DAY = + T.let(:ACH_NEXT_DAY, Lithic::PaymentRetryParams::Method::TaggedSymbol) + ACH_SAME_DAY = + T.let(:ACH_SAME_DAY, Lithic::PaymentRetryParams::Method::TaggedSymbol) + + sig do + override.returns( + T::Array[Lithic::PaymentRetryParams::Method::TaggedSymbol] + ) + end + def self.values + end + end end end end diff --git a/rbi/lithic/resources/payments.rbi b/rbi/lithic/resources/payments.rbi index 6c60171d..69b883db 100644 --- a/rbi/lithic/resources/payments.rbi +++ b/rbi/lithic/resources/payments.rbi @@ -152,10 +152,18 @@ module Lithic sig do params( payment_token: String, + method_: Lithic::PaymentRetryParams::Method::OrSymbol, request_options: Lithic::RequestOptions::OrHash ).returns(Lithic::Models::PaymentRetryResponse) end - def retry_(payment_token, request_options: {}) + def retry_( + payment_token, + # Settlement speed to retry the payment at. Defaults to the original payment's + # method. An `ACH_SAME_DAY` retry is rejected if the payment is for $1,000,000.00 + # or more, or if it is submitted after the same day ACH cutoff + method_: nil, + request_options: {} + ) end # Return an ACH payment with a specified return reason code. Returns must be diff --git a/sig/lithic/models/payment_retry_params.rbs b/sig/lithic/models/payment_retry_params.rbs index f81b9afc..99db9838 100644 --- a/sig/lithic/models/payment_retry_params.rbs +++ b/sig/lithic/models/payment_retry_params.rbs @@ -1,7 +1,11 @@ module Lithic module Models type payment_retry_params = - { payment_token: String } & Lithic::Internal::Type::request_parameters + { + payment_token: String, + method_: Lithic::Models::PaymentRetryParams::method_ + } + & Lithic::Internal::Type::request_parameters class PaymentRetryParams < Lithic::Internal::Type::BaseModel extend Lithic::Internal::Type::RequestParameters::Converter @@ -9,15 +13,34 @@ module Lithic attr_accessor payment_token: String + attr_reader method_: Lithic::Models::PaymentRetryParams::method_? + + def method_=: ( + Lithic::Models::PaymentRetryParams::method_ + ) -> Lithic::Models::PaymentRetryParams::method_ + def initialize: ( payment_token: String, + ?method_: Lithic::Models::PaymentRetryParams::method_, ?request_options: Lithic::request_opts ) -> void def to_hash: -> { payment_token: String, + method_: Lithic::Models::PaymentRetryParams::method_, request_options: Lithic::RequestOptions } + + type method_ = :ACH_NEXT_DAY | :ACH_SAME_DAY + + module Method + extend Lithic::Internal::Type::Enum + + ACH_NEXT_DAY: :ACH_NEXT_DAY + ACH_SAME_DAY: :ACH_SAME_DAY + + def self?.values: -> ::Array[Lithic::Models::PaymentRetryParams::method_] + end end end end diff --git a/sig/lithic/resources/payments.rbs b/sig/lithic/resources/payments.rbs index d46f5168..c426e840 100644 --- a/sig/lithic/resources/payments.rbs +++ b/sig/lithic/resources/payments.rbs @@ -48,6 +48,7 @@ module Lithic def retry_: ( String payment_token, + ?method_: Lithic::Models::PaymentRetryParams::method_, ?request_options: Lithic::request_opts ) -> Lithic::Models::PaymentRetryResponse From bdf043e53ac45964c091134b25fb7a3023948397 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 17 Sep 2026 20:15:07 +0000 Subject: [PATCH 13/14] feat: [TRE-14524] Add Open to buy API spec --- .stats.yml | 8 +- lib/lithic.rb | 4 + .../models/financial_accounts/open_to_buy.rb | 36 +++++++++ .../open_to_buy_retrieve_params.rb | 22 ++++++ .../financial_accounts/open_to_buy_summary.rb | 46 ++++++++++++ lib/lithic/resources/financial_accounts.rb | 4 + .../financial_accounts/open_to_buy.rb | 48 ++++++++++++ .../models/financial_accounts/open_to_buy.rbi | 64 ++++++++++++++++ .../open_to_buy_retrieve_params.rbi | 43 +++++++++++ .../open_to_buy_summary.rbi | 73 +++++++++++++++++++ rbi/lithic/resources/financial_accounts.rbi | 3 + .../financial_accounts/open_to_buy.rbi | 40 ++++++++++ .../models/financial_accounts/open_to_buy.rbs | 27 +++++++ .../open_to_buy_retrieve_params.rbs | 26 +++++++ .../open_to_buy_summary.rbs | 32 ++++++++ sig/lithic/resources/financial_accounts.rbs | 2 + .../financial_accounts/open_to_buy.rbs | 14 ++++ .../financial_accounts/open_to_buy_test.rb | 20 +++++ 18 files changed, 508 insertions(+), 4 deletions(-) create mode 100644 lib/lithic/models/financial_accounts/open_to_buy.rb create mode 100644 lib/lithic/models/financial_accounts/open_to_buy_retrieve_params.rb create mode 100644 lib/lithic/models/financial_accounts/open_to_buy_summary.rb create mode 100644 lib/lithic/resources/financial_accounts/open_to_buy.rb create mode 100644 rbi/lithic/models/financial_accounts/open_to_buy.rbi create mode 100644 rbi/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbi create mode 100644 rbi/lithic/models/financial_accounts/open_to_buy_summary.rbi create mode 100644 rbi/lithic/resources/financial_accounts/open_to_buy.rbi create mode 100644 sig/lithic/models/financial_accounts/open_to_buy.rbs create mode 100644 sig/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbs create mode 100644 sig/lithic/models/financial_accounts/open_to_buy_summary.rbs create mode 100644 sig/lithic/resources/financial_accounts/open_to_buy.rbs create mode 100644 test/lithic/resources/financial_accounts/open_to_buy_test.rb diff --git a/.stats.yml b/.stats.yml index ce934163..c48be9d8 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ -configured_endpoints: 218 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-701e31821e8acdd56e8afce852fd2207ef6962cc314fdc1e9d814adf8aae8e1f.yml -openapi_spec_hash: ddf405339b9f603c2ebc58a0a168bfbd -config_hash: b314c3c5c82a483d1a7812b31b1d1fc4 +configured_endpoints: 219 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-18e08b593c738bb6a429fe225dac7c4bf5d161a7dbb003e495b87a21d2aff6a8.yml +openapi_spec_hash: b6f308ea5a6d9ad9c22c14e7574d9669 +config_hash: 0cfee7faa13d28e91697e2d79c50935e diff --git a/lib/lithic.rb b/lib/lithic.rb index 2f7b5acf..df406923 100644 --- a/lib/lithic.rb +++ b/lib/lithic.rb @@ -324,6 +324,7 @@ require_relative "lithic/models/financial_accounts/credit_configuration_update_params" require_relative "lithic/models/financial_accounts/financial_account_credit_config" require_relative "lithic/models/financial_accounts/loan_tape_configuration" +require_relative "lithic/models/financial_accounts/open_to_buy" require_relative "lithic/models/financial_accounts/statements" require_relative "lithic/models/financial_accounts/financial_transaction_list_params" require_relative "lithic/models/financial_accounts/financial_transaction_retrieve_params" @@ -336,6 +337,8 @@ require_relative "lithic/models/financial_accounts/loan_tape_list_params" require_relative "lithic/models/financial_accounts/loan_tape_rebuild_configuration" require_relative "lithic/models/financial_accounts/loan_tape_retrieve_params" +require_relative "lithic/models/financial_accounts/open_to_buy_retrieve_params" +require_relative "lithic/models/financial_accounts/open_to_buy_summary" require_relative "lithic/models/financial_accounts/statement_list_params" require_relative "lithic/models/financial_accounts/statement_retrieve_params" require_relative "lithic/models/financial_accounts/statements/line_item_list_params" @@ -557,6 +560,7 @@ require_relative "lithic/resources/financial_accounts/interest_tier_schedule" require_relative "lithic/resources/financial_accounts/loan_tape_configuration" require_relative "lithic/resources/financial_accounts/loan_tapes" +require_relative "lithic/resources/financial_accounts/open_to_buy" require_relative "lithic/resources/financial_accounts/statements" require_relative "lithic/resources/financial_accounts/statements/line_items" require_relative "lithic/resources/fraud" diff --git a/lib/lithic/models/financial_accounts/open_to_buy.rb b/lib/lithic/models/financial_accounts/open_to_buy.rb new file mode 100644 index 00000000..43b3af4f --- /dev/null +++ b/lib/lithic/models/financial_accounts/open_to_buy.rb @@ -0,0 +1,36 @@ +# frozen_string_literal: true + +module Lithic + module Models + module FinancialAccounts + # @see Lithic::Resources::FinancialAccounts::OpenToBuy#retrieve + class FinancialAccountsOpenToBuy < Lithic::Internal::Type::BaseModel + # @!attribute open_to_buy + # Funds available for card spend backed by this Security Account, in the + # currency's smallest unit (e.g., cents for USD). Equal to the sum of the amounts + # in `summary`, and reaches zero once outstanding spend has consumed all available + # funding + # + # @return [Integer] + required :open_to_buy, Integer + + # @!attribute summary + # Balances that open to buy is derived from + # + # @return [Lithic::Models::FinancialAccounts::OpenToBuySummary] + required :summary, -> { Lithic::FinancialAccounts::OpenToBuySummary } + + # @!method initialize(open_to_buy:, summary:) + # Some parameter documentations has been truncated, see + # {Lithic::Models::FinancialAccounts::FinancialAccountsOpenToBuy} for more + # details. + # + # Open to Buy + # + # @param open_to_buy [Integer] Funds available for card spend backed by this Security Account, in the currency' + # + # @param summary [Lithic::Models::FinancialAccounts::OpenToBuySummary] Balances that open to buy is derived from + end + end + end +end diff --git a/lib/lithic/models/financial_accounts/open_to_buy_retrieve_params.rb b/lib/lithic/models/financial_accounts/open_to_buy_retrieve_params.rb new file mode 100644 index 00000000..9f0f0ef6 --- /dev/null +++ b/lib/lithic/models/financial_accounts/open_to_buy_retrieve_params.rb @@ -0,0 +1,22 @@ +# frozen_string_literal: true + +module Lithic + module Models + module FinancialAccounts + # @see Lithic::Resources::FinancialAccounts::OpenToBuy#retrieve + class OpenToBuyRetrieveParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + # @!attribute financial_account_token + # + # @return [String] + required :financial_account_token, String + + # @!method initialize(financial_account_token:, request_options: {}) + # @param financial_account_token [String] + # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}] + end + end + end +end diff --git a/lib/lithic/models/financial_accounts/open_to_buy_summary.rb b/lib/lithic/models/financial_accounts/open_to_buy_summary.rb new file mode 100644 index 00000000..c6545c16 --- /dev/null +++ b/lib/lithic/models/financial_accounts/open_to_buy_summary.rb @@ -0,0 +1,46 @@ +# frozen_string_literal: true + +module Lithic + module Models + module FinancialAccounts + class OpenToBuySummary < Lithic::Internal::Type::BaseModel + # @!attribute security + # Available balance of the Security Account backing card spend, in the currency's + # smallest unit (e.g., cents for USD) + # + # @return [Integer] + required :security, Integer + + # @!attribute settled_funds + # Funding that has moved out of the Security Account to cover card spend Lithic + # has already paid out to the networks, in the currency's smallest unit (e.g., + # cents for USD). Open to buy counts it alongside `security`, and it clears once + # collected from your business clients. Only Commercial Charge tracks this + # separately, so this is `null` for every other program setup + # + # @return [Integer, nil] + required :settled_funds, Integer, nil?: true + + # @!attribute total_outstanding_spend + # Customer card spend that has not yet been collected, in the currency's smallest + # unit (e.g., cents for USD). Reported as a negative amount, because it reduces + # open to buy + # + # @return [Integer] + required :total_outstanding_spend, Integer + + # @!method initialize(security:, settled_funds:, total_outstanding_spend:) + # Some parameter documentations has been truncated, see + # {Lithic::Models::FinancialAccounts::OpenToBuySummary} for more details. + # + # Open to Buy Summary + # + # @param security [Integer] Available balance of the Security Account backing card spend, in the currency's + # + # @param settled_funds [Integer, nil] Funding that has moved out of the Security Account to cover card spend Lithic ha + # + # @param total_outstanding_spend [Integer] Customer card spend that has not yet been collected, in the currency's + end + end + end +end diff --git a/lib/lithic/resources/financial_accounts.rb b/lib/lithic/resources/financial_accounts.rb index c691d921..0cf2e0b8 100644 --- a/lib/lithic/resources/financial_accounts.rb +++ b/lib/lithic/resources/financial_accounts.rb @@ -6,6 +6,9 @@ class FinancialAccounts # @return [Lithic::Resources::FinancialAccounts::Balances] attr_reader :balances + # @return [Lithic::Resources::FinancialAccounts::OpenToBuy] + attr_reader :open_to_buy + # @return [Lithic::Resources::FinancialAccounts::FinancialTransactions] attr_reader :financial_transactions @@ -184,6 +187,7 @@ def update_status(financial_account_token, params) def initialize(client:) @client = client @balances = Lithic::Resources::FinancialAccounts::Balances.new(client: client) + @open_to_buy = Lithic::Resources::FinancialAccounts::OpenToBuy.new(client: client) @financial_transactions = Lithic::Resources::FinancialAccounts::FinancialTransactions.new(client: client) @credit_configuration = Lithic::Resources::FinancialAccounts::CreditConfiguration.new(client: client) @statements = Lithic::Resources::FinancialAccounts::Statements.new(client: client) diff --git a/lib/lithic/resources/financial_accounts/open_to_buy.rb b/lib/lithic/resources/financial_accounts/open_to_buy.rb new file mode 100644 index 00000000..fff71b4a --- /dev/null +++ b/lib/lithic/resources/financial_accounts/open_to_buy.rb @@ -0,0 +1,48 @@ +# frozen_string_literal: true + +module Lithic + module Resources + class FinancialAccounts + class OpenToBuy + # Get the funds available for card spend backed by a given Security Account, along + # with the balances that amount is derived from. + # + # Open to buy is the amount Lithic authorizes card spend against. It is not a + # stored balance, so it is recalculated on every request from the Security + # Account, the funds held against spend Lithic has already paid out to the + # networks on your behalf, and the spend that has not yet been collected. The + # accounts that feed the calculation depend on your program setup, so + # `summary.settled_funds` is `null` outside Commercial Charge. + # + # Supported for Commercial Charge, Dynamic Reserve, and Secured Charge programs. + # Returns `404` if `financial_account_token` is not a Security Account you own, or + # if your program setup does not use an open to buy calculation. + # + # @overload retrieve(financial_account_token, request_options: {}) + # + # @param financial_account_token [String] Globally unique identifier for the Security Account to price + # + # @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}, nil] + # + # @return [Lithic::Models::FinancialAccounts::FinancialAccountsOpenToBuy] + # + # @see Lithic::Models::FinancialAccounts::OpenToBuyRetrieveParams + def retrieve(financial_account_token, params = {}) + @client.request( + method: :get, + path: ["v1/financial_accounts/%1$s/open_to_buy", financial_account_token], + model: Lithic::FinancialAccounts::FinancialAccountsOpenToBuy, + options: params[:request_options] + ) + end + + # @api private + # + # @param client [Lithic::Client] + def initialize(client:) + @client = client + end + end + end + end +end diff --git a/rbi/lithic/models/financial_accounts/open_to_buy.rbi b/rbi/lithic/models/financial_accounts/open_to_buy.rbi new file mode 100644 index 00000000..aecb97a2 --- /dev/null +++ b/rbi/lithic/models/financial_accounts/open_to_buy.rbi @@ -0,0 +1,64 @@ +# typed: strong + +module Lithic + module Models + module FinancialAccounts + class FinancialAccountsOpenToBuy < Lithic::Internal::Type::BaseModel + OrHash = + T.type_alias do + T.any( + Lithic::FinancialAccounts::FinancialAccountsOpenToBuy, + Lithic::Internal::AnyHash + ) + end + + # Funds available for card spend backed by this Security Account, in the + # currency's smallest unit (e.g., cents for USD). Equal to the sum of the amounts + # in `summary`, and reaches zero once outstanding spend has consumed all available + # funding + sig { returns(Integer) } + attr_accessor :open_to_buy + + # Balances that open to buy is derived from + sig { returns(Lithic::FinancialAccounts::OpenToBuySummary) } + attr_reader :summary + + sig do + params( + summary: Lithic::FinancialAccounts::OpenToBuySummary::OrHash + ).void + end + attr_writer :summary + + # Open to Buy + sig do + params( + open_to_buy: Integer, + summary: Lithic::FinancialAccounts::OpenToBuySummary::OrHash + ).returns(T.attached_class) + end + def self.new( + # Funds available for card spend backed by this Security Account, in the + # currency's smallest unit (e.g., cents for USD). Equal to the sum of the amounts + # in `summary`, and reaches zero once outstanding spend has consumed all available + # funding + open_to_buy:, + # Balances that open to buy is derived from + summary: + ) + end + + sig do + override.returns( + { + open_to_buy: Integer, + summary: Lithic::FinancialAccounts::OpenToBuySummary + } + ) + end + def to_hash + end + end + end + end +end diff --git a/rbi/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbi b/rbi/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbi new file mode 100644 index 00000000..f530cdaa --- /dev/null +++ b/rbi/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbi @@ -0,0 +1,43 @@ +# typed: strong + +module Lithic + module Models + module FinancialAccounts + class OpenToBuyRetrieveParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + OrHash = + T.type_alias do + T.any( + Lithic::FinancialAccounts::OpenToBuyRetrieveParams, + Lithic::Internal::AnyHash + ) + end + + sig { returns(String) } + attr_accessor :financial_account_token + + sig do + params( + financial_account_token: String, + request_options: Lithic::RequestOptions::OrHash + ).returns(T.attached_class) + end + def self.new(financial_account_token:, request_options: {}) + end + + sig do + override.returns( + { + financial_account_token: String, + request_options: Lithic::RequestOptions + } + ) + end + def to_hash + end + end + end + end +end diff --git a/rbi/lithic/models/financial_accounts/open_to_buy_summary.rbi b/rbi/lithic/models/financial_accounts/open_to_buy_summary.rbi new file mode 100644 index 00000000..87346ec7 --- /dev/null +++ b/rbi/lithic/models/financial_accounts/open_to_buy_summary.rbi @@ -0,0 +1,73 @@ +# typed: strong + +module Lithic + module Models + module FinancialAccounts + class OpenToBuySummary < Lithic::Internal::Type::BaseModel + OrHash = + T.type_alias do + T.any( + Lithic::FinancialAccounts::OpenToBuySummary, + Lithic::Internal::AnyHash + ) + end + + # Available balance of the Security Account backing card spend, in the currency's + # smallest unit (e.g., cents for USD) + sig { returns(Integer) } + attr_accessor :security + + # Funding that has moved out of the Security Account to cover card spend Lithic + # has already paid out to the networks, in the currency's smallest unit (e.g., + # cents for USD). Open to buy counts it alongside `security`, and it clears once + # collected from your business clients. Only Commercial Charge tracks this + # separately, so this is `null` for every other program setup + sig { returns(T.nilable(Integer)) } + attr_accessor :settled_funds + + # Customer card spend that has not yet been collected, in the currency's smallest + # unit (e.g., cents for USD). Reported as a negative amount, because it reduces + # open to buy + sig { returns(Integer) } + attr_accessor :total_outstanding_spend + + # Open to Buy Summary + sig do + params( + security: Integer, + settled_funds: T.nilable(Integer), + total_outstanding_spend: Integer + ).returns(T.attached_class) + end + def self.new( + # Available balance of the Security Account backing card spend, in the currency's + # smallest unit (e.g., cents for USD) + security:, + # Funding that has moved out of the Security Account to cover card spend Lithic + # has already paid out to the networks, in the currency's smallest unit (e.g., + # cents for USD). Open to buy counts it alongside `security`, and it clears once + # collected from your business clients. Only Commercial Charge tracks this + # separately, so this is `null` for every other program setup + settled_funds:, + # Customer card spend that has not yet been collected, in the currency's smallest + # unit (e.g., cents for USD). Reported as a negative amount, because it reduces + # open to buy + total_outstanding_spend: + ) + end + + sig do + override.returns( + { + security: Integer, + settled_funds: T.nilable(Integer), + total_outstanding_spend: Integer + } + ) + end + def to_hash + end + end + end + end +end diff --git a/rbi/lithic/resources/financial_accounts.rbi b/rbi/lithic/resources/financial_accounts.rbi index bd89fe0a..103bb3b9 100644 --- a/rbi/lithic/resources/financial_accounts.rbi +++ b/rbi/lithic/resources/financial_accounts.rbi @@ -6,6 +6,9 @@ module Lithic sig { returns(Lithic::Resources::FinancialAccounts::Balances) } attr_reader :balances + sig { returns(Lithic::Resources::FinancialAccounts::OpenToBuy) } + attr_reader :open_to_buy + sig do returns(Lithic::Resources::FinancialAccounts::FinancialTransactions) end diff --git a/rbi/lithic/resources/financial_accounts/open_to_buy.rbi b/rbi/lithic/resources/financial_accounts/open_to_buy.rbi new file mode 100644 index 00000000..100e8da7 --- /dev/null +++ b/rbi/lithic/resources/financial_accounts/open_to_buy.rbi @@ -0,0 +1,40 @@ +# typed: strong + +module Lithic + module Resources + class FinancialAccounts + class OpenToBuy + # Get the funds available for card spend backed by a given Security Account, along + # with the balances that amount is derived from. + # + # Open to buy is the amount Lithic authorizes card spend against. It is not a + # stored balance, so it is recalculated on every request from the Security + # Account, the funds held against spend Lithic has already paid out to the + # networks on your behalf, and the spend that has not yet been collected. The + # accounts that feed the calculation depend on your program setup, so + # `summary.settled_funds` is `null` outside Commercial Charge. + # + # Supported for Commercial Charge, Dynamic Reserve, and Secured Charge programs. + # Returns `404` if `financial_account_token` is not a Security Account you own, or + # if your program setup does not use an open to buy calculation. + sig do + params( + financial_account_token: String, + request_options: Lithic::RequestOptions::OrHash + ).returns(Lithic::FinancialAccounts::FinancialAccountsOpenToBuy) + end + def retrieve( + # Globally unique identifier for the Security Account to price + financial_account_token, + request_options: {} + ) + end + + # @api private + sig { params(client: Lithic::Client).returns(T.attached_class) } + def self.new(client:) + end + end + end + end +end diff --git a/sig/lithic/models/financial_accounts/open_to_buy.rbs b/sig/lithic/models/financial_accounts/open_to_buy.rbs new file mode 100644 index 00000000..11004bc8 --- /dev/null +++ b/sig/lithic/models/financial_accounts/open_to_buy.rbs @@ -0,0 +1,27 @@ +module Lithic + module Models + module FinancialAccounts + type financial_accounts_open_to_buy = + { + open_to_buy: Integer, + summary: Lithic::FinancialAccounts::OpenToBuySummary + } + + class FinancialAccountsOpenToBuy < Lithic::Internal::Type::BaseModel + attr_accessor open_to_buy: Integer + + attr_accessor summary: Lithic::FinancialAccounts::OpenToBuySummary + + def initialize: ( + open_to_buy: Integer, + summary: Lithic::FinancialAccounts::OpenToBuySummary + ) -> void + + def to_hash: -> { + open_to_buy: Integer, + summary: Lithic::FinancialAccounts::OpenToBuySummary + } + end + end + end +end diff --git a/sig/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbs b/sig/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbs new file mode 100644 index 00000000..1de15086 --- /dev/null +++ b/sig/lithic/models/financial_accounts/open_to_buy_retrieve_params.rbs @@ -0,0 +1,26 @@ +module Lithic + module Models + module FinancialAccounts + type open_to_buy_retrieve_params = + { financial_account_token: String } + & Lithic::Internal::Type::request_parameters + + class OpenToBuyRetrieveParams < Lithic::Internal::Type::BaseModel + extend Lithic::Internal::Type::RequestParameters::Converter + include Lithic::Internal::Type::RequestParameters + + attr_accessor financial_account_token: String + + def initialize: ( + financial_account_token: String, + ?request_options: Lithic::request_opts + ) -> void + + def to_hash: -> { + financial_account_token: String, + request_options: Lithic::RequestOptions + } + end + end + end +end diff --git a/sig/lithic/models/financial_accounts/open_to_buy_summary.rbs b/sig/lithic/models/financial_accounts/open_to_buy_summary.rbs new file mode 100644 index 00000000..215f52e9 --- /dev/null +++ b/sig/lithic/models/financial_accounts/open_to_buy_summary.rbs @@ -0,0 +1,32 @@ +module Lithic + module Models + module FinancialAccounts + type open_to_buy_summary = + { + security: Integer, + settled_funds: Integer?, + total_outstanding_spend: Integer + } + + class OpenToBuySummary < Lithic::Internal::Type::BaseModel + attr_accessor security: Integer + + attr_accessor settled_funds: Integer? + + attr_accessor total_outstanding_spend: Integer + + def initialize: ( + security: Integer, + settled_funds: Integer?, + total_outstanding_spend: Integer + ) -> void + + def to_hash: -> { + security: Integer, + settled_funds: Integer?, + total_outstanding_spend: Integer + } + end + end + end +end diff --git a/sig/lithic/resources/financial_accounts.rbs b/sig/lithic/resources/financial_accounts.rbs index 7a607491..d67cfb8b 100644 --- a/sig/lithic/resources/financial_accounts.rbs +++ b/sig/lithic/resources/financial_accounts.rbs @@ -3,6 +3,8 @@ module Lithic class FinancialAccounts attr_reader balances: Lithic::Resources::FinancialAccounts::Balances + attr_reader open_to_buy: Lithic::Resources::FinancialAccounts::OpenToBuy + attr_reader financial_transactions: Lithic::Resources::FinancialAccounts::FinancialTransactions attr_reader credit_configuration: Lithic::Resources::FinancialAccounts::CreditConfiguration diff --git a/sig/lithic/resources/financial_accounts/open_to_buy.rbs b/sig/lithic/resources/financial_accounts/open_to_buy.rbs new file mode 100644 index 00000000..88fea4d1 --- /dev/null +++ b/sig/lithic/resources/financial_accounts/open_to_buy.rbs @@ -0,0 +1,14 @@ +module Lithic + module Resources + class FinancialAccounts + class OpenToBuy + def retrieve: ( + String financial_account_token, + ?request_options: Lithic::request_opts + ) -> Lithic::FinancialAccounts::FinancialAccountsOpenToBuy + + def initialize: (client: Lithic::Client) -> void + end + end + end +end diff --git a/test/lithic/resources/financial_accounts/open_to_buy_test.rb b/test/lithic/resources/financial_accounts/open_to_buy_test.rb new file mode 100644 index 00000000..303ee934 --- /dev/null +++ b/test/lithic/resources/financial_accounts/open_to_buy_test.rb @@ -0,0 +1,20 @@ +# frozen_string_literal: true + +require_relative "../../test_helper" + +class Lithic::Test::Resources::FinancialAccounts::OpenToBuyTest < Lithic::Test::ResourceTest + def test_retrieve + response = @lithic.financial_accounts.open_to_buy.retrieve("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e") + + assert_pattern do + response => Lithic::FinancialAccounts::FinancialAccountsOpenToBuy + end + + assert_pattern do + response => { + open_to_buy: Integer, + summary: Lithic::FinancialAccounts::OpenToBuySummary + } + end + end +end From 1cca590a6c6ece8cb5d8815afebc4914fa73ea60 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 17 Sep 2026 20:15:44 +0000 Subject: [PATCH 14/14] release: 0.21.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 24 ++++++++++++++++++++++++ Gemfile.lock | 2 +- README.md | 2 +- lib/lithic/version.rb | 2 +- 5 files changed, 28 insertions(+), 4 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 0c2ecec6..86b0e83d 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.20.0" + ".": "0.21.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index bd4faf6f..31869182 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,29 @@ # Changelog +## 0.21.0 (2026-09-17) + +Full Changelog: [v0.20.0...v0.21.0](https://github.com/lithic-com/lithic-ruby/compare/v0.20.0...v0.21.0) + +### Features + +* [CARDS-5174] Add reiusse/renew 409 error ([2fc8f3b](https://github.com/lithic-com/lithic-ruby/commit/2fc8f3b93ff2e392d8eda8e343d21e423c214191)) +* [TRE-14464] Update /retry payments endpoint to accept method ([6031d67](https://github.com/lithic-com/lithic-ruby/commit/6031d6794afd8c3a4b121cf2f7368e0ac40867c0)) +* [TRE-14524] Add Open to buy API spec ([bdf043e](https://github.com/lithic-com/lithic-ruby/commit/bdf043e53ac45964c091134b25fb7a3023948397)) +* Add missing blockchain/stablecoin endpoints to the spec ([3e8c0dc](https://github.com/lithic-com/lithic-ruby/commit/3e8c0dcdaa7169ba0a47bea4493e71d778af8853)) +* **api:** add EXTERNAL_STABLECOIN category and events to payment resources ([518aebb](https://github.com/lithic-com/lithic-ruby/commit/518aebb0cf94cbc0b1ca1ef85a94a71c5bf1983e)) +* **api:** add FEE/FEE_REVERSAL to financial_event, statement_line_items, management_operation ([04690f1](https://github.com/lithic-com/lithic-ruby/commit/04690f1542cb3f213da8695507a371c4f0a5aed4)) +* **api:** add OTHER enum value to auth_rules type field ([1bb4cc8](https://github.com/lithic-com/lithic-ruby/commit/1bb4cc80ab6e025ebf0d6fcdd88c5b62cbb602a0)) +* **api:** add psd2_context field to three_ds_authentication ([19e526e](https://github.com/lithic-com/lithic-ruby/commit/19e526e916227881e91ac1dac42e75d86132451e)) +* **api:** add STABLECOIN_REVIEWED event type to payment simulate action ([766c658](https://github.com/lithic-com/lithic-ruby/commit/766c658645a79accfca85707ce6d5c087d93959e)) +* AUTH-3759: Add DECLINE_SCA_REQUIRED and SCA_REQUIRED enum entries ([e784b27](https://github.com/lithic-com/lithic-ruby/commit/e784b275c2690eb0d2ab4a36a3ee9f5af2f79b0b)) +* TRE-14349: add installment plan management operation event types ([bd71bde](https://github.com/lithic-com/lithic-ruby/commit/bd71bde5d20641e236b5b2e95908293bf0ef48e9)) +* TRE-14429: Document the stablecoin payments endpoint ([050c7bd](https://github.com/lithic-com/lithic-ruby/commit/050c7bdd679e3c090c6e1819c0aa3405e3cbfc0c)) + + +### Documentation + +* Document the card.pin_updated webhook ([b96e92e](https://github.com/lithic-com/lithic-ruby/commit/b96e92e36fa4ae4dab543d1cc639d807f810b967)) + ## 0.20.0 (2026-08-31) Full Changelog: [v0.19.0...v0.20.0](https://github.com/lithic-com/lithic-ruby/compare/v0.19.0...v0.20.0) diff --git a/Gemfile.lock b/Gemfile.lock index 53f1b0d1..8cef8551 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -11,7 +11,7 @@ GIT PATH remote: . specs: - lithic (0.20.0) + lithic (0.21.0) cgi connection_pool diff --git a/README.md b/README.md index 55ac7cac..dbf2a094 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ To use this gem, install via Bundler by adding the following to your application ```ruby -gem "lithic", "~> 0.20.0" +gem "lithic", "~> 0.21.0" ``` diff --git a/lib/lithic/version.rb b/lib/lithic/version.rb index 125be3f9..df4ea9da 100644 --- a/lib/lithic/version.rb +++ b/lib/lithic/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module Lithic - VERSION = "0.20.0" + VERSION = "0.21.0" end