Skip to content

Commit e7c375b

Browse files
feat(api): add WIRE_DRAWDOWN_REQUEST transfer type
docs(api): clarify description of token / retry_token when it serves as idempotency key feat(api): remove unnecessary X-Lithic-Pagination header
1 parent 538d96e commit e7c375b

File tree

7 files changed

+15
-24
lines changed

7 files changed

+15
-24
lines changed

.stats.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 176
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-1916ba0e95ce59f0feeebd6f3d2130990c812be7eabcda6e23c5fa096db912c7.yml
3-
openapi_spec_hash: b465e7cb5c2dee36b5bdc6d540b2a530
4-
config_hash: a8a802e2c916a5d36a025bf64ab55ee7
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic%2Flithic-854de7cc8f79e150ffe98f038ce9f39367010b2bdfffc9992be2738697dc4880.yml
3+
openapi_spec_hash: fd471b20f3eda1e00cdebf028cbfe867
4+
config_hash: 9dddee5f7af579864599849cb28a0770

README.md

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -156,23 +156,6 @@ while (page.hasNextPage()) {
156156
}
157157
```
158158

159-
## Default Headers
160-
161-
We automatically send the `X-Lithic-Pagination` header set to `cursor`.
162-
163-
If you need to, you can override it by setting default headers on a per-request basis.
164-
165-
```ts
166-
import Lithic from 'lithic';
167-
168-
const client = new Lithic();
169-
170-
const card = await client.cards.create(
171-
{ type: 'SINGLE_USE' },
172-
{ headers: { 'X-Lithic-Pagination': 'My-Custom-Value' } },
173-
);
174-
```
175-
176159
## Webhooks
177160

178161
Lithic uses webhooks to notify your application when events happen. The library provides signature verification via the `standardwebhooks` package.
@@ -231,7 +214,6 @@ export default async function POST(req: Request) {
231214
> [!NOTE]
232215
> If you're using the pages router, you will need [this trick](https://vancelucas.com/blog/how-to-access-raw-body-data-with-next-js/) to get the raw body.
233216
234-
235217
## Advanced Usage
236218

237219
### Accessing raw Response data (e.g., headers)

src/client.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1029,7 +1029,6 @@ export class Lithic {
10291029
'X-Stainless-Retry-Count': String(retryCount),
10301030
...(options.timeout ? { 'X-Stainless-Timeout': String(Math.trunc(options.timeout / 1000)) } : {}),
10311031
...getPlatformHeaders(),
1032-
'X-Lithic-Pagination': 'cursor',
10331032
},
10341033
await this.authHeaders(options),
10351034
this._options.defaultHeaders,

src/resources/book-transfers.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,8 @@ export interface BookTransferListParams extends CursorPageParams {
396396

397397
export interface BookTransferRetryParams {
398398
/**
399-
* Globally unique identifier for the retry.
399+
* Customer-provided token that will serve as an idempotency token. This token will
400+
* become the transaction token.
400401
*/
401402
retry_token: string;
402403
}

src/resources/external-payments.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,10 @@ export interface ExternalPaymentCreateParams {
211211

212212
payment_type: 'DEPOSIT' | 'WITHDRAWAL';
213213

214+
/**
215+
* Customer-provided token that will serve as an idempotency token. This token will
216+
* become the transaction token.
217+
*/
214218
token?: string;
215219

216220
memo?: string;

src/resources/management-operations.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,10 @@ export interface ManagementOperationCreateParams {
237237

238238
financial_account_token: string;
239239

240+
/**
241+
* Customer-provided token that will serve as an idempotency token. This token will
242+
* become the transaction token.
243+
*/
240244
token?: string;
241245

242246
memo?: string;

src/resources/payments.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,8 @@ export interface Payment {
317317
| 'WIRE_INBOUND_PAYMENT'
318318
| 'WIRE_INBOUND_ADMIN'
319319
| 'WIRE_OUTBOUND_PAYMENT'
320-
| 'WIRE_OUTBOUND_ADMIN';
320+
| 'WIRE_OUTBOUND_ADMIN'
321+
| 'WIRE_DRAWDOWN_REQUEST';
321322

322323
/**
323324
* User-defined identifier

0 commit comments

Comments
 (0)