Skip to content
Open
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 @@
{
".": "0.13.0"
".": "0.14.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: 191
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-0f374e78a0212145a2f55a55dfc39a612de19094d5152ae26b1bc74b01b9e343.yml
openapi_spec_hash: ec888cdaebea979a2cd6231ca04c346c
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-af9701d01abffc53ba2bf56c06415d893460e6b420f122e602cf4afe67bbf57b.yml
openapi_spec_hash: 963688b09480159a06865075c94a2577
config_hash: 01dfc901bb6d54b0f582155d779bcbe0
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## 0.14.0 (2026-05-07)

Full Changelog: [v0.13.0...v0.14.0](https://github.com/lithic-com/lithic-ruby/compare/v0.13.0...v0.14.0)

### Features

* **api:** add travel speed/distance attributes and unit parameter to auth_rules ([846d5d9](https://github.com/lithic-com/lithic-ruby/commit/846d5d99cea53078bbda45f2a4b845bc4f7f33d2))

## 0.13.0 (2026-05-06)

Full Changelog: [v0.12.0...v0.13.0](https://github.com/lithic-com/lithic-ruby/compare/v0.12.0...v0.13.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:
lithic (0.13.0)
lithic (0.14.0)
cgi
connection_pool

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

```ruby
gem "lithic", "~> 0.13.0"
gem "lithic", "~> 0.14.0"
```

<!-- x-release-please-end -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,15 @@ class Condition < Lithic::Internal::Type::BaseModel
# `parameters` required.
# - `THREE_DS_SUCCESS_RATE`: The 3DS authentication success rate for the card, as
# a percentage from 0.0 to 100.0. Card-scoped only; no `parameters` required.
# - `TRAVEL_SPEED`: The estimated speed of travel derived from the distance
# between the postal code centers of the last card-present transaction and the
# current transaction, divided by the elapsed time. Null if there is no prior
# card-present transaction, if either postal code cannot be geocoded, or if
# elapsed time is zero. Requires `parameters.unit` set to `MPH` or `KPH`.
# - `DISTANCE_FROM_LAST_TRANSACTION`: The estimated distance between the postal
# code centers of the last card-present transaction and the current transaction.
# Null if there is no prior card-present transaction or if either postal code
# cannot be geocoded. Requires `parameters.unit` set to `MILES` or `KILOMETERS`.
#
# @return [Symbol, Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Attribute]
required :attribute,
Expand All @@ -156,11 +165,12 @@ class Condition < Lithic::Internal::Type::BaseModel
required :value, union: -> { Lithic::AuthRules::ConditionalValue }

# @!attribute parameters
# Additional parameters required for transaction history signal attributes.
# Required when `attribute` is one of `AMOUNT_Z_SCORE`, `AVG_TRANSACTION_AMOUNT`,
# `STDEV_TRANSACTION_AMOUNT`, `IS_NEW_COUNTRY`, `IS_NEW_MCC`,
# `IS_FIRST_TRANSACTION`, `CONSECUTIVE_DECLINES`, `TIME_SINCE_LAST_TRANSACTION`,
# or `DISTINCT_COUNTRY_COUNT`. Not used for other attributes.
# Additional parameters for certain attributes. Required when `attribute` is one
# of `AMOUNT_Z_SCORE`, `AVG_TRANSACTION_AMOUNT`, `STDEV_TRANSACTION_AMOUNT`,
# `IS_NEW_COUNTRY`, `IS_NEW_MCC`, `IS_FIRST_TRANSACTION`, `CONSECUTIVE_DECLINES`,
# `TIME_SINCE_LAST_TRANSACTION`, or `DISTINCT_COUNTRY_COUNT` (require `scope`); or
# `TRAVEL_SPEED` or `DISTANCE_FROM_LAST_TRANSACTION` (require `unit`). Not used
# for other attributes.
#
# @return [Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters, nil]
optional :parameters,
Expand All @@ -177,7 +187,7 @@ class Condition < Lithic::Internal::Type::BaseModel
#
# @param value [String, Integer, Array<String>, Time] A regex string, to be used with `MATCHES` or `DOES_NOT_MATCH`
#
# @param parameters [Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters] Additional parameters required for transaction history signal attributes. Requir
# @param parameters [Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters] Additional parameters for certain attributes. Required when `attribute` is one o

# The attribute to target.
#
Expand Down Expand Up @@ -281,6 +291,15 @@ class Condition < Lithic::Internal::Type::BaseModel
# `parameters` required.
# - `THREE_DS_SUCCESS_RATE`: The 3DS authentication success rate for the card, as
# a percentage from 0.0 to 100.0. Card-scoped only; no `parameters` required.
# - `TRAVEL_SPEED`: The estimated speed of travel derived from the distance
# between the postal code centers of the last card-present transaction and the
# current transaction, divided by the elapsed time. Null if there is no prior
# card-present transaction, if either postal code cannot be geocoded, or if
# elapsed time is zero. Requires `parameters.unit` set to `MPH` or `KPH`.
# - `DISTANCE_FROM_LAST_TRANSACTION`: The estimated distance between the postal
# code centers of the last card-present transaction and the current transaction.
# Null if there is no prior card-present transaction or if either postal code
# cannot be geocoded. Requires `parameters.unit` set to `MILES` or `KILOMETERS`.
#
# @see Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition#attribute
module Attribute
Expand Down Expand Up @@ -323,6 +342,8 @@ module Attribute
DISTINCT_COUNTRY_COUNT = :DISTINCT_COUNTRY_COUNT
IS_NEW_MERCHANT = :IS_NEW_MERCHANT
THREE_DS_SUCCESS_RATE = :THREE_DS_SUCCESS_RATE
TRAVEL_SPEED = :TRAVEL_SPEED
DISTANCE_FROM_LAST_TRANSACTION = :DISTANCE_FROM_LAST_TRANSACTION

# @!method self.values
# @return [Array<Symbol>]
Expand All @@ -346,20 +367,36 @@ class Parameters < Lithic::Internal::Type::BaseModel
optional :scope,
enum: -> { Lithic::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters::Scope }

# @!method initialize(interval: nil, scope: nil)
# @!attribute unit
# The unit for impossible travel attributes. Required when `attribute` is
# `TRAVEL_SPEED` or `DISTANCE_FROM_LAST_TRANSACTION`.
#
# For `TRAVEL_SPEED`: `MPH` (miles per hour) or `KPH` (kilometers per hour).
#
# For `DISTANCE_FROM_LAST_TRANSACTION`: `MILES` or `KILOMETERS`.
#
# @return [Symbol, Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters::Unit, nil]
optional :unit,
enum: -> { Lithic::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters::Unit }

# @!method initialize(interval: nil, scope: nil, unit: nil)
# Some parameter documentations has been truncated, see
# {Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters}
# for more details.
#
# Additional parameters required for transaction history signal attributes.
# Required when `attribute` is one of `AMOUNT_Z_SCORE`, `AVG_TRANSACTION_AMOUNT`,
# `STDEV_TRANSACTION_AMOUNT`, `IS_NEW_COUNTRY`, `IS_NEW_MCC`,
# `IS_FIRST_TRANSACTION`, `CONSECUTIVE_DECLINES`, `TIME_SINCE_LAST_TRANSACTION`,
# or `DISTINCT_COUNTRY_COUNT`. Not used for other attributes.
# Additional parameters for certain attributes. Required when `attribute` is one
# of `AMOUNT_Z_SCORE`, `AVG_TRANSACTION_AMOUNT`, `STDEV_TRANSACTION_AMOUNT`,
# `IS_NEW_COUNTRY`, `IS_NEW_MCC`, `IS_FIRST_TRANSACTION`, `CONSECUTIVE_DECLINES`,
# `TIME_SINCE_LAST_TRANSACTION`, or `DISTINCT_COUNTRY_COUNT` (require `scope`); or
# `TRAVEL_SPEED` or `DISTANCE_FROM_LAST_TRANSACTION` (require `unit`). Not used
# for other attributes.
#
# @param interval [Symbol, Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters::Interval] The time window for statistical attributes (`AMOUNT_Z_SCORE`, `AVG_TRANSACTION_A
#
# @param scope [Symbol, Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters::Scope] The entity scope to evaluate the attribute against.
#
# @param unit [Symbol, Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters::Unit] The unit for impossible travel attributes. Required when `attribute` is
# `TRAVEL\_

# The time window for statistical attributes (`AMOUNT_Z_SCORE`,
# `AVG_TRANSACTION_AMOUNT`, `STDEV_TRANSACTION_AMOUNT`). Use `LIFETIME` for
Expand Down Expand Up @@ -391,6 +428,26 @@ module Scope
# @!method self.values
# @return [Array<Symbol>]
end

# The unit for impossible travel attributes. Required when `attribute` is
# `TRAVEL_SPEED` or `DISTANCE_FROM_LAST_TRANSACTION`.
#
# For `TRAVEL_SPEED`: `MPH` (miles per hour) or `KPH` (kilometers per hour).
#
# For `DISTANCE_FROM_LAST_TRANSACTION`: `MILES` or `KILOMETERS`.
#
# @see Lithic::Models::AuthRules::ConditionalAuthorizationActionParameters::Condition::Parameters#unit
module Unit
extend Lithic::Internal::Type::Enum

MPH = :MPH
KPH = :KPH
MILES = :MILES
KILOMETERS = :KILOMETERS

# @!method self.values
# @return [Array<Symbol>]
end
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion lib/lithic/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# frozen_string_literal: true

module Lithic
VERSION = "0.13.0"
VERSION = "0.14.0"
end
Loading