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 @@
{
".": "0.116.0"
".": "0.117.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: 184
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
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
# Changelog

## 0.117.0 (2026-03-05)

Full Changelog: [v0.116.0...v0.117.0](https://github.com/lithic-com/lithic-python/compare/v0.116.0...v0.117.0)

### Features

* **api:** add action_counts to rule performance reports and code to authorization actions ([8301127](https://github.com/lithic-com/lithic-python/commit/8301127ce01926ad8290614abe4f2b636a120cbf))
* **api:** Add Hold API for financial account fund reservations ([a476549](https://github.com/lithic-com/lithic-python/commit/a4765491913a1ca262ee53a1a988a79e05a77542))
* **api:** Remove deprecated beneficial owner entities field ([4160169](https://github.com/lithic-com/lithic-python/commit/4160169460138e469b75e642346a573a2f43c55e))


### Chores

* fix webhook parsing tests ([0f10f64](https://github.com/lithic-com/lithic-python/commit/0f10f64e04f189436e48423da8639768bb6d88a3))
* **internal:** codegen related update ([83f9164](https://github.com/lithic-com/lithic-python/commit/83f9164040f73e7f585d0f05e37bb24f97f57115))
* **internal:** codegen related update ([089f0d7](https://github.com/lithic-com/lithic-python/commit/089f0d7d6935e896cc9304ebc9535521f8353456))

## 0.116.0 (2026-02-27)

Full Changelog: [v0.115.0...v0.116.0](https://github.com/lithic-com/lithic-python/compare/v0.115.0...v0.116.0)
Expand Down
3 changes: 2 additions & 1 deletion api.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ Types:
from lithic.types.auth_rules import (
AuthRule,
AuthRuleCondition,
BacktestStats,
Conditional3DSActionParameters,
ConditionalACHActionParameters,
ConditionalAttribute,
Expand All @@ -106,7 +107,7 @@ from lithic.types.auth_rules import (
ConditionalValue,
EventStream,
MerchantLockParameters,
RuleStats,
ReportStats,
VelocityLimitParams,
VelocityLimitPeriod,
V2ListResultsResponse,
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "lithic"
version = "0.116.0"
version = "0.117.0"
description = "The official Python library for the lithic API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
13 changes: 12 additions & 1 deletion scripts/mock
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,22 @@ echo "==> Starting mock server with URL ${URL}"

# Run prism mock on the given spec
if [ "$1" == "--daemon" ]; then
# Pre-install the package so the download doesn't eat into the startup timeout
npm exec --package=@stainless-api/prism-cli@5.15.0 -- prism --version

npm exec --package=@stainless-api/prism-cli@5.15.0 -- prism mock "$URL" &> .prism.log &

# Wait for server to come online
# Wait for server to come online (max 30s)
echo -n "Waiting for server"
attempts=0
while ! grep -q "✖ fatal\|Prism is listening" ".prism.log" ; do
attempts=$((attempts + 1))
if [ "$attempts" -ge 300 ]; then
echo
echo "Timed out waiting for Prism server to start"
cat .prism.log
exit 1
fi
echo -n "."
sleep 0.1
done
Expand Down
2 changes: 1 addition & 1 deletion src/lithic/_version.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.

__title__ = "lithic"
__version__ = "0.116.0" # x-release-please-version
__version__ = "0.117.0" # x-release-please-version
24 changes: 0 additions & 24 deletions src/lithic/resources/account_holders/account_holders.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,6 @@ def create(
nature_of_business: str,
tos_timestamp: str,
workflow: Literal["KYB_BASIC", "KYB_BYO"],
beneficial_owner_entities: Iterable[account_holder_create_params.KYBBeneficialOwnerEntity] | Omit = omit,
external_id: str | Omit = omit,
kyb_passed_timestamp: str | Omit = omit,
naics_code: str | Omit = omit,
Expand Down Expand Up @@ -130,8 +129,6 @@ def create(

workflow: Specifies the type of KYB workflow to run.

beneficial_owner_entities: Deprecated.

external_id: A user provided id that can be used to link an account holder with an external
system

Expand Down Expand Up @@ -381,7 +378,6 @@ def create(
| Literal["KYC_BASIC", "KYC_BYO"]
| Literal["KYC_EXEMPT"]
| Omit = omit,
beneficial_owner_entities: Iterable[account_holder_create_params.KYBBeneficialOwnerEntity] | Omit = omit,
external_id: str | Omit = omit,
kyb_passed_timestamp: str | Omit = omit,
naics_code: str | Omit = omit,
Expand Down Expand Up @@ -414,7 +410,6 @@ def create(
"nature_of_business": nature_of_business,
"tos_timestamp": tos_timestamp,
"workflow": workflow,
"beneficial_owner_entities": beneficial_owner_entities,
"external_id": external_id,
"kyb_passed_timestamp": kyb_passed_timestamp,
"naics_code": naics_code,
Expand Down Expand Up @@ -478,8 +473,6 @@ def update(
self,
account_holder_token: str,
*,
beneficial_owner_entities: Iterable[account_holder_update_params.KYBPatchRequestBeneficialOwnerEntity]
| Omit = omit,
beneficial_owner_individuals: Iterable[account_holder_update_params.KYBPatchRequestBeneficialOwnerIndividual]
| Omit = omit,
business_entity: account_holder_update_params.KYBPatchRequestBusinessEntity | Omit = omit,
Expand Down Expand Up @@ -508,8 +501,6 @@ def update(
the program that the calling API key manages.

Args:
beneficial_owner_entities: Deprecated.

beneficial_owner_individuals: You must submit a list of all direct and indirect individuals with 25% or more
ownership in the company. A maximum of 4 beneficial owners can be submitted. If
no individual owns 25% of the company you do not need to send beneficial owner
Expand Down Expand Up @@ -658,8 +649,6 @@ def update(
self,
account_holder_token: str,
*,
beneficial_owner_entities: Iterable[account_holder_update_params.KYBPatchRequestBeneficialOwnerEntity]
| Omit = omit,
beneficial_owner_individuals: Iterable[account_holder_update_params.KYBPatchRequestBeneficialOwnerIndividual]
| Omit = omit,
business_entity: account_holder_update_params.KYBPatchRequestBusinessEntity | Omit = omit,
Expand Down Expand Up @@ -693,7 +682,6 @@ def update(
f"/v1/account_holders/{account_holder_token}",
body=maybe_transform(
{
"beneficial_owner_entities": beneficial_owner_entities,
"beneficial_owner_individuals": beneficial_owner_individuals,
"business_entity": business_entity,
"control_person": control_person,
Expand Down Expand Up @@ -1169,7 +1157,6 @@ async def create(
nature_of_business: str,
tos_timestamp: str,
workflow: Literal["KYB_BASIC", "KYB_BYO"],
beneficial_owner_entities: Iterable[account_holder_create_params.KYBBeneficialOwnerEntity] | Omit = omit,
external_id: str | Omit = omit,
kyb_passed_timestamp: str | Omit = omit,
naics_code: str | Omit = omit,
Expand Down Expand Up @@ -1220,8 +1207,6 @@ async def create(

workflow: Specifies the type of KYB workflow to run.

beneficial_owner_entities: Deprecated.

external_id: A user provided id that can be used to link an account holder with an external
system

Expand Down Expand Up @@ -1471,7 +1456,6 @@ async def create(
| Literal["KYC_BASIC", "KYC_BYO"]
| Literal["KYC_EXEMPT"]
| Omit = omit,
beneficial_owner_entities: Iterable[account_holder_create_params.KYBBeneficialOwnerEntity] | Omit = omit,
external_id: str | Omit = omit,
kyb_passed_timestamp: str | Omit = omit,
naics_code: str | Omit = omit,
Expand Down Expand Up @@ -1504,7 +1488,6 @@ async def create(
"nature_of_business": nature_of_business,
"tos_timestamp": tos_timestamp,
"workflow": workflow,
"beneficial_owner_entities": beneficial_owner_entities,
"external_id": external_id,
"kyb_passed_timestamp": kyb_passed_timestamp,
"naics_code": naics_code,
Expand Down Expand Up @@ -1568,8 +1551,6 @@ async def update(
self,
account_holder_token: str,
*,
beneficial_owner_entities: Iterable[account_holder_update_params.KYBPatchRequestBeneficialOwnerEntity]
| Omit = omit,
beneficial_owner_individuals: Iterable[account_holder_update_params.KYBPatchRequestBeneficialOwnerIndividual]
| Omit = omit,
business_entity: account_holder_update_params.KYBPatchRequestBusinessEntity | Omit = omit,
Expand Down Expand Up @@ -1598,8 +1579,6 @@ async def update(
the program that the calling API key manages.

Args:
beneficial_owner_entities: Deprecated.

beneficial_owner_individuals: You must submit a list of all direct and indirect individuals with 25% or more
ownership in the company. A maximum of 4 beneficial owners can be submitted. If
no individual owns 25% of the company you do not need to send beneficial owner
Expand Down Expand Up @@ -1748,8 +1727,6 @@ async def update(
self,
account_holder_token: str,
*,
beneficial_owner_entities: Iterable[account_holder_update_params.KYBPatchRequestBeneficialOwnerEntity]
| Omit = omit,
beneficial_owner_individuals: Iterable[account_holder_update_params.KYBPatchRequestBeneficialOwnerIndividual]
| Omit = omit,
business_entity: account_holder_update_params.KYBPatchRequestBusinessEntity | Omit = omit,
Expand Down Expand Up @@ -1783,7 +1760,6 @@ async def update(
f"/v1/account_holders/{account_holder_token}",
body=await async_maybe_transform(
{
"beneficial_owner_entities": beneficial_owner_entities,
"beneficial_owner_individuals": beneficial_owner_individuals,
"business_entity": business_entity,
"control_person": control_person,
Expand Down
16 changes: 8 additions & 8 deletions src/lithic/resources/account_holders/entities.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ def create(
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> EntityCreateResponse:
"""
Create a new beneficial owner or replace the control person entity on an
existing KYB account holder. This endpoint is only applicable for account
Create a new beneficial owner individual or replace the control person entity on
an existing KYB account holder. This endpoint is only applicable for account
holders enrolled through a KYB workflow with the Persona KYB provider. A new
control person can only replace the existing one. A maximum of 4 beneficial
owners can be associated with an account holder.
Expand Down Expand Up @@ -133,10 +133,10 @@ def delete(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> AccountHolderEntity:
"""Deactivate a beneficial owner entity on an existing KYB account holder.
"""Deactivate a beneficial owner individual on an existing KYB account holder.

Only
beneficial owner entities can be deactivated.
beneficial owner individuals can be deactivated.

Args:
extra_headers: Send extra headers
Expand Down Expand Up @@ -202,8 +202,8 @@ async def create(
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> EntityCreateResponse:
"""
Create a new beneficial owner or replace the control person entity on an
existing KYB account holder. This endpoint is only applicable for account
Create a new beneficial owner individual or replace the control person entity on
an existing KYB account holder. This endpoint is only applicable for account
holders enrolled through a KYB workflow with the Persona KYB provider. A new
control person can only replace the existing one. A maximum of 4 beneficial
owners can be associated with an account holder.
Expand Down Expand Up @@ -275,10 +275,10 @@ async def delete(
extra_body: Body | None = None,
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> AccountHolderEntity:
"""Deactivate a beneficial owner entity on an existing KYB account holder.
"""Deactivate a beneficial owner individual on an existing KYB account holder.

Only
beneficial owner entities can be deactivated.
beneficial owner individuals can be deactivated.

Args:
extra_headers: Send extra headers
Expand Down
22 changes: 21 additions & 1 deletion src/lithic/resources/auth_rules/v2/v2.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from __future__ import annotations

from typing import Any, List, Union, Optional, cast
from datetime import date
from datetime import date, datetime
from typing_extensions import Literal, overload

import httpx
Expand Down Expand Up @@ -634,6 +634,8 @@ def list_results(
self,
*,
auth_rule_token: str | Omit = omit,
begin: Union[str, datetime] | Omit = omit,
end: Union[str, datetime] | Omit = omit,
ending_before: str | Omit = omit,
event_token: str | Omit = omit,
has_actions: bool | Omit = omit,
Expand All @@ -658,6 +660,12 @@ def list_results(
Args:
auth_rule_token: Filter by Auth Rule token

begin: Date string in RFC 3339 format. Only events evaluated after the specified time
will be included. UTC time zone.

end: Date string in RFC 3339 format. Only events evaluated before the specified time
will be included. UTC time zone.

ending_before: A cursor representing an item's token before which a page of results should end.
Used to retrieve the previous page of results before this item.

Expand Down Expand Up @@ -690,6 +698,8 @@ def list_results(
query=maybe_transform(
{
"auth_rule_token": auth_rule_token,
"begin": begin,
"end": end,
"ending_before": ending_before,
"event_token": event_token,
"has_actions": has_actions,
Expand Down Expand Up @@ -1442,6 +1452,8 @@ def list_results(
self,
*,
auth_rule_token: str | Omit = omit,
begin: Union[str, datetime] | Omit = omit,
end: Union[str, datetime] | Omit = omit,
ending_before: str | Omit = omit,
event_token: str | Omit = omit,
has_actions: bool | Omit = omit,
Expand All @@ -1466,6 +1478,12 @@ def list_results(
Args:
auth_rule_token: Filter by Auth Rule token

begin: Date string in RFC 3339 format. Only events evaluated after the specified time
will be included. UTC time zone.

end: Date string in RFC 3339 format. Only events evaluated before the specified time
will be included. UTC time zone.

ending_before: A cursor representing an item's token before which a page of results should end.
Used to retrieve the previous page of results before this item.

Expand Down Expand Up @@ -1498,6 +1516,8 @@ def list_results(
query=maybe_transform(
{
"auth_rule_token": auth_rule_token,
"begin": begin,
"end": end,
"ending_before": ending_before,
"event_token": event_token,
"has_actions": has_actions,
Expand Down
8 changes: 8 additions & 0 deletions src/lithic/resources/payments.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ def create(
method_attributes: payment_create_params.MethodAttributes,
type: Literal["COLLECTION", "PAYMENT"],
token: str | Omit = omit,
hold: payment_create_params.Hold | Omit = omit,
memo: str | Omit = omit,
user_defined_id: str | Omit = omit,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -82,6 +83,8 @@ def create(
token: Customer-provided token that will serve as an idempotency token. This token will
become the transaction token.

hold: Optional hold to settle when this payment is initiated.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request
Expand All @@ -101,6 +104,7 @@ def create(
"method_attributes": method_attributes,
"type": type,
"token": token,
"hold": hold,
"memo": memo,
"user_defined_id": user_defined_id,
},
Expand Down Expand Up @@ -566,6 +570,7 @@ async def create(
method_attributes: payment_create_params.MethodAttributes,
type: Literal["COLLECTION", "PAYMENT"],
token: str | Omit = omit,
hold: payment_create_params.Hold | Omit = omit,
memo: str | Omit = omit,
user_defined_id: str | Omit = omit,
# Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs.
Expand All @@ -582,6 +587,8 @@ async def create(
token: Customer-provided token that will serve as an idempotency token. This token will
become the transaction token.

hold: Optional hold to settle when this payment is initiated.

extra_headers: Send extra headers

extra_query: Add additional query parameters to the request
Expand All @@ -601,6 +608,7 @@ async def create(
"method_attributes": method_attributes,
"type": type,
"token": token,
"hold": hold,
"memo": memo,
"user_defined_id": user_defined_id,
},
Expand Down
Loading