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.110.1"
".": "0.111.0"
}
8 changes: 4 additions & 4 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 167
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-c3f6c23018d70fd1b259b21cfd377b5d905872f0d3c5ce2cdb8013f4b6daa338.yml
openapi_spec_hash: b551344da9d29eb4c5374874ed84a9b0
config_hash: 012f050e575d1bbfe8db56a9eeaa5fcd
configured_endpoints: 171
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-9791980619fc7ce8afb01f77dfe3c660a540975327378287cb666136ae4b0a99.yml
openapi_spec_hash: 0752074b2a7b0534329a1e3176c94a62
config_hash: aab05d0cf41f1f6b9f4d5677273c1600
20 changes: 20 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,25 @@
# Changelog

## 0.111.0 (2025-11-20)

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

### Features

* **api:** add disputes V2 endpoints ([a346176](https://github.com/lithic-com/lithic-python/commit/a3461767eaf97aa5b10dd356513a401644599722))
* **api:** Add Payoff Details ([8408ced](https://github.com/lithic-com/lithic-python/commit/8408ced534e41f25de0b62aa8f6ca0735001994a))
* **api:** add return payment method ([a346176](https://github.com/lithic-com/lithic-python/commit/a3461767eaf97aa5b10dd356513a401644599722))
* **api:** add Tokenization and ACH Rules ([a346176](https://github.com/lithic-com/lithic-python/commit/a3461767eaf97aa5b10dd356513a401644599722))
* **api:** add unpause external_bank_accounts API method ([a346176](https://github.com/lithic-com/lithic-python/commit/a3461767eaf97aa5b10dd356513a401644599722))
* **api:** extract some common schemas into models ([a346176](https://github.com/lithic-com/lithic-python/commit/a3461767eaf97aa5b10dd356513a401644599722))


### Bug Fixes

* **api:** change allowed phone number length from 18 to 16 ([a346176](https://github.com/lithic-com/lithic-python/commit/a3461767eaf97aa5b10dd356513a401644599722))
* **api:** mark certain optional fields as nullable ([a346176](https://github.com/lithic-com/lithic-python/commit/a3461767eaf97aa5b10dd356513a401644599722))
* **api:** Modify return type of returns API to payment-transaction ([8408ced](https://github.com/lithic-com/lithic-python/commit/8408ced534e41f25de0b62aa8f6ca0735001994a))

## 0.110.1 (2025-11-11)

Full Changelog: [v0.110.0...v0.110.1](https://github.com/lithic-com/lithic-python/compare/v0.110.0...v0.110.1)
Expand Down
46 changes: 30 additions & 16 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ from lithic.types import (
Carrier,
Currency,
Document,
FinancialEvent,
InstanceFinancialAccountType,
Merchant,
ShippingAddress,
)
```
Expand Down Expand Up @@ -82,9 +84,13 @@ from lithic.types.auth_rules import (
AuthRule,
AuthRuleCondition,
Conditional3DSActionParameters,
ConditionalACHActionParameters,
ConditionalAttribute,
ConditionalAuthorizationActionParameters,
ConditionalBlockParameters,
ConditionalOperation,
ConditionalTokenizationActionParameters,
ConditionalValue,
MerchantLockParameters,
RuleStats,
VelocityLimitParams,
Expand Down Expand Up @@ -269,30 +275,35 @@ Methods:
Types:

```python
from lithic.types import (
Dispute,
DisputeEvidence,
DisputeCreateResponse,
DisputeRetrieveResponse,
DisputeUpdateResponse,
DisputeListResponse,
DisputeDeleteResponse,
)
from lithic.types import Dispute, DisputeEvidence
```

Methods:

- <code title="post /v1/disputes">client.disputes.<a href="./src/lithic/resources/disputes.py">create</a>(\*\*<a href="src/lithic/types/dispute_create_params.py">params</a>) -> <a href="./src/lithic/types/dispute_create_response.py">DisputeCreateResponse</a></code>
- <code title="get /v1/disputes/{dispute_token}">client.disputes.<a href="./src/lithic/resources/disputes.py">retrieve</a>(dispute_token) -> <a href="./src/lithic/types/dispute_retrieve_response.py">DisputeRetrieveResponse</a></code>
- <code title="patch /v1/disputes/{dispute_token}">client.disputes.<a href="./src/lithic/resources/disputes.py">update</a>(dispute_token, \*\*<a href="src/lithic/types/dispute_update_params.py">params</a>) -> <a href="./src/lithic/types/dispute_update_response.py">DisputeUpdateResponse</a></code>
- <code title="get /v1/disputes">client.disputes.<a href="./src/lithic/resources/disputes.py">list</a>(\*\*<a href="src/lithic/types/dispute_list_params.py">params</a>) -> <a href="./src/lithic/types/dispute_list_response.py">SyncCursorPage[DisputeListResponse]</a></code>
- <code title="delete /v1/disputes/{dispute_token}">client.disputes.<a href="./src/lithic/resources/disputes.py">delete</a>(dispute_token) -> <a href="./src/lithic/types/dispute_delete_response.py">DisputeDeleteResponse</a></code>
- <code title="post /v1/disputes">client.disputes.<a href="./src/lithic/resources/disputes.py">create</a>(\*\*<a href="src/lithic/types/dispute_create_params.py">params</a>) -> <a href="./src/lithic/types/dispute.py">Dispute</a></code>
- <code title="get /v1/disputes/{dispute_token}">client.disputes.<a href="./src/lithic/resources/disputes.py">retrieve</a>(dispute_token) -> <a href="./src/lithic/types/dispute.py">Dispute</a></code>
- <code title="patch /v1/disputes/{dispute_token}">client.disputes.<a href="./src/lithic/resources/disputes.py">update</a>(dispute_token, \*\*<a href="src/lithic/types/dispute_update_params.py">params</a>) -> <a href="./src/lithic/types/dispute.py">Dispute</a></code>
- <code title="get /v1/disputes">client.disputes.<a href="./src/lithic/resources/disputes.py">list</a>(\*\*<a href="src/lithic/types/dispute_list_params.py">params</a>) -> <a href="./src/lithic/types/dispute.py">SyncCursorPage[Dispute]</a></code>
- <code title="delete /v1/disputes/{dispute_token}">client.disputes.<a href="./src/lithic/resources/disputes.py">delete</a>(dispute_token) -> <a href="./src/lithic/types/dispute.py">Dispute</a></code>
- <code title="delete /v1/disputes/{dispute_token}/evidences/{evidence_token}">client.disputes.<a href="./src/lithic/resources/disputes.py">delete_evidence</a>(evidence_token, \*, dispute_token) -> <a href="./src/lithic/types/dispute_evidence.py">DisputeEvidence</a></code>
- <code title="post /v1/disputes/{dispute_token}/evidences">client.disputes.<a href="./src/lithic/resources/disputes.py">initiate_evidence_upload</a>(dispute_token, \*\*<a href="src/lithic/types/dispute_initiate_evidence_upload_params.py">params</a>) -> <a href="./src/lithic/types/dispute_evidence.py">DisputeEvidence</a></code>
- <code title="get /v1/disputes/{dispute_token}/evidences">client.disputes.<a href="./src/lithic/resources/disputes.py">list_evidences</a>(dispute_token, \*\*<a href="src/lithic/types/dispute_list_evidences_params.py">params</a>) -> <a href="./src/lithic/types/dispute_evidence.py">SyncCursorPage[DisputeEvidence]</a></code>
- <code title="get /v1/disputes/{dispute_token}/evidences/{evidence_token}">client.disputes.<a href="./src/lithic/resources/disputes.py">retrieve_evidence</a>(evidence_token, \*, dispute_token) -> <a href="./src/lithic/types/dispute_evidence.py">DisputeEvidence</a></code>
- <code>client.disputes.<a href="./src/lithic/resources/disputes.py">upload_evidence</a>(\*args) -> None</code>

# DisputesV2

Types:

```python
from lithic.types import DisputeV2
```

Methods:

- <code title="get /v2/disputes/{dispute_token}">client.disputes_v2.<a href="./src/lithic/resources/disputes_v2.py">retrieve</a>(dispute_token) -> <a href="./src/lithic/types/dispute_v2.py">DisputeV2</a></code>
- <code title="get /v2/disputes">client.disputes_v2.<a href="./src/lithic/resources/disputes_v2.py">list</a>(\*\*<a href="src/lithic/types/disputes_v2_list_params.py">params</a>) -> <a href="./src/lithic/types/dispute_v2.py">SyncCursorPage[DisputeV2]</a></code>

# Events

Types:
Expand Down Expand Up @@ -341,7 +352,7 @@ Methods:
Types:

```python
from lithic.types import FinancialAccount, FinancialTransaction
from lithic.types import CategoryDetails, FinancialAccount, FinancialTransaction, StatementTotals
```

Methods:
Expand Down Expand Up @@ -415,7 +426,7 @@ Methods:
Types:

```python
from lithic.types.financial_accounts import LoanTape
from lithic.types.financial_accounts import CategoryBalances, LoanTape
```

Methods:
Expand Down Expand Up @@ -517,6 +528,7 @@ from lithic.types import (
ExternalBankAccountListResponse,
ExternalBankAccountRetryMicroDepositsResponse,
ExternalBankAccountRetryPrenoteResponse,
ExternalBankAccountUnpauseResponse,
)
```

Expand All @@ -528,6 +540,7 @@ Methods:
- <code title="get /v1/external_bank_accounts">client.external_bank_accounts.<a href="./src/lithic/resources/external_bank_accounts/external_bank_accounts.py">list</a>(\*\*<a href="src/lithic/types/external_bank_account_list_params.py">params</a>) -> <a href="./src/lithic/types/external_bank_account_list_response.py">SyncCursorPage[ExternalBankAccountListResponse]</a></code>
- <code title="post /v1/external_bank_accounts/{external_bank_account_token}/retry_micro_deposits">client.external_bank_accounts.<a href="./src/lithic/resources/external_bank_accounts/external_bank_accounts.py">retry_micro_deposits</a>(external_bank_account_token, \*\*<a href="src/lithic/types/external_bank_account_retry_micro_deposits_params.py">params</a>) -> <a href="./src/lithic/types/external_bank_account_retry_micro_deposits_response.py">ExternalBankAccountRetryMicroDepositsResponse</a></code>
- <code title="post /v1/external_bank_accounts/{external_bank_account_token}/retry_prenote">client.external_bank_accounts.<a href="./src/lithic/resources/external_bank_accounts/external_bank_accounts.py">retry_prenote</a>(external_bank_account_token, \*\*<a href="src/lithic/types/external_bank_account_retry_prenote_params.py">params</a>) -> <a href="./src/lithic/types/external_bank_account_retry_prenote_response.py">ExternalBankAccountRetryPrenoteResponse</a></code>
- <code title="post /v1/external_bank_accounts/{external_bank_account_token}/unpause">client.external_bank_accounts.<a href="./src/lithic/resources/external_bank_accounts/external_bank_accounts.py">unpause</a>(external_bank_account_token) -> <a href="./src/lithic/types/external_bank_account_unpause_response.py">ExternalBankAccountUnpauseResponse</a></code>

## MicroDeposits

Expand Down Expand Up @@ -563,6 +576,7 @@ Methods:
- <code title="get /v1/payments/{payment_token}">client.payments.<a href="./src/lithic/resources/payments.py">retrieve</a>(payment_token) -> <a href="./src/lithic/types/payment.py">Payment</a></code>
- <code title="get /v1/payments">client.payments.<a href="./src/lithic/resources/payments.py">list</a>(\*\*<a href="src/lithic/types/payment_list_params.py">params</a>) -> <a href="./src/lithic/types/payment.py">SyncCursorPage[Payment]</a></code>
- <code title="post /v1/payments/{payment_token}/retry">client.payments.<a href="./src/lithic/resources/payments.py">retry</a>(payment_token) -> <a href="./src/lithic/types/payment_retry_response.py">PaymentRetryResponse</a></code>
- <code title="post /v1/payments/{payment_token}/return">client.payments.<a href="./src/lithic/resources/payments.py">return\_</a>(payment_token, \*\*<a href="src/lithic/types/payment_return_params.py">params</a>) -> <a href="./src/lithic/types/payment.py">Payment</a></code>
- <code title="post /v1/simulate/payments/{payment_token}/action">client.payments.<a href="./src/lithic/resources/payments.py">simulate_action</a>(payment_token, \*\*<a href="src/lithic/types/payment_simulate_action_params.py">params</a>) -> <a href="./src/lithic/types/payment_simulate_action_response.py">PaymentSimulateActionResponse</a></code>
- <code title="post /v1/simulate/payments/receipt">client.payments.<a href="./src/lithic/resources/payments.py">simulate_receipt</a>(\*\*<a href="src/lithic/types/payment_simulate_receipt_params.py">params</a>) -> <a href="./src/lithic/types/payment_simulate_receipt_response.py">PaymentSimulateReceiptResponse</a></code>
- <code title="post /v1/simulate/payments/release">client.payments.<a href="./src/lithic/resources/payments.py">simulate_release</a>(\*\*<a href="src/lithic/types/payment_simulate_release_params.py">params</a>) -> <a href="./src/lithic/types/payment_simulate_release_response.py">PaymentSimulateReleaseResponse</a></code>
Expand Down
4 changes: 2 additions & 2 deletions examples/upload_evidence.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# 1. Install Rye and setup a Python virtual environment: ./scripts/bootstrap
# 2. Run the example: LITHIC_API_KEY=<your_api_key> rye run python examples/upload_evidence.py
from lithic import Lithic, file_from_path
from lithic.types import DisputeListResponse, DisputeCreateResponse
from lithic.types import Dispute

client = Lithic(environment="sandbox")

Expand All @@ -17,7 +17,7 @@
assert transaction.token, "Transaction must have a token"

disputes_page = client.disputes.list()
dispute: DisputeCreateResponse | DisputeListResponse | None = disputes_page.data[0] if disputes_page.data else None
dispute: Dispute | None = disputes_page.data[0] if disputes_page.data else None
if not dispute:
dispute = client.disputes.create(
amount=42,
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.110.1"
version = "0.111.0"
description = "The official Python library for the lithic API"
dynamic = ["readme"]
license = "Apache-2.0"
Expand Down
38 changes: 38 additions & 0 deletions src/lithic/_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
three_ds,
webhooks,
auth_rules,
disputes_v2,
transactions,
card_programs,
tokenizations,
Expand All @@ -73,6 +74,7 @@
from .resources.disputes import Disputes, AsyncDisputes
from .resources.payments import Payments, AsyncPayments
from .resources.cards.cards import Cards, AsyncCards
from .resources.disputes_v2 import DisputesV2, AsyncDisputesV2
from .resources.fraud.fraud import Fraud, AsyncFraud
from .resources.card_programs import CardPrograms, AsyncCardPrograms
from .resources.events.events import Events, AsyncEvents
Expand Down Expand Up @@ -262,6 +264,12 @@ def disputes(self) -> Disputes:

return Disputes(self)

@cached_property
def disputes_v2(self) -> DisputesV2:
from .resources.disputes_v2 import DisputesV2

return DisputesV2(self)

@cached_property
def events(self) -> Events:
from .resources.events import Events
Expand Down Expand Up @@ -660,6 +668,12 @@ def disputes(self) -> AsyncDisputes:

return AsyncDisputes(self)

@cached_property
def disputes_v2(self) -> AsyncDisputesV2:
from .resources.disputes_v2 import AsyncDisputesV2

return AsyncDisputesV2(self)

@cached_property
def events(self) -> AsyncEvents:
from .resources.events import AsyncEvents
Expand Down Expand Up @@ -981,6 +995,12 @@ def disputes(self) -> disputes.DisputesWithRawResponse:

return DisputesWithRawResponse(self._client.disputes)

@cached_property
def disputes_v2(self) -> disputes_v2.DisputesV2WithRawResponse:
from .resources.disputes_v2 import DisputesV2WithRawResponse

return DisputesV2WithRawResponse(self._client.disputes_v2)

@cached_property
def events(self) -> events.EventsWithRawResponse:
from .resources.events import EventsWithRawResponse
Expand Down Expand Up @@ -1160,6 +1180,12 @@ def disputes(self) -> disputes.AsyncDisputesWithRawResponse:

return AsyncDisputesWithRawResponse(self._client.disputes)

@cached_property
def disputes_v2(self) -> disputes_v2.AsyncDisputesV2WithRawResponse:
from .resources.disputes_v2 import AsyncDisputesV2WithRawResponse

return AsyncDisputesV2WithRawResponse(self._client.disputes_v2)

@cached_property
def events(self) -> events.AsyncEventsWithRawResponse:
from .resources.events import AsyncEventsWithRawResponse
Expand Down Expand Up @@ -1339,6 +1365,12 @@ def disputes(self) -> disputes.DisputesWithStreamingResponse:

return DisputesWithStreamingResponse(self._client.disputes)

@cached_property
def disputes_v2(self) -> disputes_v2.DisputesV2WithStreamingResponse:
from .resources.disputes_v2 import DisputesV2WithStreamingResponse

return DisputesV2WithStreamingResponse(self._client.disputes_v2)

@cached_property
def events(self) -> events.EventsWithStreamingResponse:
from .resources.events import EventsWithStreamingResponse
Expand Down Expand Up @@ -1518,6 +1550,12 @@ def disputes(self) -> disputes.AsyncDisputesWithStreamingResponse:

return AsyncDisputesWithStreamingResponse(self._client.disputes)

@cached_property
def disputes_v2(self) -> disputes_v2.AsyncDisputesV2WithStreamingResponse:
from .resources.disputes_v2 import AsyncDisputesV2WithStreamingResponse

return AsyncDisputesV2WithStreamingResponse(self._client.disputes_v2)

@cached_property
def events(self) -> events.AsyncEventsWithStreamingResponse:
from .resources.events import AsyncEventsWithStreamingResponse
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.110.1" # x-release-please-version
__version__ = "0.111.0" # x-release-please-version
14 changes: 14 additions & 0 deletions src/lithic/resources/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,14 @@
AuthRulesWithStreamingResponse,
AsyncAuthRulesWithStreamingResponse,
)
from .disputes_v2 import (
DisputesV2,
AsyncDisputesV2,
DisputesV2WithRawResponse,
AsyncDisputesV2WithRawResponse,
DisputesV2WithStreamingResponse,
AsyncDisputesV2WithStreamingResponse,
)
from .transactions import (
Transactions,
AsyncTransactions,
Expand Down Expand Up @@ -287,6 +295,12 @@
"AsyncDisputesWithRawResponse",
"DisputesWithStreamingResponse",
"AsyncDisputesWithStreamingResponse",
"DisputesV2",
"AsyncDisputesV2",
"DisputesV2WithRawResponse",
"AsyncDisputesV2WithRawResponse",
"DisputesV2WithStreamingResponse",
"AsyncDisputesV2WithStreamingResponse",
"Events",
"AsyncEvents",
"EventsWithRawResponse",
Expand Down
Loading