stripe 9.0.0 → 9.3.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.
- package/CHANGELOG.md +35 -0
- package/VERSION +1 -1
- package/lib/resources/Apps/Secrets.js +31 -0
- package/lib/resources/Customers.js +5 -0
- package/lib/resources/FinancialConnections/Accounts.js +12 -0
- package/lib/resources/TestHelpers/Treasury/InboundTransfers.js +25 -0
- package/lib/resources/TestHelpers/Treasury/OutboundPayments.js +25 -0
- package/lib/resources/TestHelpers/Treasury/OutboundTransfers.js +25 -0
- package/lib/resources/TestHelpers/Treasury/ReceivedCredits.js +15 -0
- package/lib/resources/TestHelpers/Treasury/ReceivedDebits.js +15 -0
- package/lib/resources/Treasury/CreditReversals.js +26 -0
- package/lib/resources/Treasury/DebitReversals.js +26 -0
- package/lib/resources/Treasury/FinancialAccounts.js +41 -0
- package/lib/resources/Treasury/InboundTransfers.js +31 -0
- package/lib/resources/Treasury/OutboundPayments.js +31 -0
- package/lib/resources/Treasury/OutboundTransfers.js +31 -0
- package/lib/resources/Treasury/ReceivedCredits.js +21 -0
- package/lib/resources/Treasury/ReceivedDebits.js +21 -0
- package/lib/resources/Treasury/TransactionEntries.js +21 -0
- package/lib/resources/Treasury/Transactions.js +21 -0
- package/lib/resources.js +22 -0
- package/package.json +1 -1
- package/types/2020-08-27/Accounts.d.ts +5 -5
- package/types/2020-08-27/Apps/Secrets.d.ts +241 -0
- package/types/2020-08-27/BillingPortal/Configurations.d.ts +1 -1
- package/types/2020-08-27/BillingPortal/Sessions.d.ts +1 -1
- package/types/2020-08-27/Charges.d.ts +8 -0
- package/types/2020-08-27/Checkout/Sessions.d.ts +51 -3
- package/types/2020-08-27/Customers.d.ts +24 -0
- package/types/2020-08-27/Discounts.d.ts +4 -4
- package/types/2020-08-27/FinancialConnections/Accounts.d.ts +63 -0
- package/types/2020-08-27/Invoices.d.ts +3 -0
- package/types/2020-08-27/Issuing/Authorizations.d.ts +22 -0
- package/types/2020-08-27/Issuing/Cards.d.ts +7 -0
- package/types/2020-08-27/Issuing/Disputes.d.ts +29 -0
- package/types/2020-08-27/Issuing/Transactions.d.ts +17 -0
- package/types/2020-08-27/LineItems.d.ts +2 -3
- package/types/2020-08-27/Mandates.d.ts +4 -0
- package/types/2020-08-27/Orders.d.ts +84 -4
- package/types/2020-08-27/PaymentIntents.d.ts +332 -2
- package/types/2020-08-27/PaymentLinks.d.ts +167 -0
- package/types/2020-08-27/PaymentMethods.d.ts +73 -0
- package/types/2020-08-27/PromotionCodes.d.ts +2 -2
- package/types/2020-08-27/Quotes.d.ts +6 -9
- package/types/2020-08-27/Refunds.d.ts +1 -1
- package/types/2020-08-27/SetupAttempts.d.ts +4 -0
- package/types/2020-08-27/SetupIntents.d.ts +157 -0
- package/types/2020-08-27/SubscriptionSchedules.d.ts +15 -0
- package/types/2020-08-27/Subscriptions.d.ts +41 -2
- package/types/2020-08-27/Terminal/Configurations.d.ts +63 -0
- package/types/2020-08-27/TestHelpers/Treasury/InboundTransfers.d.ts +108 -0
- package/types/2020-08-27/TestHelpers/Treasury/OutboundPayments.d.ts +105 -0
- package/types/2020-08-27/TestHelpers/Treasury/OutboundTransfers.d.ts +105 -0
- package/types/2020-08-27/TestHelpers/Treasury/ReceivedCredits.d.ts +93 -0
- package/types/2020-08-27/TestHelpers/Treasury/ReceivedDebits.d.ts +91 -0
- package/types/2020-08-27/Tokens.d.ts +2 -2
- package/types/2020-08-27/Treasury/CreditReversals.d.ts +168 -0
- package/types/2020-08-27/Treasury/DebitReversals.d.ts +187 -0
- package/types/2020-08-27/Treasury/FinancialAccountFeatures.d.ts +622 -0
- package/types/2020-08-27/Treasury/FinancialAccounts.d.ts +833 -0
- package/types/2020-08-27/Treasury/InboundTransfers.d.ts +349 -0
- package/types/2020-08-27/Treasury/OutboundPayments.d.ts +550 -0
- package/types/2020-08-27/Treasury/OutboundTransfers.d.ts +385 -0
- package/types/2020-08-27/Treasury/ReceivedCredits.d.ts +303 -0
- package/types/2020-08-27/Treasury/ReceivedDebits.d.ts +231 -0
- package/types/2020-08-27/Treasury/TransactionEntries.d.ts +257 -0
- package/types/2020-08-27/Treasury/Transactions.d.ts +268 -0
- package/types/2020-08-27/WebhookEndpoints.d.ts +62 -2
- package/types/2020-08-27/index.d.ts +39 -0
|
@@ -0,0 +1,833 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec
|
|
2
|
+
|
|
3
|
+
declare module 'stripe' {
|
|
4
|
+
namespace Stripe {
|
|
5
|
+
namespace Treasury {
|
|
6
|
+
/**
|
|
7
|
+
* The FinancialAccount object.
|
|
8
|
+
*/
|
|
9
|
+
interface FinancialAccount {
|
|
10
|
+
/**
|
|
11
|
+
* Unique identifier for the object.
|
|
12
|
+
*/
|
|
13
|
+
id: string;
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* String representing the object's type. Objects of the same type share the same value.
|
|
17
|
+
*/
|
|
18
|
+
object: 'treasury.financial_account';
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* The array of paths to active Features in the Features hash.
|
|
22
|
+
*/
|
|
23
|
+
active_features: Array<FinancialAccount.ActiveFeature>;
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Balance information for the FinancialAccount
|
|
27
|
+
*/
|
|
28
|
+
balance: FinancialAccount.Balance;
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Two-letter country code ([ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)).
|
|
32
|
+
*/
|
|
33
|
+
country: string;
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Time at which the object was created. Measured in seconds since the Unix epoch.
|
|
37
|
+
*/
|
|
38
|
+
created: number;
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Encodes whether a FinancialAccount has access to a particular Feature, with a `status` enum and associated `status_details`.
|
|
42
|
+
* Stripe or the platform can control Features via the requested field.
|
|
43
|
+
*/
|
|
44
|
+
features?: Stripe.Treasury.FinancialAccountFeatures;
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* The set of credentials that resolve to a FinancialAccount.
|
|
48
|
+
*/
|
|
49
|
+
financial_addresses: Array<FinancialAccount.FinancialAddress>;
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
|
|
53
|
+
*/
|
|
54
|
+
livemode: boolean;
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
|
|
58
|
+
*/
|
|
59
|
+
metadata: Stripe.Metadata | null;
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* The array of paths to pending Features in the Features hash.
|
|
63
|
+
*/
|
|
64
|
+
pending_features: Array<FinancialAccount.PendingFeature>;
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* The set of functionalities that the platform can restrict on the FinancialAccount.
|
|
68
|
+
*/
|
|
69
|
+
platform_restrictions: FinancialAccount.PlatformRestrictions | null;
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* The array of paths to restricted Features in the Features hash.
|
|
73
|
+
*/
|
|
74
|
+
restricted_features: Array<FinancialAccount.RestrictedFeature>;
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* The enum specifying what state the account is in.
|
|
78
|
+
*/
|
|
79
|
+
status: FinancialAccount.Status;
|
|
80
|
+
|
|
81
|
+
status_details: FinancialAccount.StatusDetails;
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* The currencies the FinancialAccount can hold a balance in. Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase.
|
|
85
|
+
*/
|
|
86
|
+
supported_currencies: Array<string>;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
namespace FinancialAccount {
|
|
90
|
+
type ActiveFeature =
|
|
91
|
+
| 'card_issuing'
|
|
92
|
+
| 'deposit_insurance'
|
|
93
|
+
| 'financial_addresses.aba'
|
|
94
|
+
| 'inbound_transfers.ach'
|
|
95
|
+
| 'intra_stripe_flows'
|
|
96
|
+
| 'outbound_payments.ach'
|
|
97
|
+
| 'outbound_payments.us_domestic_wire'
|
|
98
|
+
| 'outbound_transfers.ach'
|
|
99
|
+
| 'outbound_transfers.us_domestic_wire'
|
|
100
|
+
| 'remote_deposit_capture';
|
|
101
|
+
|
|
102
|
+
interface Balance {
|
|
103
|
+
/**
|
|
104
|
+
* Funds the user can spend right now.
|
|
105
|
+
*/
|
|
106
|
+
cash: {
|
|
107
|
+
[key: string]: number;
|
|
108
|
+
};
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* Funds not spendable yet, but will become available at a later time.
|
|
112
|
+
*/
|
|
113
|
+
inbound_pending: {
|
|
114
|
+
[key: string]: number;
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Funds in the account, but not spendable because they are being held for pending outbound flows.
|
|
119
|
+
*/
|
|
120
|
+
outbound_pending: {
|
|
121
|
+
[key: string]: number;
|
|
122
|
+
};
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
interface FinancialAddress {
|
|
126
|
+
/**
|
|
127
|
+
* ABA Records contain U.S. bank account details per the ABA format.
|
|
128
|
+
*/
|
|
129
|
+
aba?: FinancialAddress.Aba;
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* The list of networks that the address supports
|
|
133
|
+
*/
|
|
134
|
+
supported_networks?: Array<FinancialAddress.SupportedNetwork>;
|
|
135
|
+
|
|
136
|
+
/**
|
|
137
|
+
* The type of financial address
|
|
138
|
+
*/
|
|
139
|
+
type: 'aba';
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
namespace FinancialAddress {
|
|
143
|
+
interface Aba {
|
|
144
|
+
/**
|
|
145
|
+
* The name of the person or business that owns the bank account.
|
|
146
|
+
*/
|
|
147
|
+
account_holder_name: string;
|
|
148
|
+
|
|
149
|
+
/**
|
|
150
|
+
* The account number.
|
|
151
|
+
*/
|
|
152
|
+
account_number: string | null;
|
|
153
|
+
|
|
154
|
+
/**
|
|
155
|
+
* The last four characters of the account number.
|
|
156
|
+
*/
|
|
157
|
+
account_number_last4: string;
|
|
158
|
+
|
|
159
|
+
/**
|
|
160
|
+
* Name of the bank.
|
|
161
|
+
*/
|
|
162
|
+
bank_name: string;
|
|
163
|
+
|
|
164
|
+
/**
|
|
165
|
+
* Routing number for the account.
|
|
166
|
+
*/
|
|
167
|
+
routing_number: string;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
type SupportedNetwork = 'ach' | 'us_domestic_wire';
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
type PendingFeature =
|
|
174
|
+
| 'card_issuing'
|
|
175
|
+
| 'deposit_insurance'
|
|
176
|
+
| 'financial_addresses.aba'
|
|
177
|
+
| 'inbound_transfers.ach'
|
|
178
|
+
| 'intra_stripe_flows'
|
|
179
|
+
| 'outbound_payments.ach'
|
|
180
|
+
| 'outbound_payments.us_domestic_wire'
|
|
181
|
+
| 'outbound_transfers.ach'
|
|
182
|
+
| 'outbound_transfers.us_domestic_wire'
|
|
183
|
+
| 'remote_deposit_capture';
|
|
184
|
+
|
|
185
|
+
interface PlatformRestrictions {
|
|
186
|
+
/**
|
|
187
|
+
* Restricts all inbound money movement.
|
|
188
|
+
*/
|
|
189
|
+
inbound_flows: PlatformRestrictions.InboundFlows | null;
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* Restricts all outbound money movement.
|
|
193
|
+
*/
|
|
194
|
+
outbound_flows: PlatformRestrictions.OutboundFlows | null;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
namespace PlatformRestrictions {
|
|
198
|
+
type InboundFlows = 'restricted' | 'unrestricted';
|
|
199
|
+
|
|
200
|
+
type OutboundFlows = 'restricted' | 'unrestricted';
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
type RestrictedFeature =
|
|
204
|
+
| 'card_issuing'
|
|
205
|
+
| 'deposit_insurance'
|
|
206
|
+
| 'financial_addresses.aba'
|
|
207
|
+
| 'inbound_transfers.ach'
|
|
208
|
+
| 'intra_stripe_flows'
|
|
209
|
+
| 'outbound_payments.ach'
|
|
210
|
+
| 'outbound_payments.us_domestic_wire'
|
|
211
|
+
| 'outbound_transfers.ach'
|
|
212
|
+
| 'outbound_transfers.us_domestic_wire'
|
|
213
|
+
| 'remote_deposit_capture';
|
|
214
|
+
|
|
215
|
+
type Status = 'closed' | 'open';
|
|
216
|
+
|
|
217
|
+
interface StatusDetails {
|
|
218
|
+
/**
|
|
219
|
+
* Details related to the closure of this FinancialAccount
|
|
220
|
+
*/
|
|
221
|
+
closed: StatusDetails.Closed | null;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
namespace StatusDetails {
|
|
225
|
+
interface Closed {
|
|
226
|
+
/**
|
|
227
|
+
* The array that contains reasons for a FinancialAccount closure.
|
|
228
|
+
*/
|
|
229
|
+
reasons: Array<Closed.Reason>;
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
namespace Closed {
|
|
233
|
+
type Reason = 'account_rejected' | 'closed_by_platform' | 'other';
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
interface FinancialAccountCreateParams {
|
|
239
|
+
/**
|
|
240
|
+
* The currencies the FinancialAccount can hold a balance in.
|
|
241
|
+
*/
|
|
242
|
+
supported_currencies: Array<string>;
|
|
243
|
+
|
|
244
|
+
/**
|
|
245
|
+
* Specifies which fields in the response should be expanded.
|
|
246
|
+
*/
|
|
247
|
+
expand?: Array<string>;
|
|
248
|
+
|
|
249
|
+
/**
|
|
250
|
+
* Encodes whether a FinancialAccount has access to a particular feature. Stripe or the platform can control features via the requested field.
|
|
251
|
+
*/
|
|
252
|
+
features?: FinancialAccountCreateParams.Features;
|
|
253
|
+
|
|
254
|
+
/**
|
|
255
|
+
* Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
|
|
256
|
+
*/
|
|
257
|
+
metadata?: Stripe.MetadataParam;
|
|
258
|
+
|
|
259
|
+
/**
|
|
260
|
+
* The set of functionalities that the platform can restrict on the FinancialAccount.
|
|
261
|
+
*/
|
|
262
|
+
platform_restrictions?: FinancialAccountCreateParams.PlatformRestrictions;
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
namespace FinancialAccountCreateParams {
|
|
266
|
+
interface Features {
|
|
267
|
+
/**
|
|
268
|
+
* Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
|
|
269
|
+
*/
|
|
270
|
+
deposit_insurance?: Features.DepositInsurance;
|
|
271
|
+
|
|
272
|
+
/**
|
|
273
|
+
* Contains Features that add FinancialAddresses to the FinancialAccount.
|
|
274
|
+
*/
|
|
275
|
+
financial_addresses?: Features.FinancialAddresses;
|
|
276
|
+
|
|
277
|
+
/**
|
|
278
|
+
* Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
|
|
279
|
+
*/
|
|
280
|
+
inbound_transfers?: Features.InboundTransfers;
|
|
281
|
+
|
|
282
|
+
/**
|
|
283
|
+
* Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
|
|
284
|
+
*/
|
|
285
|
+
intra_stripe_flows?: Features.IntraStripeFlows;
|
|
286
|
+
|
|
287
|
+
/**
|
|
288
|
+
* Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
|
|
289
|
+
*/
|
|
290
|
+
outbound_payments?: Features.OutboundPayments;
|
|
291
|
+
|
|
292
|
+
/**
|
|
293
|
+
* Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
|
|
294
|
+
*/
|
|
295
|
+
outbound_transfers?: Features.OutboundTransfers;
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
namespace Features {
|
|
299
|
+
interface DepositInsurance {
|
|
300
|
+
/**
|
|
301
|
+
* Whether the FinancialAccount should have the Feature.
|
|
302
|
+
*/
|
|
303
|
+
requested: boolean;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
interface FinancialAddresses {
|
|
307
|
+
/**
|
|
308
|
+
* Adds an ABA FinancialAddress to the FinancialAccount.
|
|
309
|
+
*/
|
|
310
|
+
aba?: FinancialAddresses.Aba;
|
|
311
|
+
}
|
|
312
|
+
|
|
313
|
+
namespace FinancialAddresses {
|
|
314
|
+
interface Aba {
|
|
315
|
+
/**
|
|
316
|
+
* Whether the FinancialAccount should have the Feature.
|
|
317
|
+
*/
|
|
318
|
+
requested: boolean;
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
interface InboundTransfers {
|
|
323
|
+
/**
|
|
324
|
+
* Enables ACH Debits via the InboundTransfers API.
|
|
325
|
+
*/
|
|
326
|
+
ach?: InboundTransfers.Ach;
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
namespace InboundTransfers {
|
|
330
|
+
interface Ach {
|
|
331
|
+
/**
|
|
332
|
+
* Whether the FinancialAccount should have the Feature.
|
|
333
|
+
*/
|
|
334
|
+
requested: boolean;
|
|
335
|
+
}
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
interface IntraStripeFlows {
|
|
339
|
+
/**
|
|
340
|
+
* Whether the FinancialAccount should have the Feature.
|
|
341
|
+
*/
|
|
342
|
+
requested: boolean;
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
interface OutboundPayments {
|
|
346
|
+
/**
|
|
347
|
+
* Enables ACH transfers via the OutboundPayments API.
|
|
348
|
+
*/
|
|
349
|
+
ach?: OutboundPayments.Ach;
|
|
350
|
+
|
|
351
|
+
/**
|
|
352
|
+
* Enables US domestic wire tranfers via the OutboundPayments API.
|
|
353
|
+
*/
|
|
354
|
+
us_domestic_wire?: OutboundPayments.UsDomesticWire;
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
namespace OutboundPayments {
|
|
358
|
+
interface Ach {
|
|
359
|
+
/**
|
|
360
|
+
* Whether the FinancialAccount should have the Feature.
|
|
361
|
+
*/
|
|
362
|
+
requested: boolean;
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
interface UsDomesticWire {
|
|
366
|
+
/**
|
|
367
|
+
* Whether the FinancialAccount should have the Feature.
|
|
368
|
+
*/
|
|
369
|
+
requested: boolean;
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
interface OutboundTransfers {
|
|
374
|
+
/**
|
|
375
|
+
* Enables ACH transfers via the OutboundTransfers API.
|
|
376
|
+
*/
|
|
377
|
+
ach?: OutboundTransfers.Ach;
|
|
378
|
+
|
|
379
|
+
/**
|
|
380
|
+
* Enables US domestic wire tranfers via the OutboundTransfers API.
|
|
381
|
+
*/
|
|
382
|
+
us_domestic_wire?: OutboundTransfers.UsDomesticWire;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
namespace OutboundTransfers {
|
|
386
|
+
interface Ach {
|
|
387
|
+
/**
|
|
388
|
+
* Whether the FinancialAccount should have the Feature.
|
|
389
|
+
*/
|
|
390
|
+
requested: boolean;
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
interface UsDomesticWire {
|
|
394
|
+
/**
|
|
395
|
+
* Whether the FinancialAccount should have the Feature.
|
|
396
|
+
*/
|
|
397
|
+
requested: boolean;
|
|
398
|
+
}
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
interface PlatformRestrictions {
|
|
403
|
+
/**
|
|
404
|
+
* Restricts all inbound money movement.
|
|
405
|
+
*/
|
|
406
|
+
inbound_flows?: PlatformRestrictions.InboundFlows;
|
|
407
|
+
|
|
408
|
+
/**
|
|
409
|
+
* Restricts all outbound money movement.
|
|
410
|
+
*/
|
|
411
|
+
outbound_flows?: PlatformRestrictions.OutboundFlows;
|
|
412
|
+
}
|
|
413
|
+
|
|
414
|
+
namespace PlatformRestrictions {
|
|
415
|
+
type InboundFlows = 'restricted' | 'unrestricted';
|
|
416
|
+
|
|
417
|
+
type OutboundFlows = 'restricted' | 'unrestricted';
|
|
418
|
+
}
|
|
419
|
+
}
|
|
420
|
+
|
|
421
|
+
interface FinancialAccountRetrieveParams {
|
|
422
|
+
/**
|
|
423
|
+
* Specifies which fields in the response should be expanded.
|
|
424
|
+
*/
|
|
425
|
+
expand?: Array<string>;
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
interface FinancialAccountUpdateParams {
|
|
429
|
+
/**
|
|
430
|
+
* Specifies which fields in the response should be expanded.
|
|
431
|
+
*/
|
|
432
|
+
expand?: Array<string>;
|
|
433
|
+
|
|
434
|
+
/**
|
|
435
|
+
* Encodes whether a FinancialAccount has access to a particular feature, with a status enum and associated `status_details`. Stripe or the platform may control features via the requested field.
|
|
436
|
+
*/
|
|
437
|
+
features?: FinancialAccountUpdateParams.Features;
|
|
438
|
+
|
|
439
|
+
/**
|
|
440
|
+
* Set of [key-value pairs](https://stripe.com/docs/api/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. Individual keys can be unset by posting an empty value to them. All keys can be unset by posting an empty value to `metadata`.
|
|
441
|
+
*/
|
|
442
|
+
metadata?: Stripe.MetadataParam;
|
|
443
|
+
|
|
444
|
+
/**
|
|
445
|
+
* The set of functionalities that the platform can restrict on the FinancialAccount.
|
|
446
|
+
*/
|
|
447
|
+
platform_restrictions?: FinancialAccountUpdateParams.PlatformRestrictions;
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
namespace FinancialAccountUpdateParams {
|
|
451
|
+
interface Features {
|
|
452
|
+
/**
|
|
453
|
+
* Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
|
|
454
|
+
*/
|
|
455
|
+
deposit_insurance?: Features.DepositInsurance;
|
|
456
|
+
|
|
457
|
+
/**
|
|
458
|
+
* Contains Features that add FinancialAddresses to the FinancialAccount.
|
|
459
|
+
*/
|
|
460
|
+
financial_addresses?: Features.FinancialAddresses;
|
|
461
|
+
|
|
462
|
+
/**
|
|
463
|
+
* Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
|
|
464
|
+
*/
|
|
465
|
+
inbound_transfers?: Features.InboundTransfers;
|
|
466
|
+
|
|
467
|
+
/**
|
|
468
|
+
* Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
|
|
469
|
+
*/
|
|
470
|
+
intra_stripe_flows?: Features.IntraStripeFlows;
|
|
471
|
+
|
|
472
|
+
/**
|
|
473
|
+
* Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
|
|
474
|
+
*/
|
|
475
|
+
outbound_payments?: Features.OutboundPayments;
|
|
476
|
+
|
|
477
|
+
/**
|
|
478
|
+
* Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
|
|
479
|
+
*/
|
|
480
|
+
outbound_transfers?: Features.OutboundTransfers;
|
|
481
|
+
}
|
|
482
|
+
|
|
483
|
+
namespace Features {
|
|
484
|
+
interface DepositInsurance {
|
|
485
|
+
/**
|
|
486
|
+
* Whether the FinancialAccount should have the Feature.
|
|
487
|
+
*/
|
|
488
|
+
requested: boolean;
|
|
489
|
+
}
|
|
490
|
+
|
|
491
|
+
interface FinancialAddresses {
|
|
492
|
+
/**
|
|
493
|
+
* Adds an ABA FinancialAddress to the FinancialAccount.
|
|
494
|
+
*/
|
|
495
|
+
aba?: FinancialAddresses.Aba;
|
|
496
|
+
}
|
|
497
|
+
|
|
498
|
+
namespace FinancialAddresses {
|
|
499
|
+
interface Aba {
|
|
500
|
+
/**
|
|
501
|
+
* Whether the FinancialAccount should have the Feature.
|
|
502
|
+
*/
|
|
503
|
+
requested: boolean;
|
|
504
|
+
}
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
interface InboundTransfers {
|
|
508
|
+
/**
|
|
509
|
+
* Enables ACH Debits via the InboundTransfers API.
|
|
510
|
+
*/
|
|
511
|
+
ach?: InboundTransfers.Ach;
|
|
512
|
+
}
|
|
513
|
+
|
|
514
|
+
namespace InboundTransfers {
|
|
515
|
+
interface Ach {
|
|
516
|
+
/**
|
|
517
|
+
* Whether the FinancialAccount should have the Feature.
|
|
518
|
+
*/
|
|
519
|
+
requested: boolean;
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
interface IntraStripeFlows {
|
|
524
|
+
/**
|
|
525
|
+
* Whether the FinancialAccount should have the Feature.
|
|
526
|
+
*/
|
|
527
|
+
requested: boolean;
|
|
528
|
+
}
|
|
529
|
+
|
|
530
|
+
interface OutboundPayments {
|
|
531
|
+
/**
|
|
532
|
+
* Enables ACH transfers via the OutboundPayments API.
|
|
533
|
+
*/
|
|
534
|
+
ach?: OutboundPayments.Ach;
|
|
535
|
+
|
|
536
|
+
/**
|
|
537
|
+
* Enables US domestic wire tranfers via the OutboundPayments API.
|
|
538
|
+
*/
|
|
539
|
+
us_domestic_wire?: OutboundPayments.UsDomesticWire;
|
|
540
|
+
}
|
|
541
|
+
|
|
542
|
+
namespace OutboundPayments {
|
|
543
|
+
interface Ach {
|
|
544
|
+
/**
|
|
545
|
+
* Whether the FinancialAccount should have the Feature.
|
|
546
|
+
*/
|
|
547
|
+
requested: boolean;
|
|
548
|
+
}
|
|
549
|
+
|
|
550
|
+
interface UsDomesticWire {
|
|
551
|
+
/**
|
|
552
|
+
* Whether the FinancialAccount should have the Feature.
|
|
553
|
+
*/
|
|
554
|
+
requested: boolean;
|
|
555
|
+
}
|
|
556
|
+
}
|
|
557
|
+
|
|
558
|
+
interface OutboundTransfers {
|
|
559
|
+
/**
|
|
560
|
+
* Enables ACH transfers via the OutboundTransfers API.
|
|
561
|
+
*/
|
|
562
|
+
ach?: OutboundTransfers.Ach;
|
|
563
|
+
|
|
564
|
+
/**
|
|
565
|
+
* Enables US domestic wire tranfers via the OutboundTransfers API.
|
|
566
|
+
*/
|
|
567
|
+
us_domestic_wire?: OutboundTransfers.UsDomesticWire;
|
|
568
|
+
}
|
|
569
|
+
|
|
570
|
+
namespace OutboundTransfers {
|
|
571
|
+
interface Ach {
|
|
572
|
+
/**
|
|
573
|
+
* Whether the FinancialAccount should have the Feature.
|
|
574
|
+
*/
|
|
575
|
+
requested: boolean;
|
|
576
|
+
}
|
|
577
|
+
|
|
578
|
+
interface UsDomesticWire {
|
|
579
|
+
/**
|
|
580
|
+
* Whether the FinancialAccount should have the Feature.
|
|
581
|
+
*/
|
|
582
|
+
requested: boolean;
|
|
583
|
+
}
|
|
584
|
+
}
|
|
585
|
+
}
|
|
586
|
+
|
|
587
|
+
interface PlatformRestrictions {
|
|
588
|
+
/**
|
|
589
|
+
* Restricts all inbound money movement.
|
|
590
|
+
*/
|
|
591
|
+
inbound_flows?: PlatformRestrictions.InboundFlows;
|
|
592
|
+
|
|
593
|
+
/**
|
|
594
|
+
* Restricts all outbound money movement.
|
|
595
|
+
*/
|
|
596
|
+
outbound_flows?: PlatformRestrictions.OutboundFlows;
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
namespace PlatformRestrictions {
|
|
600
|
+
type InboundFlows = 'restricted' | 'unrestricted';
|
|
601
|
+
|
|
602
|
+
type OutboundFlows = 'restricted' | 'unrestricted';
|
|
603
|
+
}
|
|
604
|
+
}
|
|
605
|
+
|
|
606
|
+
interface FinancialAccountListParams extends PaginationParams {
|
|
607
|
+
created?: Stripe.RangeQueryParam | number;
|
|
608
|
+
|
|
609
|
+
/**
|
|
610
|
+
* Specifies which fields in the response should be expanded.
|
|
611
|
+
*/
|
|
612
|
+
expand?: Array<string>;
|
|
613
|
+
}
|
|
614
|
+
|
|
615
|
+
interface FinancialAccountRetrieveFeaturesParams {
|
|
616
|
+
/**
|
|
617
|
+
* Specifies which fields in the response should be expanded.
|
|
618
|
+
*/
|
|
619
|
+
expand?: Array<string>;
|
|
620
|
+
}
|
|
621
|
+
|
|
622
|
+
interface FinancialAccountUpdateFeaturesParams {
|
|
623
|
+
/**
|
|
624
|
+
* Represents whether this FinancialAccount is eligible for deposit insurance. Various factors determine the insurance amount.
|
|
625
|
+
*/
|
|
626
|
+
deposit_insurance?: FinancialAccountUpdateFeaturesParams.DepositInsurance;
|
|
627
|
+
|
|
628
|
+
/**
|
|
629
|
+
* Specifies which fields in the response should be expanded.
|
|
630
|
+
*/
|
|
631
|
+
expand?: Array<string>;
|
|
632
|
+
|
|
633
|
+
/**
|
|
634
|
+
* Contains Features that add FinancialAddresses to the FinancialAccount.
|
|
635
|
+
*/
|
|
636
|
+
financial_addresses?: FinancialAccountUpdateFeaturesParams.FinancialAddresses;
|
|
637
|
+
|
|
638
|
+
/**
|
|
639
|
+
* Contains settings related to adding funds to a FinancialAccount from another Account with the same owner.
|
|
640
|
+
*/
|
|
641
|
+
inbound_transfers?: FinancialAccountUpdateFeaturesParams.InboundTransfers;
|
|
642
|
+
|
|
643
|
+
/**
|
|
644
|
+
* Represents the ability for the FinancialAccount to send money to, or receive money from other FinancialAccounts (for example, via OutboundPayment).
|
|
645
|
+
*/
|
|
646
|
+
intra_stripe_flows?: FinancialAccountUpdateFeaturesParams.IntraStripeFlows;
|
|
647
|
+
|
|
648
|
+
/**
|
|
649
|
+
* Includes Features related to initiating money movement out of the FinancialAccount to someone else's bucket of money.
|
|
650
|
+
*/
|
|
651
|
+
outbound_payments?: FinancialAccountUpdateFeaturesParams.OutboundPayments;
|
|
652
|
+
|
|
653
|
+
/**
|
|
654
|
+
* Contains a Feature and settings related to moving money out of the FinancialAccount into another Account with the same owner.
|
|
655
|
+
*/
|
|
656
|
+
outbound_transfers?: FinancialAccountUpdateFeaturesParams.OutboundTransfers;
|
|
657
|
+
}
|
|
658
|
+
|
|
659
|
+
namespace FinancialAccountUpdateFeaturesParams {
|
|
660
|
+
interface DepositInsurance {
|
|
661
|
+
/**
|
|
662
|
+
* Whether the FinancialAccount should have the Feature.
|
|
663
|
+
*/
|
|
664
|
+
requested: boolean;
|
|
665
|
+
}
|
|
666
|
+
|
|
667
|
+
interface FinancialAddresses {
|
|
668
|
+
/**
|
|
669
|
+
* Adds an ABA FinancialAddress to the FinancialAccount.
|
|
670
|
+
*/
|
|
671
|
+
aba?: FinancialAddresses.Aba;
|
|
672
|
+
}
|
|
673
|
+
|
|
674
|
+
namespace FinancialAddresses {
|
|
675
|
+
interface Aba {
|
|
676
|
+
/**
|
|
677
|
+
* Whether the FinancialAccount should have the Feature.
|
|
678
|
+
*/
|
|
679
|
+
requested: boolean;
|
|
680
|
+
}
|
|
681
|
+
}
|
|
682
|
+
|
|
683
|
+
interface InboundTransfers {
|
|
684
|
+
/**
|
|
685
|
+
* Enables ACH Debits via the InboundTransfers API.
|
|
686
|
+
*/
|
|
687
|
+
ach?: InboundTransfers.Ach;
|
|
688
|
+
}
|
|
689
|
+
|
|
690
|
+
namespace InboundTransfers {
|
|
691
|
+
interface Ach {
|
|
692
|
+
/**
|
|
693
|
+
* Whether the FinancialAccount should have the Feature.
|
|
694
|
+
*/
|
|
695
|
+
requested: boolean;
|
|
696
|
+
}
|
|
697
|
+
}
|
|
698
|
+
|
|
699
|
+
interface IntraStripeFlows {
|
|
700
|
+
/**
|
|
701
|
+
* Whether the FinancialAccount should have the Feature.
|
|
702
|
+
*/
|
|
703
|
+
requested: boolean;
|
|
704
|
+
}
|
|
705
|
+
|
|
706
|
+
interface OutboundPayments {
|
|
707
|
+
/**
|
|
708
|
+
* Enables ACH transfers via the OutboundPayments API.
|
|
709
|
+
*/
|
|
710
|
+
ach?: OutboundPayments.Ach;
|
|
711
|
+
|
|
712
|
+
/**
|
|
713
|
+
* Enables US domestic wire tranfers via the OutboundPayments API.
|
|
714
|
+
*/
|
|
715
|
+
us_domestic_wire?: OutboundPayments.UsDomesticWire;
|
|
716
|
+
}
|
|
717
|
+
|
|
718
|
+
namespace OutboundPayments {
|
|
719
|
+
interface Ach {
|
|
720
|
+
/**
|
|
721
|
+
* Whether the FinancialAccount should have the Feature.
|
|
722
|
+
*/
|
|
723
|
+
requested: boolean;
|
|
724
|
+
}
|
|
725
|
+
|
|
726
|
+
interface UsDomesticWire {
|
|
727
|
+
/**
|
|
728
|
+
* Whether the FinancialAccount should have the Feature.
|
|
729
|
+
*/
|
|
730
|
+
requested: boolean;
|
|
731
|
+
}
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
interface OutboundTransfers {
|
|
735
|
+
/**
|
|
736
|
+
* Enables ACH transfers via the OutboundTransfers API.
|
|
737
|
+
*/
|
|
738
|
+
ach?: OutboundTransfers.Ach;
|
|
739
|
+
|
|
740
|
+
/**
|
|
741
|
+
* Enables US domestic wire tranfers via the OutboundTransfers API.
|
|
742
|
+
*/
|
|
743
|
+
us_domestic_wire?: OutboundTransfers.UsDomesticWire;
|
|
744
|
+
}
|
|
745
|
+
|
|
746
|
+
namespace OutboundTransfers {
|
|
747
|
+
interface Ach {
|
|
748
|
+
/**
|
|
749
|
+
* Whether the FinancialAccount should have the Feature.
|
|
750
|
+
*/
|
|
751
|
+
requested: boolean;
|
|
752
|
+
}
|
|
753
|
+
|
|
754
|
+
interface UsDomesticWire {
|
|
755
|
+
/**
|
|
756
|
+
* Whether the FinancialAccount should have the Feature.
|
|
757
|
+
*/
|
|
758
|
+
requested: boolean;
|
|
759
|
+
}
|
|
760
|
+
}
|
|
761
|
+
}
|
|
762
|
+
|
|
763
|
+
class FinancialAccountsResource {
|
|
764
|
+
/**
|
|
765
|
+
* Creates a new FinancialAccount. For now, each connected account can only have one FinancialAccount.
|
|
766
|
+
*/
|
|
767
|
+
create(
|
|
768
|
+
params: FinancialAccountCreateParams,
|
|
769
|
+
options?: RequestOptions
|
|
770
|
+
): Promise<Stripe.Response<Stripe.Treasury.FinancialAccount>>;
|
|
771
|
+
|
|
772
|
+
/**
|
|
773
|
+
* Retrieves the details of a FinancialAccount.
|
|
774
|
+
*/
|
|
775
|
+
retrieve(
|
|
776
|
+
id: string,
|
|
777
|
+
params?: FinancialAccountRetrieveParams,
|
|
778
|
+
options?: RequestOptions
|
|
779
|
+
): Promise<Stripe.Response<Stripe.Treasury.FinancialAccount>>;
|
|
780
|
+
retrieve(
|
|
781
|
+
id: string,
|
|
782
|
+
options?: RequestOptions
|
|
783
|
+
): Promise<Stripe.Response<Stripe.Treasury.FinancialAccount>>;
|
|
784
|
+
|
|
785
|
+
/**
|
|
786
|
+
* Updates the details of a FinancialAccount.
|
|
787
|
+
*/
|
|
788
|
+
update(
|
|
789
|
+
id: string,
|
|
790
|
+
params?: FinancialAccountUpdateParams,
|
|
791
|
+
options?: RequestOptions
|
|
792
|
+
): Promise<Stripe.Response<Stripe.Treasury.FinancialAccount>>;
|
|
793
|
+
|
|
794
|
+
/**
|
|
795
|
+
* Returns a list of FinancialAccounts.
|
|
796
|
+
*/
|
|
797
|
+
list(
|
|
798
|
+
params?: FinancialAccountListParams,
|
|
799
|
+
options?: RequestOptions
|
|
800
|
+
): ApiListPromise<Stripe.Treasury.FinancialAccount>;
|
|
801
|
+
list(
|
|
802
|
+
options?: RequestOptions
|
|
803
|
+
): ApiListPromise<Stripe.Treasury.FinancialAccount>;
|
|
804
|
+
|
|
805
|
+
/**
|
|
806
|
+
* Retrieves Features information associated with the FinancialAccount.
|
|
807
|
+
*/
|
|
808
|
+
retrieveFeatures(
|
|
809
|
+
id: string,
|
|
810
|
+
params?: FinancialAccountRetrieveFeaturesParams,
|
|
811
|
+
options?: RequestOptions
|
|
812
|
+
): Promise<Stripe.Response<Stripe.Treasury.FinancialAccountFeatures>>;
|
|
813
|
+
retrieveFeatures(
|
|
814
|
+
id: string,
|
|
815
|
+
options?: RequestOptions
|
|
816
|
+
): Promise<Stripe.Response<Stripe.Treasury.FinancialAccountFeatures>>;
|
|
817
|
+
|
|
818
|
+
/**
|
|
819
|
+
* Updates the Features associated with a FinancialAccount.
|
|
820
|
+
*/
|
|
821
|
+
updateFeatures(
|
|
822
|
+
id: string,
|
|
823
|
+
params?: FinancialAccountUpdateFeaturesParams,
|
|
824
|
+
options?: RequestOptions
|
|
825
|
+
): Promise<Stripe.Response<Stripe.Treasury.FinancialAccountFeatures>>;
|
|
826
|
+
updateFeatures(
|
|
827
|
+
id: string,
|
|
828
|
+
options?: RequestOptions
|
|
829
|
+
): Promise<Stripe.Response<Stripe.Treasury.FinancialAccountFeatures>>;
|
|
830
|
+
}
|
|
831
|
+
}
|
|
832
|
+
}
|
|
833
|
+
}
|