increase 0.184.0 → 0.186.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/core.js +2 -1
  3. package/core.js.map +1 -1
  4. package/core.mjs +2 -1
  5. package/core.mjs.map +1 -1
  6. package/index.d.mts +0 -3
  7. package/index.d.ts +0 -3
  8. package/index.d.ts.map +1 -1
  9. package/index.js +0 -4
  10. package/index.js.map +1 -1
  11. package/index.mjs +0 -4
  12. package/index.mjs.map +1 -1
  13. package/package.json +1 -1
  14. package/pagination.js +1 -1
  15. package/pagination.js.map +1 -1
  16. package/pagination.mjs +1 -1
  17. package/pagination.mjs.map +1 -1
  18. package/resources/check-transfers.d.ts +6 -0
  19. package/resources/check-transfers.d.ts.map +1 -1
  20. package/resources/check-transfers.js.map +1 -1
  21. package/resources/check-transfers.mjs.map +1 -1
  22. package/resources/index.d.ts +0 -1
  23. package/resources/index.d.ts.map +1 -1
  24. package/resources/index.js +2 -5
  25. package/resources/index.js.map +1 -1
  26. package/resources/index.mjs +0 -1
  27. package/resources/index.mjs.map +1 -1
  28. package/src/core.ts +2 -2
  29. package/src/index.ts +0 -19
  30. package/src/pagination.ts +1 -1
  31. package/src/resources/check-transfers.ts +7 -0
  32. package/src/resources/index.ts +0 -7
  33. package/src/version.ts +1 -1
  34. package/version.d.ts +1 -1
  35. package/version.js +1 -1
  36. package/version.mjs +1 -1
  37. package/resources/real-time-payments-request-for-payments.d.ts +0 -353
  38. package/resources/real-time-payments-request-for-payments.d.ts.map +0 -1
  39. package/resources/real-time-payments-request-for-payments.js +0 -34
  40. package/resources/real-time-payments-request-for-payments.js.map +0 -1
  41. package/resources/real-time-payments-request-for-payments.mjs +0 -29
  42. package/resources/real-time-payments-request-for-payments.mjs.map +0 -1
  43. package/src/resources/real-time-payments-request-for-payments.ts +0 -469
@@ -1,469 +0,0 @@
1
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- import { APIResource } from '../resource';
4
- import { isRequestOptions } from '../core';
5
- import * as Core from '../core';
6
- import { Page, type PageParams } from '../pagination';
7
-
8
- export class RealTimePaymentsRequestForPayments extends APIResource {
9
- /**
10
- * Create a Real-Time Payments Request for Payment
11
- */
12
- create(
13
- body: RealTimePaymentsRequestForPaymentCreateParams,
14
- options?: Core.RequestOptions,
15
- ): Core.APIPromise<RealTimePaymentsRequestForPayment> {
16
- return this._client.post('/real_time_payments_request_for_payments', { body, ...options });
17
- }
18
-
19
- /**
20
- * Retrieve a Real-Time Payments Request for Payment
21
- */
22
- retrieve(
23
- requestForPaymentId: string,
24
- options?: Core.RequestOptions,
25
- ): Core.APIPromise<RealTimePaymentsRequestForPayment> {
26
- return this._client.get(`/real_time_payments_request_for_payments/${requestForPaymentId}`, options);
27
- }
28
-
29
- /**
30
- * List Real-Time Payments Request for Payments
31
- */
32
- list(
33
- query?: RealTimePaymentsRequestForPaymentListParams,
34
- options?: Core.RequestOptions,
35
- ): Core.PagePromise<RealTimePaymentsRequestForPaymentsPage, RealTimePaymentsRequestForPayment>;
36
- list(
37
- options?: Core.RequestOptions,
38
- ): Core.PagePromise<RealTimePaymentsRequestForPaymentsPage, RealTimePaymentsRequestForPayment>;
39
- list(
40
- query: RealTimePaymentsRequestForPaymentListParams | Core.RequestOptions = {},
41
- options?: Core.RequestOptions,
42
- ): Core.PagePromise<RealTimePaymentsRequestForPaymentsPage, RealTimePaymentsRequestForPayment> {
43
- if (isRequestOptions(query)) {
44
- return this.list({}, query);
45
- }
46
- return this._client.getAPIList(
47
- '/real_time_payments_request_for_payments',
48
- RealTimePaymentsRequestForPaymentsPage,
49
- { query, ...options },
50
- );
51
- }
52
- }
53
-
54
- export class RealTimePaymentsRequestForPaymentsPage extends Page<RealTimePaymentsRequestForPayment> {}
55
-
56
- /**
57
- * Real-Time Payments transfers move funds, within seconds, between your Increase
58
- * account and any other account on the Real-Time Payments network. A request for
59
- * payment is a request to the receiver to send funds to your account. The
60
- * permitted uses of Requests For Payment are limited by the Real-Time Payments
61
- * network to business-to-business payments and transfers between two accounts at
62
- * different banks owned by the same individual. Please contact
63
- * [support@increase.com](mailto:support@increase.com) to enable this API for your
64
- * team.
65
- */
66
- export interface RealTimePaymentsRequestForPayment {
67
- /**
68
- * The Real-Time Payments Request for Payment's identifier.
69
- */
70
- id: string;
71
-
72
- /**
73
- * The transfer amount in USD cents.
74
- */
75
- amount: number;
76
-
77
- /**
78
- * The [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date and time at which
79
- * the request for payment was created.
80
- */
81
- created_at: string;
82
-
83
- /**
84
- * The [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) code for the transfer's
85
- * currency. For real-time payments transfers this is always equal to `USD`.
86
- *
87
- * - `CAD` - Canadian Dollar (CAD)
88
- * - `CHF` - Swiss Franc (CHF)
89
- * - `EUR` - Euro (EUR)
90
- * - `GBP` - British Pound (GBP)
91
- * - `JPY` - Japanese Yen (JPY)
92
- * - `USD` - US Dollar (USD)
93
- */
94
- currency: 'CAD' | 'CHF' | 'EUR' | 'GBP' | 'JPY' | 'USD';
95
-
96
- /**
97
- * The name of the recipient the sender is requesting a transfer from.
98
- */
99
- debtor_name: string;
100
-
101
- /**
102
- * The Account Number in which a successful transfer will arrive.
103
- */
104
- destination_account_number_id: string;
105
-
106
- /**
107
- * The expiration time for this request, in UTC. The requestee will not be able to
108
- * pay after this date.
109
- */
110
- expires_at: string;
111
-
112
- /**
113
- * The transaction that fulfilled this request.
114
- */
115
- fulfillment_transaction_id: string | null;
116
-
117
- /**
118
- * The idempotency key you chose for this object. This value is unique across
119
- * Increase and is used to ensure that a request is only processed once. Learn more
120
- * about [idempotency](https://increase.com/documentation/idempotency-keys).
121
- */
122
- idempotency_key: string | null;
123
-
124
- /**
125
- * If the request for payment is refused by the destination financial institution
126
- * or the receiving customer, this will contain supplemental details.
127
- */
128
- refusal: RealTimePaymentsRequestForPayment.Refusal | null;
129
-
130
- /**
131
- * If the request for payment is rejected by Real-Time Payments or the destination
132
- * financial institution, this will contain supplemental details.
133
- */
134
- rejection: RealTimePaymentsRequestForPayment.Rejection | null;
135
-
136
- /**
137
- * Unstructured information that will show on the recipient's bank statement.
138
- */
139
- remittance_information: string;
140
-
141
- /**
142
- * The account number the request is sent to.
143
- */
144
- source_account_number: string;
145
-
146
- /**
147
- * The receiver's American Bankers' Association (ABA) Routing Transit Number (RTN).
148
- */
149
- source_routing_number: string;
150
-
151
- /**
152
- * The lifecycle status of the request for payment.
153
- *
154
- * - `pending_submission` - The request for payment is queued to be submitted to
155
- * Real-Time Payments.
156
- * - `pending_response` - The request for payment has been submitted and is pending
157
- * a response from Real-Time Payments.
158
- * - `rejected` - The request for payment was rejected by the network or the
159
- * recipient.
160
- * - `accepted` - The request for payment was accepted by the recipient but has not
161
- * yet been paid.
162
- * - `refused` - The request for payment was refused by the recipient.
163
- * - `fulfilled` - The request for payment was fulfilled by the receiver.
164
- */
165
- status: 'pending_submission' | 'pending_response' | 'rejected' | 'accepted' | 'refused' | 'fulfilled';
166
-
167
- /**
168
- * After the request for payment is submitted to Real-Time Payments, this will
169
- * contain supplemental details.
170
- */
171
- submission: RealTimePaymentsRequestForPayment.Submission | null;
172
-
173
- /**
174
- * A constant representing the object's type. For this resource it will always be
175
- * `real_time_payments_request_for_payment`.
176
- */
177
- type: 'real_time_payments_request_for_payment';
178
- }
179
-
180
- export namespace RealTimePaymentsRequestForPayment {
181
- /**
182
- * If the request for payment is refused by the destination financial institution
183
- * or the receiving customer, this will contain supplemental details.
184
- */
185
- export interface Refusal {
186
- /**
187
- * The reason the request for payment was refused as provided by the recipient bank
188
- * or the customer.
189
- *
190
- * - `account_blocked` - The destination account is currently blocked from
191
- * receiving transactions. Corresponds to the Real-Time Payments reason code
192
- * `AC06`.
193
- * - `transaction_forbidden` - Real-Time Payments transfers are not allowed to the
194
- * destination account. Corresponds to the Real-Time Payments reason code `AG01`.
195
- * - `transaction_type_not_supported` - Real-Time Payments transfers are not
196
- * enabled for the destination account. Corresponds to the Real-Time Payments
197
- * reason code `AG03`.
198
- * - `unexpected_amount` - The amount of the transfer is different than expected by
199
- * the recipient. Corresponds to the Real-Time Payments reason code `AM09`.
200
- * - `amount_exceeds_bank_limits` - The amount is higher than the recipient is
201
- * authorized to send or receive. Corresponds to the Real-Time Payments reason
202
- * code `AM14`.
203
- * - `invalid_debtor_address` - The debtor's address is required, but missing or
204
- * invalid. Corresponds to the Real-Time Payments reason code `BE07`.
205
- * - `invalid_creditor_address` - The creditor's address is required, but missing
206
- * or invalid. Corresponds to the Real-Time Payments reason code `BE04`.
207
- * - `creditor_identifier_incorrect` - Creditor identifier incorrect. Corresponds
208
- * to the Real-Time Payments reason code `CH11`.
209
- * - `requested_by_customer` - The customer refused the request. Corresponds to the
210
- * Real-Time Payments reason code `CUST`.
211
- * - `order_rejected` - The order was rejected. Corresponds to the Real-Time
212
- * Payments reason code `DS04`.
213
- * - `end_customer_deceased` - The destination account holder is deceased.
214
- * Corresponds to the Real-Time Payments reason code `MD07`.
215
- * - `customer_has_opted_out` - The customer has opted out of receiving requests
216
- * for payments from this creditor. Corresponds to the Real-Time Payments reason
217
- * code `SL12`.
218
- * - `other` - Some other error or issue has occurred.
219
- */
220
- refusal_reason_code:
221
- | 'account_blocked'
222
- | 'transaction_forbidden'
223
- | 'transaction_type_not_supported'
224
- | 'unexpected_amount'
225
- | 'amount_exceeds_bank_limits'
226
- | 'invalid_debtor_address'
227
- | 'invalid_creditor_address'
228
- | 'creditor_identifier_incorrect'
229
- | 'requested_by_customer'
230
- | 'order_rejected'
231
- | 'end_customer_deceased'
232
- | 'customer_has_opted_out'
233
- | 'other';
234
- }
235
-
236
- /**
237
- * If the request for payment is rejected by Real-Time Payments or the destination
238
- * financial institution, this will contain supplemental details.
239
- */
240
- export interface Rejection {
241
- /**
242
- * The reason the request for payment was rejected as provided by the recipient
243
- * bank or the Real-Time Payments network.
244
- *
245
- * - `account_closed` - The destination account is closed. Corresponds to the
246
- * Real-Time Payments reason code `AC04`.
247
- * - `account_blocked` - The destination account is currently blocked from
248
- * receiving transactions. Corresponds to the Real-Time Payments reason code
249
- * `AC06`.
250
- * - `invalid_creditor_account_type` - The destination account is ineligible to
251
- * receive Real-Time Payments transfers. Corresponds to the Real-Time Payments
252
- * reason code `AC14`.
253
- * - `invalid_creditor_account_number` - The destination account does not exist.
254
- * Corresponds to the Real-Time Payments reason code `AC03`.
255
- * - `invalid_creditor_financial_institution_identifier` - The destination routing
256
- * number is invalid. Corresponds to the Real-Time Payments reason code `RC04`.
257
- * - `end_customer_deceased` - The destination account holder is deceased.
258
- * Corresponds to the Real-Time Payments reason code `MD07`.
259
- * - `narrative` - The reason is provided as narrative information in the
260
- * additional information field.
261
- * - `transaction_forbidden` - Real-Time Payments transfers are not allowed to the
262
- * destination account. Corresponds to the Real-Time Payments reason code `AG01`.
263
- * - `transaction_type_not_supported` - Real-Time Payments transfers are not
264
- * enabled for the destination account. Corresponds to the Real-Time Payments
265
- * reason code `AG03`.
266
- * - `unexpected_amount` - The amount of the transfer is different than expected by
267
- * the recipient. Corresponds to the Real-Time Payments reason code `AM09`.
268
- * - `amount_exceeds_bank_limits` - The amount is higher than the recipient is
269
- * authorized to send or receive. Corresponds to the Real-Time Payments reason
270
- * code `AM14`.
271
- * - `invalid_creditor_address` - The creditor's address is required, but missing
272
- * or invalid. Corresponds to the Real-Time Payments reason code `BE04`.
273
- * - `unknown_end_customer` - The specified creditor is unknown. Corresponds to the
274
- * Real-Time Payments reason code `BE06`.
275
- * - `invalid_debtor_address` - The debtor's address is required, but missing or
276
- * invalid. Corresponds to the Real-Time Payments reason code `BE07`.
277
- * - `timeout` - There was a timeout processing the transfer. Corresponds to the
278
- * Real-Time Payments reason code `DS24`.
279
- * - `unsupported_message_for_recipient` - Real-Time Payments transfers are not
280
- * enabled for the destination account. Corresponds to the Real-Time Payments
281
- * reason code `NOAT`.
282
- * - `recipient_connection_not_available` - The destination financial institution
283
- * is currently not connected to Real-Time Payments. Corresponds to the Real-Time
284
- * Payments reason code `9912`.
285
- * - `real_time_payments_suspended` - Real-Time Payments is currently unavailable.
286
- * Corresponds to the Real-Time Payments reason code `9948`.
287
- * - `instructed_agent_signed_off` - The destination financial institution is
288
- * currently signed off of Real-Time Payments. Corresponds to the Real-Time
289
- * Payments reason code `9910`.
290
- * - `processing_error` - The transfer was rejected due to an internal Increase
291
- * issue. We have been notified.
292
- * - `other` - Some other error or issue has occurred.
293
- */
294
- reject_reason_code:
295
- | 'account_closed'
296
- | 'account_blocked'
297
- | 'invalid_creditor_account_type'
298
- | 'invalid_creditor_account_number'
299
- | 'invalid_creditor_financial_institution_identifier'
300
- | 'end_customer_deceased'
301
- | 'narrative'
302
- | 'transaction_forbidden'
303
- | 'transaction_type_not_supported'
304
- | 'unexpected_amount'
305
- | 'amount_exceeds_bank_limits'
306
- | 'invalid_creditor_address'
307
- | 'unknown_end_customer'
308
- | 'invalid_debtor_address'
309
- | 'timeout'
310
- | 'unsupported_message_for_recipient'
311
- | 'recipient_connection_not_available'
312
- | 'real_time_payments_suspended'
313
- | 'instructed_agent_signed_off'
314
- | 'processing_error'
315
- | 'other';
316
- }
317
-
318
- /**
319
- * After the request for payment is submitted to Real-Time Payments, this will
320
- * contain supplemental details.
321
- */
322
- export interface Submission {
323
- /**
324
- * The Real-Time Payments payment information identification of the request.
325
- */
326
- payment_information_identification: string;
327
- }
328
- }
329
-
330
- export interface RealTimePaymentsRequestForPaymentCreateParams {
331
- /**
332
- * The requested amount in USD cents. Must be positive.
333
- */
334
- amount: number;
335
-
336
- /**
337
- * Details of the person being requested to pay.
338
- */
339
- debtor: RealTimePaymentsRequestForPaymentCreateParams.Debtor;
340
-
341
- /**
342
- * The identifier of the Account Number where the funds will land.
343
- */
344
- destination_account_number_id: string;
345
-
346
- /**
347
- * The expiration time for this request, in UTC. The requestee will not be able to
348
- * pay after this date.
349
- */
350
- expires_at: string;
351
-
352
- /**
353
- * Unstructured information that will show on the requestee's bank statement.
354
- */
355
- remittance_information: string;
356
-
357
- /**
358
- * The account number the funds will be requested from.
359
- */
360
- source_account_number: string;
361
-
362
- /**
363
- * The requestee's American Bankers' Association (ABA) Routing Transit Number
364
- * (RTN).
365
- */
366
- source_routing_number: string;
367
- }
368
-
369
- export namespace RealTimePaymentsRequestForPaymentCreateParams {
370
- /**
371
- * Details of the person being requested to pay.
372
- */
373
- export interface Debtor {
374
- /**
375
- * Address of the debtor.
376
- */
377
- address: Debtor.Address;
378
-
379
- /**
380
- * The name of the debtor.
381
- */
382
- name: string;
383
- }
384
-
385
- export namespace Debtor {
386
- /**
387
- * Address of the debtor.
388
- */
389
- export interface Address {
390
- /**
391
- * The ISO 3166, Alpha-2 country code.
392
- */
393
- country: string;
394
-
395
- /**
396
- * The town or city.
397
- */
398
- city?: string;
399
-
400
- /**
401
- * The postal code or zip.
402
- */
403
- post_code?: string;
404
-
405
- /**
406
- * The street name without the street number.
407
- */
408
- street_name?: string;
409
- }
410
- }
411
- }
412
-
413
- export interface RealTimePaymentsRequestForPaymentListParams extends PageParams {
414
- /**
415
- * Filter Real-Time Payments Request for Payments to those destined to the
416
- * specified Account.
417
- */
418
- account_id?: string;
419
-
420
- created_at?: RealTimePaymentsRequestForPaymentListParams.CreatedAt;
421
-
422
- /**
423
- * Filter records to the one with the specified `idempotency_key` you chose for
424
- * that object. This value is unique across Increase and is used to ensure that a
425
- * request is only processed once. Learn more about
426
- * [idempotency](https://increase.com/documentation/idempotency-keys).
427
- */
428
- idempotency_key?: string;
429
- }
430
-
431
- export namespace RealTimePaymentsRequestForPaymentListParams {
432
- export interface CreatedAt {
433
- /**
434
- * Return results after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
435
- * timestamp.
436
- */
437
- after?: string;
438
-
439
- /**
440
- * Return results before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601)
441
- * timestamp.
442
- */
443
- before?: string;
444
-
445
- /**
446
- * Return results on or after this
447
- * [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
448
- */
449
- on_or_after?: string;
450
-
451
- /**
452
- * Return results on or before this
453
- * [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) timestamp.
454
- */
455
- on_or_before?: string;
456
- }
457
- }
458
-
459
- RealTimePaymentsRequestForPayments.RealTimePaymentsRequestForPaymentsPage =
460
- RealTimePaymentsRequestForPaymentsPage;
461
-
462
- export declare namespace RealTimePaymentsRequestForPayments {
463
- export {
464
- type RealTimePaymentsRequestForPayment as RealTimePaymentsRequestForPayment,
465
- RealTimePaymentsRequestForPaymentsPage as RealTimePaymentsRequestForPaymentsPage,
466
- type RealTimePaymentsRequestForPaymentCreateParams as RealTimePaymentsRequestForPaymentCreateParams,
467
- type RealTimePaymentsRequestForPaymentListParams as RealTimePaymentsRequestForPaymentListParams,
468
- };
469
- }