Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "1.147.0"
".": "1.148.0"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 229
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-cfdb6b2516039e7537ec6edb67df5581e3f08396a9f92579dd42c565015583e6.yml
openapi_spec_hash: c41230e467198f4240e80c77ef8c5c7c
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/increase%2Fincrease-a66f039751a4ffdebbbf533f24f55cd2c42708b9cf105512849849fddaafb5e8.yml
openapi_spec_hash: c265609bceb053f898ea14b1191fe927
config_hash: ca1425272e17fa23d4466d33492334fa
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 1.148.0 (2025-11-24)

Full Changelog: [v1.147.0...v1.148.0](https://github.com/Increase/increase-ruby/compare/v1.147.0...v1.148.0)

### Features

* **api:** api update ([70549b5](https://github.com/Increase/increase-ruby/commit/70549b5f5c04bd68309c448849df43ced96e48c8))

## 1.147.0 (2025-11-21)

Full Changelog: [v1.146.0...v1.147.0](https://github.com/Increase/increase-ruby/compare/v1.146.0...v1.147.0)
Expand Down
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ GIT
PATH
remote: .
specs:
increase (1.147.0)
increase (1.148.0)
connection_pool

GEM
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ To use this gem, install via Bundler by adding the following to your application
<!-- x-release-please-start-version -->

```ruby
gem "increase", "~> 1.147.0"
gem "increase", "~> 1.148.0"
```

<!-- x-release-please-end -->
Expand Down
34 changes: 31 additions & 3 deletions lib/increase/models/real_time_decision.rb
Original file line number Diff line number Diff line change
Expand Up @@ -907,14 +907,42 @@ class Decline < Increase::Internal::Type::BaseModel
# @!attribute reason
# The reason the authorization was declined.
#
# @return [String]
required :reason, String
# @return [Symbol, Increase::Models::RealTimeDecision::CardAuthorization::Decline::Reason]
required :reason, enum: -> { Increase::RealTimeDecision::CardAuthorization::Decline::Reason }

# @!method initialize(reason:)
# Present if and only if `decision` is `decline`. Contains information related to
# the reason the authorization was declined.
#
# @param reason [String] The reason the authorization was declined.
# @param reason [Symbol, Increase::Models::RealTimeDecision::CardAuthorization::Decline::Reason] The reason the authorization was declined.

# The reason the authorization was declined.
#
# @see Increase::Models::RealTimeDecision::CardAuthorization::Decline#reason
module Reason
extend Increase::Internal::Type::Enum

# The cardholder does not have sufficient funds to cover the transaction. The merchant may attempt to process the transaction again.
INSUFFICIENT_FUNDS = :insufficient_funds

# This type of transaction is not allowed for this card. This transaction should not be retried.
TRANSACTION_NEVER_ALLOWED = :transaction_never_allowed

# The transaction amount exceeds the cardholder's approval limit. The merchant may attempt to process the transaction again.
EXCEEDS_APPROVAL_LIMIT = :exceeds_approval_limit

# The card has been temporarily disabled or not yet activated. The merchant may attempt to process the transaction again.
CARD_TEMPORARILY_DISABLED = :card_temporarily_disabled

# The transaction is suspected to be fraudulent. The merchant may attempt to process the transaction again.
SUSPECTED_FRAUD = :suspected_fraud

# The transaction was declined for another reason. The merchant may attempt to process the transaction again. This should be used sparingly.
OTHER = :other

# @!method self.values
# @return [Array<Symbol>]
end
end

# The direction describes the direction the funds will move, either from the
Expand Down
2 changes: 1 addition & 1 deletion lib/increase/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Increase
VERSION = "1.147.0"
VERSION = "1.148.0"
end
88 changes: 85 additions & 3 deletions rbi/increase/models/real_time_decision.rbi
Original file line number Diff line number Diff line change
Expand Up @@ -1619,21 +1619,103 @@ module Increase
end

# The reason the authorization was declined.
sig { returns(String) }
sig do
returns(
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
)
end
attr_accessor :reason

# Present if and only if `decision` is `decline`. Contains information related to
# the reason the authorization was declined.
sig { params(reason: String).returns(T.attached_class) }
sig do
params(
reason:
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::OrSymbol
).returns(T.attached_class)
end
def self.new(
# The reason the authorization was declined.
reason:
)
end

sig { override.returns({ reason: String }) }
sig do
override.returns(
{
reason:
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
}
)
end
def to_hash
end

# The reason the authorization was declined.
module Reason
extend Increase::Internal::Type::Enum

TaggedSymbol =
T.type_alias do
T.all(
Symbol,
Increase::RealTimeDecision::CardAuthorization::Decline::Reason
)
end
OrSymbol = T.type_alias { T.any(Symbol, String) }

# The cardholder does not have sufficient funds to cover the transaction. The merchant may attempt to process the transaction again.
INSUFFICIENT_FUNDS =
T.let(
:insufficient_funds,
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
)

# This type of transaction is not allowed for this card. This transaction should not be retried.
TRANSACTION_NEVER_ALLOWED =
T.let(
:transaction_never_allowed,
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
)

# The transaction amount exceeds the cardholder's approval limit. The merchant may attempt to process the transaction again.
EXCEEDS_APPROVAL_LIMIT =
T.let(
:exceeds_approval_limit,
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
)

# The card has been temporarily disabled or not yet activated. The merchant may attempt to process the transaction again.
CARD_TEMPORARILY_DISABLED =
T.let(
:card_temporarily_disabled,
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
)

# The transaction is suspected to be fraudulent. The merchant may attempt to process the transaction again.
SUSPECTED_FRAUD =
T.let(
:suspected_fraud,
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
)

# The transaction was declined for another reason. The merchant may attempt to process the transaction again. This should be used sparingly.
OTHER =
T.let(
:other,
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
)

sig do
override.returns(
T::Array[
Increase::RealTimeDecision::CardAuthorization::Decline::Reason::TaggedSymbol
]
)
end
def self.values
end
end
end

# The direction describes the direction the funds will move, either from the
Expand Down
47 changes: 43 additions & 4 deletions sig/increase/models/real_time_decision.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -508,14 +508,53 @@ module Increase
def self?.values: -> ::Array[Increase::Models::RealTimeDecision::CardAuthorization::decision]
end

type decline = { reason: String }
type decline =
{
reason: Increase::Models::RealTimeDecision::CardAuthorization::Decline::reason
}

class Decline < Increase::Internal::Type::BaseModel
attr_accessor reason: String
attr_accessor reason: Increase::Models::RealTimeDecision::CardAuthorization::Decline::reason

def initialize: (reason: String) -> void
def initialize: (
reason: Increase::Models::RealTimeDecision::CardAuthorization::Decline::reason
) -> void

def to_hash: -> { reason: String }
def to_hash: -> {
reason: Increase::Models::RealTimeDecision::CardAuthorization::Decline::reason
}

type reason =
:insufficient_funds
| :transaction_never_allowed
| :exceeds_approval_limit
| :card_temporarily_disabled
| :suspected_fraud
| :other

module Reason
extend Increase::Internal::Type::Enum

# The cardholder does not have sufficient funds to cover the transaction. The merchant may attempt to process the transaction again.
INSUFFICIENT_FUNDS: :insufficient_funds

# This type of transaction is not allowed for this card. This transaction should not be retried.
TRANSACTION_NEVER_ALLOWED: :transaction_never_allowed

# The transaction amount exceeds the cardholder's approval limit. The merchant may attempt to process the transaction again.
EXCEEDS_APPROVAL_LIMIT: :exceeds_approval_limit

# The card has been temporarily disabled or not yet activated. The merchant may attempt to process the transaction again.
CARD_TEMPORARILY_DISABLED: :card_temporarily_disabled

# The transaction is suspected to be fraudulent. The merchant may attempt to process the transaction again.
SUSPECTED_FRAUD: :suspected_fraud

# The transaction was declined for another reason. The merchant may attempt to process the transaction again. This should be used sparingly.
OTHER: :other

def self?.values: -> ::Array[Increase::Models::RealTimeDecision::CardAuthorization::Decline::reason]
end
end

type direction = :settlement | :refund
Expand Down