@stripe/stripe-js 3.0.10 → 3.1.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/dist/api/bank-accounts.d.mts +61 -0
- package/dist/api/bank-accounts.d.ts +61 -0
- package/dist/api/cards.d.mts +130 -0
- package/dist/api/cards.d.ts +130 -0
- package/dist/api/confirmation-tokens.d.mts +183 -0
- package/dist/api/confirmation-tokens.d.ts +183 -0
- package/dist/api/financial-connections.d.mts +232 -0
- package/dist/api/financial-connections.d.ts +232 -0
- package/dist/api/index.d.mts +12 -0
- package/dist/api/index.d.ts +12 -0
- package/dist/api/orders.d.mts +122 -0
- package/dist/api/orders.d.ts +122 -0
- package/dist/api/payment-intents.d.mts +330 -0
- package/dist/api/payment-intents.d.ts +330 -0
- package/dist/api/payment-methods.d.mts +452 -0
- package/dist/api/payment-methods.d.ts +452 -0
- package/dist/api/setup-intents.d.mts +184 -0
- package/dist/api/setup-intents.d.ts +184 -0
- package/dist/api/shared.d.mts +125 -0
- package/dist/api/shared.d.ts +125 -0
- package/dist/api/sources.d.mts +1045 -0
- package/dist/api/sources.d.ts +1045 -0
- package/dist/api/tokens.d.mts +639 -0
- package/dist/api/tokens.d.ts +639 -0
- package/dist/api/verification-sessions.d.mts +9 -0
- package/dist/api/verification-sessions.d.ts +9 -0
- package/dist/index.d.mts +4 -12792
- package/dist/index.d.ts +4 -12792
- package/dist/{stripe.js → index.js} +1 -1
- package/dist/{stripe.mjs → index.mjs} +1 -1
- package/dist/pure.d.mts +5 -0
- package/dist/pure.d.ts +5 -0
- package/dist/pure.js +204 -0
- package/dist/pure.mjs +200 -0
- package/dist/shared.d.mts +6 -0
- package/dist/shared.d.ts +6 -0
- package/dist/stripe-js/checkout.d.mts +153 -0
- package/dist/stripe-js/checkout.d.ts +153 -0
- package/dist/stripe-js/confirmation-tokens.d.mts +1 -0
- package/dist/stripe-js/confirmation-tokens.d.ts +1 -0
- package/dist/stripe-js/custom-checkout.d.mts +402 -0
- package/dist/stripe-js/custom-checkout.d.ts +402 -0
- package/dist/stripe-js/elements/address.d.mts +261 -0
- package/dist/stripe-js/elements/address.d.ts +261 -0
- package/dist/stripe-js/elements/affirm-message.d.mts +65 -0
- package/dist/stripe-js/elements/affirm-message.d.ts +65 -0
- package/dist/stripe-js/elements/afterpay-clearpay-message.d.mts +119 -0
- package/dist/stripe-js/elements/afterpay-clearpay-message.d.ts +119 -0
- package/dist/stripe-js/elements/apple-pay.d.mts +156 -0
- package/dist/stripe-js/elements/apple-pay.d.ts +156 -0
- package/dist/stripe-js/elements/au-bank-account.d.mts +138 -0
- package/dist/stripe-js/elements/au-bank-account.d.ts +138 -0
- package/dist/stripe-js/elements/base.d.mts +264 -0
- package/dist/stripe-js/elements/base.d.ts +264 -0
- package/dist/stripe-js/elements/card-cvc.d.mts +119 -0
- package/dist/stripe-js/elements/card-cvc.d.ts +119 -0
- package/dist/stripe-js/elements/card-expiry.d.mts +119 -0
- package/dist/stripe-js/elements/card-expiry.d.ts +119 -0
- package/dist/stripe-js/elements/card-number.d.mts +200 -0
- package/dist/stripe-js/elements/card-number.d.ts +200 -0
- package/dist/stripe-js/elements/card.d.mts +226 -0
- package/dist/stripe-js/elements/card.d.ts +226 -0
- package/dist/stripe-js/elements/cart.d.mts +224 -0
- package/dist/stripe-js/elements/cart.d.ts +224 -0
- package/dist/stripe-js/elements/eps-bank.d.mts +140 -0
- package/dist/stripe-js/elements/eps-bank.d.ts +140 -0
- package/dist/stripe-js/elements/express-checkout.d.mts +446 -0
- package/dist/stripe-js/elements/express-checkout.d.ts +446 -0
- package/dist/stripe-js/elements/fpx-bank.d.mts +134 -0
- package/dist/stripe-js/elements/fpx-bank.d.ts +134 -0
- package/dist/stripe-js/elements/iban.d.mts +135 -0
- package/dist/stripe-js/elements/iban.d.ts +135 -0
- package/dist/stripe-js/elements/ideal-bank.d.mts +140 -0
- package/dist/stripe-js/elements/ideal-bank.d.ts +140 -0
- package/dist/stripe-js/elements/index.d.mts +22 -0
- package/dist/stripe-js/elements/index.d.ts +22 -0
- package/dist/stripe-js/elements/issuing/index.d.mts +5 -0
- package/dist/stripe-js/elements/issuing/index.d.ts +5 -0
- package/dist/stripe-js/elements/issuing/issuing-card-copy-button.d.mts +37 -0
- package/dist/stripe-js/elements/issuing/issuing-card-copy-button.d.ts +37 -0
- package/dist/stripe-js/elements/issuing/issuing-card-cvc-display.d.mts +32 -0
- package/dist/stripe-js/elements/issuing/issuing-card-cvc-display.d.ts +32 -0
- package/dist/stripe-js/elements/issuing/issuing-card-expiry-display.d.mts +32 -0
- package/dist/stripe-js/elements/issuing/issuing-card-expiry-display.d.ts +32 -0
- package/dist/stripe-js/elements/issuing/issuing-card-number-display.d.mts +40 -0
- package/dist/stripe-js/elements/issuing/issuing-card-number-display.d.ts +40 -0
- package/dist/stripe-js/elements/issuing/issuing-card-pin-display.d.mts +32 -0
- package/dist/stripe-js/elements/issuing/issuing-card-pin-display.d.ts +32 -0
- package/dist/stripe-js/elements/link-authentication.d.mts +158 -0
- package/dist/stripe-js/elements/link-authentication.d.ts +158 -0
- package/dist/stripe-js/elements/p24-bank.d.mts +140 -0
- package/dist/stripe-js/elements/p24-bank.d.ts +140 -0
- package/dist/stripe-js/elements/payment-method-messaging.d.mts +98 -0
- package/dist/stripe-js/elements/payment-method-messaging.d.ts +98 -0
- package/dist/stripe-js/elements/payment-request-button.d.mts +151 -0
- package/dist/stripe-js/elements/payment-request-button.d.ts +151 -0
- package/dist/stripe-js/elements/payment.d.mts +275 -0
- package/dist/stripe-js/elements/payment.d.ts +275 -0
- package/dist/stripe-js/elements/shipping-address.d.mts +215 -0
- package/dist/stripe-js/elements/shipping-address.d.ts +215 -0
- package/dist/stripe-js/elements-group.d.mts +1129 -0
- package/dist/stripe-js/elements-group.d.ts +1129 -0
- package/dist/stripe-js/embedded-checkout.d.mts +35 -0
- package/dist/stripe-js/embedded-checkout.d.ts +35 -0
- package/dist/stripe-js/ephemeral-keys.d.mts +3 -0
- package/dist/stripe-js/ephemeral-keys.d.ts +3 -0
- package/dist/stripe-js/financial-connections.d.mts +19 -0
- package/dist/stripe-js/financial-connections.d.ts +19 -0
- package/dist/stripe-js/index.d.mts +13 -0
- package/dist/stripe-js/index.d.ts +13 -0
- package/dist/stripe-js/orders.d.mts +9 -0
- package/dist/stripe-js/orders.d.ts +9 -0
- package/dist/stripe-js/payment-intents.d.mts +1470 -0
- package/dist/stripe-js/payment-intents.d.ts +1470 -0
- package/dist/stripe-js/payment-request.d.mts +529 -0
- package/dist/stripe-js/payment-request.d.ts +529 -0
- package/dist/stripe-js/setup-intents.d.mts +250 -0
- package/dist/stripe-js/setup-intents.d.ts +250 -0
- package/dist/stripe-js/stripe.d.mts +1486 -0
- package/dist/stripe-js/stripe.d.ts +1486 -0
- package/dist/stripe-js/token-and-sources.d.mts +110 -0
- package/dist/stripe-js/token-and-sources.d.ts +110 -0
- package/dist/utils.d.mts +2 -0
- package/dist/utils.d.ts +2 -0
- package/lib/index.d.mts +1 -0
- package/lib/index.d.ts +1 -0
- package/lib/index.js +2 -0
- package/lib/index.mjs +1 -0
- package/package.json +11 -10
- package/pure/index.d.mts +1 -12771
- package/pure/index.d.ts +1 -12771
- package/pure/index.js +1 -204
- package/pure/index.mjs +1 -200
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The BankAccount object.
|
|
3
|
+
*/
|
|
4
|
+
export interface BankAccount {
|
|
5
|
+
/**
|
|
6
|
+
* Unique identifier for the object.
|
|
7
|
+
*/
|
|
8
|
+
id: string;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* String representing the object's type. Objects of the same type share the same value.
|
|
12
|
+
*/
|
|
13
|
+
object: 'bank_account';
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* The name of the person or business that owns the bank account.
|
|
17
|
+
*/
|
|
18
|
+
account_holder_name: string | null;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* The type of entity that holds the account. This can be either `individual` or `company`.
|
|
22
|
+
*/
|
|
23
|
+
account_holder_type: string | null;
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Name of the bank associated with the routing number (e.g., `WELLS FARGO`).
|
|
27
|
+
*/
|
|
28
|
+
bank_name: string | null;
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Two-letter ISO code representing the country the bank account is located in.
|
|
32
|
+
*/
|
|
33
|
+
country: string;
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account.
|
|
37
|
+
*/
|
|
38
|
+
currency: string;
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
|
|
42
|
+
*/
|
|
43
|
+
fingerprint: string | null;
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* The last four digits of the bank account number.
|
|
47
|
+
*/
|
|
48
|
+
last4: string;
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* The routing transit number for the bank account.
|
|
52
|
+
*/
|
|
53
|
+
routing_number: string | null;
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* For bank accounts, possible values are `new`, `validated`, `verified`, `verification_failed`, or `errored`. A bank account that hasn't had any activity or validation performed is `new`. If Stripe can determine that the bank account exists, its status will be `validated`. Note that there often isn't enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be `verified`. If the verification failed for any reason, such as microdeposit failure, the status will be `verification_failed`. If a transfer sent to this bank account fails, we'll set the status to `errored` and will not continue to send transfers until the bank details are updated.
|
|
57
|
+
*
|
|
58
|
+
* For external accounts, possible values are `new` and `errored`. Validations aren't run against external accounts because they're only used for payouts. This means the other statuses don't apply. If a transfer fails, the status is set to `errored` and transfers are stopped until account details are updated.
|
|
59
|
+
*/
|
|
60
|
+
status: string;
|
|
61
|
+
}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The BankAccount object.
|
|
3
|
+
*/
|
|
4
|
+
export interface BankAccount {
|
|
5
|
+
/**
|
|
6
|
+
* Unique identifier for the object.
|
|
7
|
+
*/
|
|
8
|
+
id: string;
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* String representing the object's type. Objects of the same type share the same value.
|
|
12
|
+
*/
|
|
13
|
+
object: 'bank_account';
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* The name of the person or business that owns the bank account.
|
|
17
|
+
*/
|
|
18
|
+
account_holder_name: string | null;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* The type of entity that holds the account. This can be either `individual` or `company`.
|
|
22
|
+
*/
|
|
23
|
+
account_holder_type: string | null;
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Name of the bank associated with the routing number (e.g., `WELLS FARGO`).
|
|
27
|
+
*/
|
|
28
|
+
bank_name: string | null;
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Two-letter ISO code representing the country the bank account is located in.
|
|
32
|
+
*/
|
|
33
|
+
country: string;
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Three-letter [ISO code for the currency](https://stripe.com/docs/payouts) paid out to the bank account.
|
|
37
|
+
*/
|
|
38
|
+
currency: string;
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
|
|
42
|
+
*/
|
|
43
|
+
fingerprint: string | null;
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* The last four digits of the bank account number.
|
|
47
|
+
*/
|
|
48
|
+
last4: string;
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* The routing transit number for the bank account.
|
|
52
|
+
*/
|
|
53
|
+
routing_number: string | null;
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* For bank accounts, possible values are `new`, `validated`, `verified`, `verification_failed`, or `errored`. A bank account that hasn't had any activity or validation performed is `new`. If Stripe can determine that the bank account exists, its status will be `validated`. Note that there often isn't enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be `verified`. If the verification failed for any reason, such as microdeposit failure, the status will be `verification_failed`. If a transfer sent to this bank account fails, we'll set the status to `errored` and will not continue to send transfers until the bank details are updated.
|
|
57
|
+
*
|
|
58
|
+
* For external accounts, possible values are `new` and `errored`. Validations aren't run against external accounts because they're only used for payouts. This means the other statuses don't apply. If a transfer fails, the status is set to `errored` and transfers are stopped until account details are updated.
|
|
59
|
+
*/
|
|
60
|
+
status: string;
|
|
61
|
+
}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import {Metadata} from './shared';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* The Card object.
|
|
5
|
+
*/
|
|
6
|
+
export interface Card {
|
|
7
|
+
/**
|
|
8
|
+
* Unique identifier for the object.
|
|
9
|
+
*/
|
|
10
|
+
id: string;
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* String representing the object's type. Objects of the same type share the same value.
|
|
14
|
+
*/
|
|
15
|
+
object: 'card';
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* City/District/Suburb/Town/Village.
|
|
19
|
+
*/
|
|
20
|
+
address_city: string | null;
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Billing address country, if provided when creating card.
|
|
24
|
+
*/
|
|
25
|
+
address_country: string | null;
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Address line 1 (Street address/PO Box/Company name).
|
|
29
|
+
*/
|
|
30
|
+
address_line1: string | null;
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* If `address_line1` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.
|
|
34
|
+
*/
|
|
35
|
+
address_line1_check: string | null;
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Address line 2 (Apartment/Suite/Unit/Building).
|
|
39
|
+
*/
|
|
40
|
+
address_line2: string | null;
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* State/County/Province/Region.
|
|
44
|
+
*/
|
|
45
|
+
address_state: string | null;
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* ZIP or postal code.
|
|
49
|
+
*/
|
|
50
|
+
address_zip: string | null;
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* If `address_zip` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.
|
|
54
|
+
*/
|
|
55
|
+
address_zip_check: string | null;
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* Card brand. Can be `American Express`, `Diners Club`, `Discover`, `JCB`, `MasterCard`, `UnionPay`, `Visa`, or `Unknown`.
|
|
59
|
+
*/
|
|
60
|
+
brand: string;
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.
|
|
64
|
+
*/
|
|
65
|
+
country: string | null;
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
|
|
69
|
+
*/
|
|
70
|
+
currency?: string | null;
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* The customer that this card belongs to. This attribute will not be in the card object if the card belongs to an account or recipient instead.
|
|
74
|
+
*/
|
|
75
|
+
customer?: string | null;
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* If a CVC was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.
|
|
79
|
+
*/
|
|
80
|
+
cvc_check: string | null;
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* (For tokenized numbers only.) The last four digits of the device account number.
|
|
84
|
+
*/
|
|
85
|
+
dynamic_last4: string | null;
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* Two-digit number representing the card's expiration month.
|
|
89
|
+
*/
|
|
90
|
+
exp_month: number;
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* Four-digit number representing the card's expiration year.
|
|
94
|
+
*/
|
|
95
|
+
exp_year: number;
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* Uniquely identifies this particular card number. You can use this attribute to check whether two customers who've signed up with you are using the same card number, for example.
|
|
99
|
+
*/
|
|
100
|
+
fingerprint?: string | null;
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
|
|
104
|
+
*/
|
|
105
|
+
funding: string;
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* The last four digits of the card.
|
|
109
|
+
*/
|
|
110
|
+
last4: string;
|
|
111
|
+
|
|
112
|
+
/**
|
|
113
|
+
* Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
|
|
114
|
+
*/
|
|
115
|
+
metadata: Metadata;
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Cardholder name.
|
|
119
|
+
*/
|
|
120
|
+
name: string | null;
|
|
121
|
+
|
|
122
|
+
/**
|
|
123
|
+
* If the card number is tokenized, this is the method that was used. Can be `apple_pay` or `google_pay`.
|
|
124
|
+
*/
|
|
125
|
+
tokenization_method: string | null;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export namespace Card {
|
|
129
|
+
export type AvailablePayoutMethod = 'instant' | 'standard';
|
|
130
|
+
}
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import {Metadata} from './shared';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* The Card object.
|
|
5
|
+
*/
|
|
6
|
+
export interface Card {
|
|
7
|
+
/**
|
|
8
|
+
* Unique identifier for the object.
|
|
9
|
+
*/
|
|
10
|
+
id: string;
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* String representing the object's type. Objects of the same type share the same value.
|
|
14
|
+
*/
|
|
15
|
+
object: 'card';
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* City/District/Suburb/Town/Village.
|
|
19
|
+
*/
|
|
20
|
+
address_city: string | null;
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* Billing address country, if provided when creating card.
|
|
24
|
+
*/
|
|
25
|
+
address_country: string | null;
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Address line 1 (Street address/PO Box/Company name).
|
|
29
|
+
*/
|
|
30
|
+
address_line1: string | null;
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* If `address_line1` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.
|
|
34
|
+
*/
|
|
35
|
+
address_line1_check: string | null;
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Address line 2 (Apartment/Suite/Unit/Building).
|
|
39
|
+
*/
|
|
40
|
+
address_line2: string | null;
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* State/County/Province/Region.
|
|
44
|
+
*/
|
|
45
|
+
address_state: string | null;
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* ZIP or postal code.
|
|
49
|
+
*/
|
|
50
|
+
address_zip: string | null;
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* If `address_zip` was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.
|
|
54
|
+
*/
|
|
55
|
+
address_zip_check: string | null;
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* Card brand. Can be `American Express`, `Diners Club`, `Discover`, `JCB`, `MasterCard`, `UnionPay`, `Visa`, or `Unknown`.
|
|
59
|
+
*/
|
|
60
|
+
brand: string;
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Two-letter ISO code representing the country of the card. You could use this attribute to get a sense of the international breakdown of cards you've collected.
|
|
64
|
+
*/
|
|
65
|
+
country: string | null;
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* Three-letter [ISO currency code](https://www.iso.org/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https://stripe.com/docs/currencies).
|
|
69
|
+
*/
|
|
70
|
+
currency?: string | null;
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* The customer that this card belongs to. This attribute will not be in the card object if the card belongs to an account or recipient instead.
|
|
74
|
+
*/
|
|
75
|
+
customer?: string | null;
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* If a CVC was provided, results of the check: `pass`, `fail`, `unavailable`, or `unchecked`.
|
|
79
|
+
*/
|
|
80
|
+
cvc_check: string | null;
|
|
81
|
+
|
|
82
|
+
/**
|
|
83
|
+
* (For tokenized numbers only.) The last four digits of the device account number.
|
|
84
|
+
*/
|
|
85
|
+
dynamic_last4: string | null;
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* Two-digit number representing the card's expiration month.
|
|
89
|
+
*/
|
|
90
|
+
exp_month: number;
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* Four-digit number representing the card's expiration year.
|
|
94
|
+
*/
|
|
95
|
+
exp_year: number;
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* Uniquely identifies this particular card number. You can use this attribute to check whether two customers who've signed up with you are using the same card number, for example.
|
|
99
|
+
*/
|
|
100
|
+
fingerprint?: string | null;
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* Card funding type. Can be `credit`, `debit`, `prepaid`, or `unknown`.
|
|
104
|
+
*/
|
|
105
|
+
funding: string;
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* The last four digits of the card.
|
|
109
|
+
*/
|
|
110
|
+
last4: string;
|
|
111
|
+
|
|
112
|
+
/**
|
|
113
|
+
* Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
|
|
114
|
+
*/
|
|
115
|
+
metadata: Metadata;
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Cardholder name.
|
|
119
|
+
*/
|
|
120
|
+
name: string | null;
|
|
121
|
+
|
|
122
|
+
/**
|
|
123
|
+
* If the card number is tokenized, this is the method that was used. Can be `apple_pay` or `google_pay`.
|
|
124
|
+
*/
|
|
125
|
+
tokenization_method: string | null;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export namespace Card {
|
|
129
|
+
export type AvailablePayoutMethod = 'instant' | 'standard';
|
|
130
|
+
}
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
import {StripeElements} from '../stripe-js';
|
|
2
|
+
import {Address} from './shared';
|
|
3
|
+
import {PaymentMethod, PaymentMethodCreateParams} from './payment-methods';
|
|
4
|
+
import {PaymentIntent} from './payment-intents';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* The ConfirmationToken object.
|
|
8
|
+
*/
|
|
9
|
+
export interface ConfirmationToken {
|
|
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: 'confirmation_token';
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Time at which the object was created. Measured in seconds since the Unix epoch.
|
|
22
|
+
*/
|
|
23
|
+
created: number;
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Time at which this ConfirmationToken expires and can no longer be used to confirm a PaymentIntent or SetupIntent. This is set to null once this ConfirmationToken has been used. Measured in seconds since the Unix epoch.
|
|
27
|
+
*/
|
|
28
|
+
expires_at: number;
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode.
|
|
32
|
+
*/
|
|
33
|
+
livemode: boolean;
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* ID of the PaymentIntent that this ConfirmationToken was used to confirm, or null if this ConfirmationToken has not yet been used.
|
|
37
|
+
*/
|
|
38
|
+
payment_intent: null | string;
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* Payment details collected by the Payment Element, used to create a PaymentMethod when a PaymentIntent or SetupIntent is confirmed with this ConfirmationToken.
|
|
42
|
+
*/
|
|
43
|
+
payment_method_preview: ConfirmationToken.PaymentMethodPreview;
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* The URL your customer is redirected to after they complete the payment.
|
|
47
|
+
*/
|
|
48
|
+
return_url: string | null;
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Indicates that you intend to make future payments with this ConfirmationToken’s payment method.
|
|
52
|
+
*
|
|
53
|
+
* The presence of this property will [attach the payment method](https://stripe.com/docs/payments/save-during-payment) to the PaymentIntent’s Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
|
|
54
|
+
*
|
|
55
|
+
* Stripe uses `setup_future_usage` to dynamically optimize your payment flow and comply with regional legislation and network rules. For example, if your customer is impacted by [SCA](https://stripe.com/docs/strong-customer-authentication), using `off_session` will ensure that they are authenticated while processing this PaymentIntent. You will then be able to collect [off-session payments](https://stripe.com/docs/payments/cards/charging-saved-cards#off-session-payments-with-saved-cards) for this customer.
|
|
56
|
+
*/
|
|
57
|
+
setup_future_usage: PaymentIntent.SetupFutureUsage | null;
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* ID of the SetupIntent that this ConfirmationToken was used to confirm, or null if this ConfirmationToken has not yet been used.
|
|
61
|
+
*/
|
|
62
|
+
setup_intent: null | string;
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Shipping information for this ConfirmationToken.
|
|
66
|
+
*/
|
|
67
|
+
shipping: PaymentIntent.Shipping | null;
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* Set to true when confirming server-side and using Stripe.js, iOS, or Android client-side SDKs to handle the next actions.
|
|
71
|
+
*/
|
|
72
|
+
use_stripe_sdk: boolean;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export interface ConfirmationTokenCreateParams {
|
|
76
|
+
/**
|
|
77
|
+
* Data used to create a new payment method.
|
|
78
|
+
*
|
|
79
|
+
*/
|
|
80
|
+
payment_method_data?: {
|
|
81
|
+
/**
|
|
82
|
+
* The customer's billing details.
|
|
83
|
+
*/
|
|
84
|
+
billing_details?: PaymentMethodCreateParams.BillingDetails;
|
|
85
|
+
};
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* Shipping information.
|
|
89
|
+
*/
|
|
90
|
+
shipping?: ConfirmationToken.Shipping;
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* The url your customer will be directed to after they complete authentication.
|
|
94
|
+
*/
|
|
95
|
+
return_url?: string | null;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
export interface CreateConfirmationToken {
|
|
99
|
+
/**
|
|
100
|
+
* The Elements instance.
|
|
101
|
+
*
|
|
102
|
+
* @docs https://stripe.com/docs/js/elements_object
|
|
103
|
+
*/
|
|
104
|
+
elements: StripeElements;
|
|
105
|
+
|
|
106
|
+
/**
|
|
107
|
+
* Parameters for creating the ConfirmationToken.
|
|
108
|
+
* Details collected by Elements will be overriden by values passed here.
|
|
109
|
+
*/
|
|
110
|
+
params?: ConfirmationTokenCreateParams;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export namespace ConfirmationToken {
|
|
114
|
+
export interface Shipping {
|
|
115
|
+
/**
|
|
116
|
+
* Recipient address.
|
|
117
|
+
*/
|
|
118
|
+
address: Address;
|
|
119
|
+
|
|
120
|
+
/**
|
|
121
|
+
* Recipient name.
|
|
122
|
+
*/
|
|
123
|
+
name: string | null;
|
|
124
|
+
|
|
125
|
+
/**
|
|
126
|
+
* Recipient phone (including extension).
|
|
127
|
+
*/
|
|
128
|
+
phone?: string | null;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
export interface PaymentMethodPreview {
|
|
132
|
+
/**
|
|
133
|
+
* The type of the PaymentMethod. An additional hash is included on payment_method_preview with a name matching this value. It contains additional information specific to the PaymentMethod type.
|
|
134
|
+
*/
|
|
135
|
+
type: string;
|
|
136
|
+
|
|
137
|
+
billing_details: PaymentMethod.BillingDetails;
|
|
138
|
+
|
|
139
|
+
acss_debit?: PaymentMethod.AcssDebit;
|
|
140
|
+
|
|
141
|
+
affirm?: PaymentMethod.Affirm;
|
|
142
|
+
|
|
143
|
+
afterpay_clearpay?: PaymentMethod.AfterpayClearpay;
|
|
144
|
+
|
|
145
|
+
au_becs_debit?: PaymentMethod.AuBecsDebit;
|
|
146
|
+
|
|
147
|
+
card?: PaymentMethod.Card;
|
|
148
|
+
|
|
149
|
+
card_present?: PaymentMethod.CardPresent;
|
|
150
|
+
|
|
151
|
+
eps?: PaymentMethod.Eps;
|
|
152
|
+
|
|
153
|
+
fpx?: PaymentMethod.Fpx;
|
|
154
|
+
|
|
155
|
+
grabpay?: PaymentMethod.GrabPay;
|
|
156
|
+
|
|
157
|
+
ideal?: PaymentMethod.Ideal;
|
|
158
|
+
|
|
159
|
+
p24?: PaymentMethod.P24;
|
|
160
|
+
|
|
161
|
+
sepa_debit?: PaymentMethod.SepaDebit;
|
|
162
|
+
|
|
163
|
+
us_bank_account?: PaymentMethod.UsBankAccount;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
export interface MandateData {
|
|
167
|
+
customer_acceptance: {
|
|
168
|
+
type: 'online';
|
|
169
|
+
|
|
170
|
+
online?: {
|
|
171
|
+
/**
|
|
172
|
+
* The IP address from which the Mandate was accepted by the customer.
|
|
173
|
+
*/
|
|
174
|
+
ip_address: string;
|
|
175
|
+
|
|
176
|
+
/**
|
|
177
|
+
* The user agent of the browser from which the Mandate was accepted by the customer.
|
|
178
|
+
*/
|
|
179
|
+
user_agent: string;
|
|
180
|
+
};
|
|
181
|
+
};
|
|
182
|
+
}
|
|
183
|
+
}
|