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
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
lint:
timeout-minutes: 10
name: lint
runs-on: ${{ github.repository == 'stainless-sdks/lithic-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
runs-on: ${{ startsWith(github.repository, 'stainless-sdks/') && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata')
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
Expand All @@ -44,7 +44,7 @@ jobs:
permissions:
contents: read
id-token: write
runs-on: ${{ github.repository == 'stainless-sdks/lithic-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
runs-on: ${{ startsWith(github.repository, 'stainless-sdks/') && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2

Expand Down Expand Up @@ -84,7 +84,7 @@ jobs:
test:
timeout-minutes: 10
name: test
runs-on: ${{ github.repository == 'stainless-sdks/lithic-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
runs-on: ${{ startsWith(github.repository, 'stainless-sdks/') && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: github.event_name == 'push' || github.event.pull_request.head.repo.fork
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
Expand All @@ -106,7 +106,7 @@ jobs:
examples:
timeout-minutes: 10
name: examples
runs-on: ${{ github.repository == 'stainless-sdks/lithic-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
runs-on: ${{ startsWith(github.repository, 'stainless-sdks/') && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
if: github.repository == 'lithic-com/lithic-python' && (github.event_name == 'push' || github.event.pull_request.head.repo.fork) && (github.event_name != 'push' || github.event.head_commit.message != 'codegen metadata')

steps:
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.129.0"
".": "0.130.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: 213
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-9e397c65ffb81e2928b8ecf979769a79131ae6058b6fb373a5e930dc8a168732.yml
openapi_spec_hash: 93aea3855d2d1c390107d223762aa818
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-2d2600072500797474f0d7798c1a8b668bfbc4e0c6a8f076ca7b4cc7ad82058b.yml
openapi_spec_hash: 7605eb6be77a3d150078916f0eb0e9ac
config_hash: 5bb913c05ebeb301ec925b16e75bb251
17 changes: 17 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,22 @@
# Changelog

## 0.130.0 (2026-07-17)

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

### Features

* **api:** add embed.session_generated and embed.viewed webhook events ([84ae573](https://github.com/lithic-com/lithic-python/commit/84ae5737ab2f64c05b512dc8cc0ac6de0579de70))
* **api:** add PAYMENT enum value to book_transfers ([64b5358](https://github.com/lithic-com/lithic-python/commit/64b535810856b0344875a50a10bfed3212a1bb8a))
* **stlc:** configurable CI runner and private-production-repo support in workflow templates ([d2bf66d](https://github.com/lithic-com/lithic-python/commit/d2bf66d3cb39aaeb20363b620223a1c010aaf846))


### Documentation

* **api:** clarify dispute event descriptions in Event model ([92638f2](https://github.com/lithic-com/lithic-python/commit/92638f2617ed8c2114082008a5d30171bbdd17ae))
* **api:** clarify simulate_clearing behavior in transactions ([85d2d96](https://github.com/lithic-com/lithic-python/commit/85d2d9657022d3e7848477b329ba7f347efa7007))
* **api:** update category parameter description in external_payments ([7c331aa](https://github.com/lithic-com/lithic-python/commit/7c331aae7db42d9e5663d71d26ec2f8a7ee91153))

## 0.129.0 (2026-06-29)

Full Changelog: [v0.128.0...v0.129.0](https://github.com/lithic-com/lithic-python/compare/v0.128.0...v0.129.0)
Expand Down
2 changes: 2 additions & 0 deletions api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1015,6 +1015,8 @@ from lithic.types import (
DigitalWalletTokenizationUpdatedWebhookEvent,
DisputeUpdatedWebhookEvent,
DisputeEvidenceUploadFailedWebhookEvent,
EmbedSessionGeneratedWebhookEvent,
EmbedViewedWebhookEvent,
ExternalBankAccountCreatedWebhookEvent,
ExternalBankAccountUpdatedWebhookEvent,
ExternalPaymentCreatedWebhookEvent,
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.129.0"
version = "0.130.0"
description = "The official Python library for the lithic API"
dynamic = ["readme"]
license = "Apache-2.0"
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.129.0" # x-release-please-version
__version__ = "0.130.0" # x-release-please-version
2 changes: 2 additions & 0 deletions src/lithic/resources/book_transfers.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ def create(
"INTEREST",
"LATE_PAYMENT",
"BILL_PAYMENT",
"PAYMENT_FEE",
"CASH_BACK",
"ACCOUNT_TO_ACCOUNT",
"CARD_TO_CARD",
Expand Down Expand Up @@ -445,6 +446,7 @@ async def create(
"INTEREST",
"LATE_PAYMENT",
"BILL_PAYMENT",
"PAYMENT_FEE",
"CASH_BACK",
"ACCOUNT_TO_ACCOUNT",
"CARD_TO_CARD",
Expand Down
33 changes: 25 additions & 8 deletions src/lithic/resources/cards/cards.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import json
import base64
import hashlib
import typing_extensions
from typing import Any, Union, cast
from datetime import datetime, timezone, timedelta
from typing_extensions import Literal
Expand Down Expand Up @@ -675,6 +676,7 @@ def convert_physical(
cast_to=Card,
)

@typing_extensions.deprecated("deprecated")
def embed(
self,
*,
Expand All @@ -688,6 +690,9 @@ def embed(
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> str:
"""
**Deprecated.** Use the modern embedded card flow instead: create a session with
`POST /v1/cards/{card_token}/embed` and render it via `GET /v1/embed`.

Handling full card PANs and CVV codes requires that you comply with the Payment
Card Industry Data Security Standards (PCI DSS). Some clients choose to reduce
their compliance obligations by leveraging our embedded card UI solution
Expand Down Expand Up @@ -1903,6 +1908,7 @@ async def convert_physical(
cast_to=Card,
)

@typing_extensions.deprecated("deprecated")
async def embed(
self,
*,
Expand All @@ -1916,6 +1922,9 @@ async def embed(
timeout: float | httpx.Timeout | None | NotGiven = not_given,
) -> str:
"""
**Deprecated.** Use the modern embedded card flow instead: create a session with
`POST /v1/cards/{card_token}/embed` and render it via `GET /v1/embed`.

Handling full card PANs and CVV codes requires that you comply with the Payment
Card Industry Data Security Standards (PCI DSS). Some clients choose to reduce
their compliance obligations by leveraging our embedded card UI solution
Expand Down Expand Up @@ -2539,8 +2548,10 @@ def __init__(self, cards: Cards) -> None:
self.convert_physical = _legacy_response.to_raw_response_wrapper(
cards.convert_physical,
)
self.embed = _legacy_response.to_raw_response_wrapper(
cards.embed,
self.embed = ( # pyright: ignore[reportDeprecated]
_legacy_response.to_raw_response_wrapper(
cards.embed, # pyright: ignore[reportDeprecated],
)
)
self.provision = _legacy_response.to_raw_response_wrapper(
cards.provision,
Expand Down Expand Up @@ -2592,8 +2603,10 @@ def __init__(self, cards: AsyncCards) -> None:
self.convert_physical = _legacy_response.async_to_raw_response_wrapper(
cards.convert_physical,
)
self.embed = _legacy_response.async_to_raw_response_wrapper(
cards.embed,
self.embed = ( # pyright: ignore[reportDeprecated]
_legacy_response.async_to_raw_response_wrapper(
cards.embed, # pyright: ignore[reportDeprecated],
)
)
self.provision = _legacy_response.async_to_raw_response_wrapper(
cards.provision,
Expand Down Expand Up @@ -2645,8 +2658,10 @@ def __init__(self, cards: Cards) -> None:
self.convert_physical = to_streamed_response_wrapper(
cards.convert_physical,
)
self.embed = to_streamed_response_wrapper(
cards.embed,
self.embed = ( # pyright: ignore[reportDeprecated]
to_streamed_response_wrapper(
cards.embed, # pyright: ignore[reportDeprecated],
)
)
self.provision = to_streamed_response_wrapper(
cards.provision,
Expand Down Expand Up @@ -2698,8 +2713,10 @@ def __init__(self, cards: AsyncCards) -> None:
self.convert_physical = async_to_streamed_response_wrapper(
cards.convert_physical,
)
self.embed = async_to_streamed_response_wrapper(
cards.embed,
self.embed = ( # pyright: ignore[reportDeprecated]
async_to_streamed_response_wrapper(
cards.embed, # pyright: ignore[reportDeprecated],
)
)
self.provision = async_to_streamed_response_wrapper(
cards.provision,
Expand Down
4 changes: 4 additions & 0 deletions src/lithic/resources/events/events.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,8 @@ def list(
"dispute_transaction.created",
"dispute_transaction.updated",
"dispute.updated",
"embed.session_generated",
"embed.viewed",
"external_bank_account.created",
"external_bank_account.updated",
"external_payment.created",
Expand Down Expand Up @@ -421,6 +423,8 @@ def list(
"dispute_transaction.created",
"dispute_transaction.updated",
"dispute.updated",
"embed.session_generated",
"embed.viewed",
"external_bank_account.created",
"external_bank_account.updated",
"external_payment.created",
Expand Down
12 changes: 12 additions & 0 deletions src/lithic/resources/events/subscriptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ def create(
"dispute_transaction.created",
"dispute_transaction.updated",
"dispute.updated",
"embed.session_generated",
"embed.viewed",
"external_bank_account.created",
"external_bank_account.updated",
"external_payment.created",
Expand Down Expand Up @@ -245,6 +247,8 @@ def update(
"dispute_transaction.created",
"dispute_transaction.updated",
"dispute.updated",
"embed.session_generated",
"embed.viewed",
"external_bank_account.created",
"external_bank_account.updated",
"external_payment.created",
Expand Down Expand Up @@ -721,6 +725,8 @@ def send_simulated_example(
"dispute_transaction.created",
"dispute_transaction.updated",
"dispute.updated",
"embed.session_generated",
"embed.viewed",
"external_bank_account.created",
"external_bank_account.updated",
"external_payment.created",
Expand Down Expand Up @@ -851,6 +857,8 @@ async def create(
"dispute_transaction.created",
"dispute_transaction.updated",
"dispute.updated",
"embed.session_generated",
"embed.viewed",
"external_bank_account.created",
"external_bank_account.updated",
"external_payment.created",
Expand Down Expand Up @@ -1004,6 +1012,8 @@ async def update(
"dispute_transaction.created",
"dispute_transaction.updated",
"dispute.updated",
"embed.session_generated",
"embed.viewed",
"external_bank_account.created",
"external_bank_account.updated",
"external_payment.created",
Expand Down Expand Up @@ -1480,6 +1490,8 @@ async def send_simulated_example(
"dispute_transaction.created",
"dispute_transaction.updated",
"dispute.updated",
"embed.session_generated",
"embed.viewed",
"external_bank_account.created",
"external_bank_account.updated",
"external_payment.created",
Expand Down
4 changes: 2 additions & 2 deletions src/lithic/resources/external_payments.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ def list(
Only entries created after the specified time
will be included. UTC time zone.

category: External Payment category to be returned.
category: The external rail the funds moved on

end: Date string in RFC 3339 format. Only entries created before the specified time
will be included. UTC time zone.
Expand Down Expand Up @@ -563,7 +563,7 @@ def list(
Only entries created after the specified time
will be included. UTC time zone.

category: External Payment category to be returned.
category: The external rail the funds moved on

end: Date string in RFC 3339 format. Only entries created before the specified time
will be included. UTC time zone.
Expand Down
28 changes: 16 additions & 12 deletions src/lithic/resources/transactions/transactions.py
Original file line number Diff line number Diff line change
Expand Up @@ -470,9 +470,10 @@ def simulate_clearing(
After this event, the
transaction transitions from `PENDING` to `SETTLED` status.

If `amount` is not set, the full amount of the transaction will be cleared.
Transactions that have already cleared, either partially or fully, cannot be
cleared again using this endpoint.
If `amount` is not set, the full amount of the transaction will be cleared. This
endpoint may be called multiple times against the same authorization to simulate
a multiple-completion scenario, with each call creating a separate clearing
event.

Args:
token: The transaction token returned from the /v1/simulate/authorize response.
Expand All @@ -483,9 +484,10 @@ def simulate_clearing(
example, entering 100 in this field will result in a -100 amount in the
transaction, if the original authorization is a credit authorization.

If `amount` is not set, the full amount of the transaction will be cleared.
Transactions that have already cleared, either partially or fully, cannot be
cleared again using this endpoint.
If `amount` is not set, the full amount of the transaction will be cleared. This
endpoint may be called multiple times against the same authorization to simulate
a multiple-completion scenario, with each call creating a separate clearing
event.

extra_headers: Send extra headers

Expand Down Expand Up @@ -1214,9 +1216,10 @@ async def simulate_clearing(
After this event, the
transaction transitions from `PENDING` to `SETTLED` status.

If `amount` is not set, the full amount of the transaction will be cleared.
Transactions that have already cleared, either partially or fully, cannot be
cleared again using this endpoint.
If `amount` is not set, the full amount of the transaction will be cleared. This
endpoint may be called multiple times against the same authorization to simulate
a multiple-completion scenario, with each call creating a separate clearing
event.

Args:
token: The transaction token returned from the /v1/simulate/authorize response.
Expand All @@ -1227,9 +1230,10 @@ async def simulate_clearing(
example, entering 100 in this field will result in a -100 amount in the
transaction, if the original authorization is a credit authorization.

If `amount` is not set, the full amount of the transaction will be cleared.
Transactions that have already cleared, either partially or fully, cannot be
cleared again using this endpoint.
If `amount` is not set, the full amount of the transaction will be cleared. This
endpoint may be called multiple times against the same authorization to simulate
a multiple-completion scenario, with each call creating a separate clearing
event.

extra_headers: Send extra headers

Expand Down
4 changes: 4 additions & 0 deletions src/lithic/types/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@
from .card_renewed_webhook_event import CardRenewedWebhookEvent as CardRenewedWebhookEvent
from .card_shipped_webhook_event import CardShippedWebhookEvent as CardShippedWebhookEvent
from .card_updated_webhook_event import CardUpdatedWebhookEvent as CardUpdatedWebhookEvent
from .embed_viewed_webhook_event import EmbedViewedWebhookEvent as EmbedViewedWebhookEvent
from .event_list_attempts_params import EventListAttemptsParams as EventListAttemptsParams
from .settlement_summary_details import SettlementSummaryDetails as SettlementSummaryDetails
from .transfer_limit_list_params import TransferLimitListParams as TransferLimitListParams
Expand Down Expand Up @@ -203,6 +204,9 @@
from .claim_document_uploaded_webhook_event import (
ClaimDocumentUploadedWebhookEvent as ClaimDocumentUploadedWebhookEvent,
)
from .embed_session_generated_webhook_event import (
EmbedSessionGeneratedWebhookEvent as EmbedSessionGeneratedWebhookEvent,
)
from .external_bank_account_create_response import (
ExternalBankAccountCreateResponse as ExternalBankAccountCreateResponse,
)
Expand Down
1 change: 1 addition & 0 deletions src/lithic/types/book_transfer_create_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ class BookTransferCreateParams(TypedDict, total=False):
"INTEREST",
"LATE_PAYMENT",
"BILL_PAYMENT",
"PAYMENT_FEE",
"CASH_BACK",
"ACCOUNT_TO_ACCOUNT",
"CARD_TO_CARD",
Expand Down
1 change: 1 addition & 0 deletions src/lithic/types/book_transfer_response.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ class Event(BaseModel):
"INTEREST",
"LATE_PAYMENT",
"BILL_PAYMENT",
"PAYMENT_FEE",
"CASH_BACK",
"ACCOUNT_TO_ACCOUNT",
"CARD_TO_CARD",
Expand Down
Loading