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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
34 changes: 34 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,40 @@ on:
- 'stl-preview-base/**'

jobs:
build:
timeout-minutes: 10
name: build
permissions:
contents: read
id-token: write
runs-on: ${{ github.repository == 'stainless-sdks/lithic-ruby' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: |-
github.repository == 'stainless-sdks/lithic-ruby' &&
(github.event_name == 'push' || github.event.pull_request.head.repo.fork)
steps:
- uses: actions/checkout@v6
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
bundler-cache: false
- run: |-
bundle install

- name: Get GitHub OIDC Token
if: github.repository == 'stainless-sdks/lithic-ruby'
id: github-oidc
uses: actions/github-script@v8
with:
script: core.setOutput('github_token', await core.getIDToken());

- name: Build and upload gem artifacts
if: github.repository == 'stainless-sdks/lithic-ruby'
env:
URL: https://pkg.stainless.com/s
AUTH: ${{ steps.github-oidc.outputs.github_token }}
SHA: ${{ github.sha }}
PACKAGE_NAME: lithic
run: ./scripts/utils/upload-artifact.sh
lint:
timeout-minutes: 10
name: lint
Expand Down
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.6.0"
".": "0.7.0"
}
6 changes: 3 additions & 3 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 185
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-a45946df228eec554b3cd2491f658bd5a45cb91509da0a9f92d50468ea88072f.yml
openapi_spec_hash: 24c7c13e1e7385cab5442ca66091ffc6
config_hash: 50031f78031362c2e4900222b9ce7ada
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-ee8607f0a2cdcaee420935050334a439db8dd097be83023fccdaf1d6f9a7de14.yml
openapi_spec_hash: 0f21c68cdddb7c5bd99f42356d507393
config_hash: fb5070d41fcabdedbc084b83964b592a
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,21 @@
# Changelog

## 0.7.0 (2026-03-05)

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

### Features

* **api:** add action_counts to rule performance reports and code to authorization actions ([bd02001](https://github.com/lithic-com/lithic-ruby/commit/bd02001603d5893f1095ed7d89f9f019c780fff8))
* **api:** Add Hold API for financial account fund reservations ([6b16d86](https://github.com/lithic-com/lithic-ruby/commit/6b16d86f054b238b7d2b91c9e0e62df67e88fbd7))
* **api:** Remove deprecated beneficial owner entities field ([7c54dcf](https://github.com/lithic-com/lithic-ruby/commit/7c54dcf052f9c13b7ab73862f80e279d1184e8ee))


### Chores

* **internal:** codegen related update ([199e518](https://github.com/lithic-com/lithic-ruby/commit/199e518f942530266541eef7343ff626dfbf7c10))
* **internal:** codegen related update ([412e84f](https://github.com/lithic-com/lithic-ruby/commit/412e84f1d1e0b574fd791ea420fbf88707a6985a))

## 0.6.0 (2026-02-27)

Full Changelog: [v0.5.0...v0.6.0](https://github.com/lithic-com/lithic-ruby/compare/v0.5.0...v0.6.0)
Expand Down
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ GIT
PATH
remote: .
specs:
lithic (0.6.0)
lithic (0.7.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.6.0"
gem "lithic", "~> 0.7.0"
```

<!-- x-release-please-end -->
Expand Down
3 changes: 2 additions & 1 deletion lib/lithic.rb
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@
require_relative "lithic/models/api_status"
require_relative "lithic/models/auth_rules/auth_rule"
require_relative "lithic/models/auth_rules/auth_rule_condition"
require_relative "lithic/models/auth_rules/backtest_stats"
require_relative "lithic/models/auth_rules/conditional_3ds_action_parameters"
require_relative "lithic/models/auth_rules/conditional_ach_action_parameters"
require_relative "lithic/models/auth_rules/conditional_attribute"
Expand All @@ -124,7 +125,7 @@
require_relative "lithic/models/auth_rules/conditional_value"
require_relative "lithic/models/auth_rules/event_stream"
require_relative "lithic/models/auth_rules/merchant_lock_parameters"
require_relative "lithic/models/auth_rules/rule_stats"
require_relative "lithic/models/auth_rules/report_stats"
require_relative "lithic/models/auth_rules/v2/backtest_create_params"
require_relative "lithic/models/auth_rules/v2/backtest_create_response"
require_relative "lithic/models/auth_rules/v2/backtest_retrieve_params"
Expand Down
31 changes: 31 additions & 0 deletions lib/lithic/internal/util.rb
Original file line number Diff line number Diff line change
Expand Up @@ -490,6 +490,37 @@ def writable_enum(&blk)
JSONL_CONTENT = %r{^application/(:?x-(?:n|l)djson)|(:?(?:x-)?jsonl)}

class << self
# @api private
#
# @param query [Hash{Symbol=>Object}]
#
# @return [Hash{Symbol=>Object}]
def encode_query_params(query)
out = {}
query.each { write_query_param_element!(out, _1, _2) }
out
end

# @api private
#
# @param collection [Hash{Symbol=>Object}]
# @param key [String]
# @param element [Object]
#
# @return [nil]
private def write_query_param_element!(collection, key, element)
case element
in Hash
element.each do |name, value|
write_query_param_element!(collection, "#{key}[#{name}]", value)
end
in Array
collection[key] = element.map(&:to_s).join(",")
else
collection[key] = element.to_s
end
end

# @api private
#
# @param y [Enumerator::Yielder]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,13 @@ class AccountActivityRetrieveTransactionParams < Lithic::Internal::Type::BaseMod
extend Lithic::Internal::Type::RequestParameters::Converter
include Lithic::Internal::Type::RequestParameters

# @!method initialize(request_options: {})
# @!attribute transaction_token
#
# @return [String]
required :transaction_token, String

# @!method initialize(transaction_token:, request_options: {})
# @param transaction_token [String]
# @param request_options [Lithic::RequestOptions, Hash{Symbol=>Object}]
end
end
Expand Down
80 changes: 1 addition & 79 deletions lib/lithic/models/account_holder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,6 @@ class AccountHolder < Lithic::Internal::Type::BaseModel
# @return [String, nil]
optional :account_token, String

# @!attribute beneficial_owner_entities
# @deprecated
#
# Deprecated.
#
# @return [Array<Lithic::Models::AccountHolder::BeneficialOwnerEntity>, nil]
optional :beneficial_owner_entities,
-> { Lithic::Internal::Type::ArrayOf[Lithic::AccountHolder::BeneficialOwnerEntity] }

# @!attribute beneficial_owner_individuals
# Only present when user_type == "BUSINESS". You must submit a list of all direct
# and indirect individuals with 25% or more ownership in the company. A maximum of
Expand Down Expand Up @@ -168,7 +159,7 @@ class AccountHolder < Lithic::Internal::Type::BaseModel
# @return [String, nil]
optional :website_url, String

# @!method initialize(token:, created:, account_token: nil, beneficial_owner_entities: nil, beneficial_owner_individuals: nil, business_account_token: nil, business_entity: nil, control_person: nil, email: nil, exemption_type: nil, external_id: nil, individual: nil, naics_code: nil, nature_of_business: nil, phone_number: nil, required_documents: nil, status: nil, status_reasons: nil, user_type: nil, verification_application: nil, website_url: nil)
# @!method initialize(token:, created:, account_token: nil, beneficial_owner_individuals: nil, business_account_token: nil, business_entity: nil, control_person: nil, email: nil, exemption_type: nil, external_id: nil, individual: nil, naics_code: nil, nature_of_business: nil, phone_number: nil, required_documents: nil, status: nil, status_reasons: nil, user_type: nil, verification_application: nil, website_url: nil)
# Some parameter documentations has been truncated, see
# {Lithic::Models::AccountHolder} for more details.
#
Expand All @@ -178,8 +169,6 @@ class AccountHolder < Lithic::Internal::Type::BaseModel
#
# @param account_token [String] Globally unique identifier for the account.
#
# @param beneficial_owner_entities [Array<Lithic::Models::AccountHolder::BeneficialOwnerEntity>] Deprecated.
#
# @param beneficial_owner_individuals [Array<Lithic::Models::AccountHolder::BeneficialOwnerIndividual>] Only present when user_type == "BUSINESS".
#
# @param business_account_token [String] Only applicable for customers using the KYC-Exempt workflow to enroll authorized
Expand Down Expand Up @@ -214,73 +203,6 @@ class AccountHolder < Lithic::Internal::Type::BaseModel
#
# @param website_url [String] Only present when user_type == "BUSINESS". Business's primary website.

class BeneficialOwnerEntity < Lithic::Internal::Type::BaseModel
# @!attribute address
# Business's physical address - PO boxes, UPS drops, and FedEx drops are not
# acceptable; APO/FPO are acceptable.
#
# @return [Lithic::Models::Address]
required :address, -> { Lithic::Address }

# @!attribute dba_business_name
# Any name that the business operates under that is not its legal business name
# (if applicable).
#
# @return [String]
required :dba_business_name, String

# @!attribute entity_token
# Globally unique identifier for the entity.
#
# @return [String]
required :entity_token, String

# @!attribute government_id
# Government-issued identification number. US Federal Employer Identification
# Numbers (EIN) are currently supported, entered as full nine-digits, with or
# without hyphens.
#
# @return [String]
required :government_id, String

# @!attribute legal_business_name
# Legal (formal) business name.
#
# @return [String]
required :legal_business_name, String

# @!attribute phone_numbers
# One or more of the business's phone number(s), entered as a list in E.164
# format.
#
# @return [Array<String>]
required :phone_numbers, Lithic::Internal::Type::ArrayOf[String]

# @!attribute parent_company
# Parent company name (if applicable).
#
# @return [String, nil]
optional :parent_company, String

# @!method initialize(address:, dba_business_name:, entity_token:, government_id:, legal_business_name:, phone_numbers:, parent_company: nil)
# Some parameter documentations has been truncated, see
# {Lithic::Models::AccountHolder::BeneficialOwnerEntity} for more details.
#
# @param address [Lithic::Models::Address] Business's physical address - PO boxes, UPS drops, and FedEx drops are not accep
#
# @param dba_business_name [String] Any name that the business operates under that is not its legal business name (i
#
# @param entity_token [String] Globally unique identifier for the entity.
#
# @param government_id [String] Government-issued identification number. US Federal Employer Identification Numb
#
# @param legal_business_name [String] Legal (formal) business name.
#
# @param phone_numbers [Array<String>] One or more of the business's phone number(s), entered as a list in E.164 format
#
# @param parent_company [String] Parent company name (if applicable).
end

class BeneficialOwnerIndividual < Lithic::Internal::Type::BaseModel
# @!attribute address
# Individual's current address
Expand Down
Loading