Skip to content

Commit 85d2d96

Browse files
docs(api): clarify simulate_clearing behavior in transactions
1 parent 8f7e822 commit 85d2d96

3 files changed

Lines changed: 22 additions & 17 deletions

File tree

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 213
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-9e397c65ffb81e2928b8ecf979769a79131ae6058b6fb373a5e930dc8a168732.yml
3-
openapi_spec_hash: 93aea3855d2d1c390107d223762aa818
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-1514911f233cb8bf0d6752c45bfa53a61b8f9b8ff215a4ea94a95f9505911000.yml
3+
openapi_spec_hash: 9820a9c9a4ff778c627041eb53fd4ee5
44
config_hash: 5bb913c05ebeb301ec925b16e75bb251

src/lithic/resources/transactions/transactions.py

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -470,9 +470,10 @@ def simulate_clearing(
470470
After this event, the
471471
transaction transitions from `PENDING` to `SETTLED` status.
472472
473-
If `amount` is not set, the full amount of the transaction will be cleared.
474-
Transactions that have already cleared, either partially or fully, cannot be
475-
cleared again using this endpoint.
473+
If `amount` is not set, the full amount of the transaction will be cleared. This
474+
endpoint may be called multiple times against the same authorization to simulate
475+
a multiple-completion scenario, with each call creating a separate clearing
476+
event.
476477
477478
Args:
478479
token: The transaction token returned from the /v1/simulate/authorize response.
@@ -483,9 +484,10 @@ def simulate_clearing(
483484
example, entering 100 in this field will result in a -100 amount in the
484485
transaction, if the original authorization is a credit authorization.
485486
486-
If `amount` is not set, the full amount of the transaction will be cleared.
487-
Transactions that have already cleared, either partially or fully, cannot be
488-
cleared again using this endpoint.
487+
If `amount` is not set, the full amount of the transaction will be cleared. This
488+
endpoint may be called multiple times against the same authorization to simulate
489+
a multiple-completion scenario, with each call creating a separate clearing
490+
event.
489491
490492
extra_headers: Send extra headers
491493
@@ -1214,9 +1216,10 @@ async def simulate_clearing(
12141216
After this event, the
12151217
transaction transitions from `PENDING` to `SETTLED` status.
12161218
1217-
If `amount` is not set, the full amount of the transaction will be cleared.
1218-
Transactions that have already cleared, either partially or fully, cannot be
1219-
cleared again using this endpoint.
1219+
If `amount` is not set, the full amount of the transaction will be cleared. This
1220+
endpoint may be called multiple times against the same authorization to simulate
1221+
a multiple-completion scenario, with each call creating a separate clearing
1222+
event.
12201223
12211224
Args:
12221225
token: The transaction token returned from the /v1/simulate/authorize response.
@@ -1227,9 +1230,10 @@ async def simulate_clearing(
12271230
example, entering 100 in this field will result in a -100 amount in the
12281231
transaction, if the original authorization is a credit authorization.
12291232
1230-
If `amount` is not set, the full amount of the transaction will be cleared.
1231-
Transactions that have already cleared, either partially or fully, cannot be
1232-
cleared again using this endpoint.
1233+
If `amount` is not set, the full amount of the transaction will be cleared. This
1234+
endpoint may be called multiple times against the same authorization to simulate
1235+
a multiple-completion scenario, with each call creating a separate clearing
1236+
event.
12331237
12341238
extra_headers: Send extra headers
12351239

src/lithic/types/transaction_simulate_clearing_params.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,8 @@ class TransactionSimulateClearingParams(TypedDict, total=False):
2020
will result in a -100 amount in the transaction, if the original authorization
2121
is a credit authorization.
2222
23-
If `amount` is not set, the full amount of the transaction will be cleared.
24-
Transactions that have already cleared, either partially or fully, cannot be
25-
cleared again using this endpoint.
23+
If `amount` is not set, the full amount of the transaction will be cleared. This
24+
endpoint may be called multiple times against the same authorization to simulate
25+
a multiple-completion scenario, with each call creating a separate clearing
26+
event.
2627
"""

0 commit comments

Comments
 (0)