stripe-ruby-mock 3.1.0.rc3 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/rspec_tests.yml +38 -0
- data/.rspec +2 -1
- data/CHANGELOG.md +36 -0
- data/Gemfile +0 -5
- data/README.md +6 -4
- data/lib/stripe_mock/api/client.rb +1 -1
- data/lib/stripe_mock/api/webhooks.rb +65 -26
- data/lib/stripe_mock/data.rb +80 -11
- data/lib/stripe_mock/instance.rb +7 -3
- data/lib/stripe_mock/request_handlers/accounts.rb +17 -6
- data/lib/stripe_mock/request_handlers/charges.rb +25 -1
- data/lib/stripe_mock/request_handlers/checkout_session.rb +158 -1
- data/lib/stripe_mock/request_handlers/customers.rb +12 -1
- data/lib/stripe_mock/request_handlers/events.rb +30 -3
- data/lib/stripe_mock/request_handlers/helpers/coupon_helpers.rb +1 -0
- data/lib/stripe_mock/request_handlers/helpers/search_helpers.rb +67 -0
- data/lib/stripe_mock/request_handlers/helpers/subscription_helpers.rb +28 -9
- data/lib/stripe_mock/request_handlers/invoices.rb +16 -2
- data/lib/stripe_mock/request_handlers/payment_intents.rb +23 -3
- data/lib/stripe_mock/request_handlers/payment_methods.rb +5 -1
- data/lib/stripe_mock/request_handlers/prices.rb +31 -4
- data/lib/stripe_mock/request_handlers/products.rb +14 -5
- data/lib/stripe_mock/request_handlers/promotion_codes.rb +43 -0
- data/lib/stripe_mock/request_handlers/refunds.rb +13 -2
- data/lib/stripe_mock/request_handlers/setup_intents.rb +16 -9
- data/lib/stripe_mock/request_handlers/subscriptions.rb +103 -5
- data/lib/stripe_mock/request_handlers/transfers.rb +12 -1
- data/lib/stripe_mock/request_handlers/validators/param_validators.rb +5 -4
- data/lib/stripe_mock/test_strategies/base.rb +51 -24
- data/lib/stripe_mock/version.rb +1 -1
- data/lib/stripe_mock/webhook_fixtures/account.updated.json +1 -1
- data/lib/stripe_mock/webhook_fixtures/balance.available.json +26 -20
- data/lib/stripe_mock/webhook_fixtures/charge.captured.json +143 -0
- data/lib/stripe_mock/webhook_fixtures/charge.dispute.created.json +63 -16
- data/lib/stripe_mock/webhook_fixtures/charge.failed.json +49 -120
- data/lib/stripe_mock/webhook_fixtures/charge.refund.updated.json +35 -0
- data/lib/stripe_mock/webhook_fixtures/charge.refunded.json +145 -50
- data/lib/stripe_mock/webhook_fixtures/charge.succeeded.json +114 -43
- data/lib/stripe_mock/webhook_fixtures/checkout.session.completed.json +79 -0
- data/lib/stripe_mock/webhook_fixtures/checkout.session.completed.payment_mode.json +53 -0
- data/lib/stripe_mock/webhook_fixtures/checkout.session.completed.setup_mode.json +45 -0
- data/lib/stripe_mock/webhook_fixtures/customer.created.json +37 -46
- data/lib/stripe_mock/webhook_fixtures/customer.deleted.json +36 -32
- data/lib/stripe_mock/webhook_fixtures/customer.source.created.json +31 -22
- data/lib/stripe_mock/webhook_fixtures/customer.source.updated.json +36 -25
- data/lib/stripe_mock/webhook_fixtures/customer.subscription.created.json +135 -47
- data/lib/stripe_mock/webhook_fixtures/customer.subscription.deleted.json +134 -45
- data/lib/stripe_mock/webhook_fixtures/customer.subscription.updated.json +135 -56
- data/lib/stripe_mock/webhook_fixtures/customer.updated.json +38 -47
- data/lib/stripe_mock/webhook_fixtures/invoice.created.json +176 -49
- data/lib/stripe_mock/webhook_fixtures/invoice.finalized.json +171 -0
- data/lib/stripe_mock/webhook_fixtures/invoice.paid.json +171 -0
- data/lib/stripe_mock/webhook_fixtures/invoice.payment_action_required.json +171 -0
- data/lib/stripe_mock/webhook_fixtures/invoice.payment_failed.json +149 -83
- data/lib/stripe_mock/webhook_fixtures/invoice.payment_succeeded.json +149 -90
- data/lib/stripe_mock/webhook_fixtures/invoice.upcoming.json +70 -0
- data/lib/stripe_mock/webhook_fixtures/invoice.updated.json +178 -50
- data/lib/stripe_mock/webhook_fixtures/invoiceitem.created.json +87 -13
- data/lib/stripe_mock/webhook_fixtures/invoiceitem.updated.json +88 -14
- data/lib/stripe_mock/webhook_fixtures/mandate.updated.json +34 -0
- data/lib/stripe_mock/webhook_fixtures/payment_intent.amount_capturable_updated.json +170 -0
- data/lib/stripe_mock/webhook_fixtures/payment_intent.canceled.json +73 -0
- data/lib/stripe_mock/webhook_fixtures/payment_intent.created.json +86 -0
- data/lib/stripe_mock/webhook_fixtures/payment_intent.payment_failed.json +118 -79
- data/lib/stripe_mock/webhook_fixtures/payment_intent.processing.json +162 -0
- data/lib/stripe_mock/webhook_fixtures/payment_intent.requires_action.json +191 -0
- data/lib/stripe_mock/webhook_fixtures/payment_intent.succeeded.json +85 -53
- data/lib/stripe_mock/webhook_fixtures/payment_link.created.json +47 -0
- data/lib/stripe_mock/webhook_fixtures/payment_link.updated.json +50 -0
- data/lib/stripe_mock/webhook_fixtures/payment_method.attached.json +63 -0
- data/lib/stripe_mock/webhook_fixtures/payment_method.detached.json +62 -0
- data/lib/stripe_mock/webhook_fixtures/payout.created.json +40 -0
- data/lib/stripe_mock/webhook_fixtures/payout.paid.json +40 -0
- data/lib/stripe_mock/webhook_fixtures/payout.updated.json +46 -0
- data/lib/stripe_mock/webhook_fixtures/plan.created.json +30 -13
- data/lib/stripe_mock/webhook_fixtures/plan.deleted.json +30 -13
- data/lib/stripe_mock/webhook_fixtures/plan.updated.json +34 -14
- data/lib/stripe_mock/webhook_fixtures/price.created.json +42 -0
- data/lib/stripe_mock/webhook_fixtures/price.deleted.json +42 -0
- data/lib/stripe_mock/webhook_fixtures/price.updated.json +48 -0
- data/lib/stripe_mock/webhook_fixtures/product.created.json +19 -13
- data/lib/stripe_mock/webhook_fixtures/product.deleted.json +20 -14
- data/lib/stripe_mock/webhook_fixtures/product.updated.json +24 -15
- data/lib/stripe_mock/webhook_fixtures/quote.accepted.json +92 -0
- data/lib/stripe_mock/webhook_fixtures/quote.canceled.json +92 -0
- data/lib/stripe_mock/webhook_fixtures/quote.created.json +92 -0
- data/lib/stripe_mock/webhook_fixtures/quote.finalized.json +92 -0
- data/lib/stripe_mock/webhook_fixtures/setup_intent.canceled.json +46 -0
- data/lib/stripe_mock/webhook_fixtures/setup_intent.created.json +51 -0
- data/lib/stripe_mock/webhook_fixtures/setup_intent.setup_failed.json +100 -0
- data/lib/stripe_mock/webhook_fixtures/setup_intent.succeeded.json +46 -0
- data/lib/stripe_mock/webhook_fixtures/subscription_schedule.canceled.json +119 -0
- data/lib/stripe_mock/webhook_fixtures/subscription_schedule.created.json +114 -0
- data/lib/stripe_mock/webhook_fixtures/subscription_schedule.released.json +111 -0
- data/lib/stripe_mock/webhook_fixtures/subscription_schedule.updated.json +125 -0
- data/lib/stripe_mock/webhook_fixtures/tax_rate.created.json +32 -0
- data/lib/stripe_mock/webhook_fixtures/tax_rate.updated.json +37 -0
- data/lib/stripe_mock.rb +4 -1
- data/spec/instance_spec.rb +3 -1
- data/spec/integration_examples/completing_checkout_sessions_example.rb +37 -0
- data/spec/readme_spec.rb +1 -1
- data/spec/shared_stripe_examples/account_examples.rb +9 -1
- data/spec/shared_stripe_examples/bank_token_examples.rb +5 -7
- data/spec/shared_stripe_examples/charge_examples.rb +97 -0
- data/spec/shared_stripe_examples/checkout_session_examples.rb +99 -0
- data/spec/shared_stripe_examples/customer_examples.rb +56 -0
- data/spec/shared_stripe_examples/invoice_examples.rb +107 -1
- data/spec/shared_stripe_examples/payment_intent_examples.rb +136 -0
- data/spec/shared_stripe_examples/payment_method_examples.rb +32 -27
- data/spec/shared_stripe_examples/price_examples.rb +111 -2
- data/spec/shared_stripe_examples/product_examples.rb +68 -0
- data/spec/shared_stripe_examples/promotion_code_examples.rb +68 -0
- data/spec/shared_stripe_examples/refund_examples.rb +13 -0
- data/spec/shared_stripe_examples/setup_intent_examples.rb +17 -0
- data/spec/shared_stripe_examples/subscription_examples.rb +276 -6
- data/spec/shared_stripe_examples/transfer_examples.rb +10 -1
- data/spec/shared_stripe_examples/webhook_event_examples.rb +51 -5
- data/spec/spec_helper.rb +1 -1
- data/spec/support/stripe_examples.rb +3 -1
- data/stripe-ruby-mock.gemspec +3 -4
- metadata +59 -29
- data/.travis.yml +0 -25
- data/lib/stripe_mock/request_handlers/checkout.rb +0 -15
- data/spec/shared_stripe_examples/checkout_examples.rb +0 -47
@@ -1,18 +1,18 @@
|
|
1
1
|
{
|
2
|
-
"id": "
|
2
|
+
"id": "evt_000000000000000000000000",
|
3
3
|
"object": "event",
|
4
|
-
"api_version": "
|
5
|
-
"created":
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320033,
|
6
6
|
"data": {
|
7
7
|
"object": {
|
8
|
-
"id": "
|
8
|
+
"id": "pi_000000000000000000000000",
|
9
9
|
"object": "payment_intent",
|
10
|
-
"
|
11
|
-
"amount": 900,
|
10
|
+
"amount": 2000,
|
12
11
|
"amount_capturable": 0,
|
13
|
-
"amount_received":
|
12
|
+
"amount_received": 2000,
|
14
13
|
"application": null,
|
15
14
|
"application_fee_amount": null,
|
15
|
+
"automatic_payment_methods": null,
|
16
16
|
"canceled_at": null,
|
17
17
|
"cancellation_reason": null,
|
18
18
|
"capture_method": "automatic",
|
@@ -20,18 +20,19 @@
|
|
20
20
|
"object": "list",
|
21
21
|
"data": [
|
22
22
|
{
|
23
|
-
"id": "
|
23
|
+
"id": "ch_000000000000000000000000",
|
24
24
|
"object": "charge",
|
25
|
-
"amount":
|
25
|
+
"amount": 2000,
|
26
|
+
"amount_captured": 2000,
|
26
27
|
"amount_refunded": 0,
|
27
28
|
"application": null,
|
28
29
|
"application_fee": null,
|
29
30
|
"application_fee_amount": null,
|
30
|
-
"balance_transaction": "
|
31
|
+
"balance_transaction": "txn_000000000000000000000000",
|
31
32
|
"billing_details": {
|
32
33
|
"address": {
|
33
34
|
"city": null,
|
34
|
-
"country":
|
35
|
+
"country": null,
|
35
36
|
"line1": null,
|
36
37
|
"line2": null,
|
37
38
|
"postal_code": null,
|
@@ -41,33 +42,36 @@
|
|
41
42
|
"name": null,
|
42
43
|
"phone": null
|
43
44
|
},
|
45
|
+
"calculated_statement_descriptor": "EXAMPLECOMPANY",
|
44
46
|
"captured": true,
|
45
|
-
"created":
|
46
|
-
"currency": "
|
47
|
-
"customer":
|
48
|
-
"description":
|
49
|
-
"destination":
|
47
|
+
"created": 1648320032,
|
48
|
+
"currency": "usd",
|
49
|
+
"customer": null,
|
50
|
+
"description": "(created by Stripe CLI)",
|
51
|
+
"destination": null,
|
50
52
|
"dispute": null,
|
51
53
|
"disputed": false,
|
52
54
|
"failure_code": null,
|
53
55
|
"failure_message": null,
|
54
|
-
"fraud_details": {
|
56
|
+
"fraud_details": {
|
57
|
+
},
|
55
58
|
"invoice": null,
|
56
59
|
"livemode": false,
|
57
|
-
"metadata": {
|
60
|
+
"metadata": {
|
61
|
+
},
|
58
62
|
"on_behalf_of": null,
|
59
63
|
"order": null,
|
60
64
|
"outcome": {
|
61
65
|
"network_status": "approved_by_network",
|
62
66
|
"reason": null,
|
63
67
|
"risk_level": "normal",
|
64
|
-
"risk_score":
|
68
|
+
"risk_score": 2,
|
65
69
|
"seller_message": "Payment complete.",
|
66
70
|
"type": "authorized"
|
67
71
|
},
|
68
72
|
"paid": true,
|
69
|
-
"payment_intent": "
|
70
|
-
"payment_method": "
|
73
|
+
"payment_intent": "pi_000000000000000000000000",
|
74
|
+
"payment_method": "pm_000000000000000000000000",
|
71
75
|
"payment_method_details": {
|
72
76
|
"card": {
|
73
77
|
"brand": "visa",
|
@@ -77,12 +81,13 @@
|
|
77
81
|
"cvc_check": null
|
78
82
|
},
|
79
83
|
"country": "US",
|
80
|
-
"exp_month":
|
81
|
-
"exp_year":
|
82
|
-
"fingerprint": "
|
84
|
+
"exp_month": 3,
|
85
|
+
"exp_year": 2023,
|
86
|
+
"fingerprint": "ZoVSX2dK5igWt2SB",
|
83
87
|
"funding": "credit",
|
84
88
|
"installments": null,
|
85
89
|
"last4": "4242",
|
90
|
+
"mandate": null,
|
86
91
|
"network": "visa",
|
87
92
|
"three_d_secure": null,
|
88
93
|
"wallet": null
|
@@ -91,74 +96,101 @@
|
|
91
96
|
},
|
92
97
|
"receipt_email": null,
|
93
98
|
"receipt_number": null,
|
94
|
-
"receipt_url": "https://pay.stripe.com/receipts/
|
99
|
+
"receipt_url": "https://pay.stripe.com/receipts/acct_0000000000000000/ch_000000000000000000000000/rcpt_0000000000000000000000000000000",
|
95
100
|
"refunded": false,
|
96
101
|
"refunds": {
|
97
102
|
"object": "list",
|
98
|
-
"data": [
|
103
|
+
"data": [
|
104
|
+
|
105
|
+
],
|
99
106
|
"has_more": false,
|
100
107
|
"total_count": 0,
|
101
|
-
"url": "/v1/charges/
|
108
|
+
"url": "/v1/charges/ch_000000000000000000000000/refunds"
|
102
109
|
},
|
103
110
|
"review": null,
|
104
|
-
"shipping":
|
111
|
+
"shipping": {
|
112
|
+
"address": {
|
113
|
+
"city": "San Francisco",
|
114
|
+
"country": "US",
|
115
|
+
"line1": "510 Townsend St",
|
116
|
+
"line2": null,
|
117
|
+
"postal_code": "94103",
|
118
|
+
"state": "CA"
|
119
|
+
},
|
120
|
+
"carrier": null,
|
121
|
+
"name": "Jenny Rosen",
|
122
|
+
"phone": null,
|
123
|
+
"tracking_number": null
|
124
|
+
},
|
105
125
|
"source": null,
|
106
126
|
"source_transfer": null,
|
107
|
-
"statement_descriptor":
|
127
|
+
"statement_descriptor": null,
|
108
128
|
"statement_descriptor_suffix": null,
|
109
129
|
"status": "succeeded",
|
110
|
-
"
|
111
|
-
"
|
112
|
-
"amount": null,
|
113
|
-
"destination": "acct_00000000000000"
|
114
|
-
},
|
115
|
-
"transfer_group": "group_pi_00000000000000"
|
130
|
+
"transfer_data": null,
|
131
|
+
"transfer_group": null
|
116
132
|
}
|
117
133
|
],
|
118
134
|
"has_more": false,
|
119
135
|
"total_count": 1,
|
120
|
-
"url": "/v1/charges?payment_intent=
|
136
|
+
"url": "/v1/charges?payment_intent=pi_000000000000000000000000"
|
121
137
|
},
|
122
|
-
"client_secret": "
|
138
|
+
"client_secret": "pi_000000000000000000000000_secret_0000000000000000000000000",
|
123
139
|
"confirmation_method": "automatic",
|
124
|
-
"created":
|
125
|
-
"currency": "
|
126
|
-
"customer":
|
127
|
-
"description":
|
140
|
+
"created": 1648320032,
|
141
|
+
"currency": "usd",
|
142
|
+
"customer": null,
|
143
|
+
"description": "(created by Stripe CLI)",
|
128
144
|
"invoice": null,
|
129
145
|
"last_payment_error": null,
|
130
146
|
"livemode": false,
|
131
|
-
"metadata": {
|
147
|
+
"metadata": {
|
148
|
+
},
|
132
149
|
"next_action": null,
|
133
|
-
"next_source_action": null,
|
134
150
|
"on_behalf_of": null,
|
135
|
-
"payment_method": "
|
151
|
+
"payment_method": "pm_000000000000000000000000",
|
136
152
|
"payment_method_options": {
|
137
153
|
"card": {
|
138
154
|
"installments": null,
|
155
|
+
"mandate_options": null,
|
156
|
+
"network": null,
|
139
157
|
"request_three_d_secure": "automatic"
|
140
158
|
}
|
141
159
|
},
|
142
|
-
"payment_method_types": [
|
160
|
+
"payment_method_types": [
|
161
|
+
"card"
|
162
|
+
],
|
163
|
+
"processing": null,
|
143
164
|
"receipt_email": null,
|
144
165
|
"review": null,
|
145
166
|
"setup_future_usage": null,
|
146
|
-
"shipping":
|
167
|
+
"shipping": {
|
168
|
+
"address": {
|
169
|
+
"city": "San Francisco",
|
170
|
+
"country": "US",
|
171
|
+
"line1": "510 Townsend St",
|
172
|
+
"line2": null,
|
173
|
+
"postal_code": "94103",
|
174
|
+
"state": "CA"
|
175
|
+
},
|
176
|
+
"carrier": null,
|
177
|
+
"name": "Jenny Rosen",
|
178
|
+
"phone": null,
|
179
|
+
"tracking_number": null
|
180
|
+
},
|
147
181
|
"source": null,
|
148
|
-
"statement_descriptor":
|
182
|
+
"statement_descriptor": null,
|
149
183
|
"statement_descriptor_suffix": null,
|
150
184
|
"status": "succeeded",
|
151
|
-
"transfer_data":
|
152
|
-
|
153
|
-
},
|
154
|
-
"transfer_group": "group_pi_00000000000000"
|
185
|
+
"transfer_data": null,
|
186
|
+
"transfer_group": null
|
155
187
|
}
|
156
188
|
},
|
157
189
|
"livemode": false,
|
158
190
|
"pending_webhooks": 2,
|
159
191
|
"request": {
|
160
192
|
"id": "req_00000000000000",
|
161
|
-
"idempotency_key":
|
193
|
+
"idempotency_key": "7143a956-2f40-407a-b312-43038ae76c86"
|
162
194
|
},
|
163
195
|
"type": "payment_intent.succeeded"
|
164
|
-
}
|
196
|
+
}
|
@@ -0,0 +1,47 @@
|
|
1
|
+
{
|
2
|
+
"id": "evt_000000000000000000000000",
|
3
|
+
"object": "event",
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320037,
|
6
|
+
"data": {
|
7
|
+
"object": {
|
8
|
+
"id": "plink_000000000000000000000000",
|
9
|
+
"object": "payment_link",
|
10
|
+
"active": true,
|
11
|
+
"after_completion": {
|
12
|
+
"hosted_confirmation": {
|
13
|
+
"custom_message": null
|
14
|
+
},
|
15
|
+
"type": "hosted_confirmation"
|
16
|
+
},
|
17
|
+
"allow_promotion_codes": false,
|
18
|
+
"application_fee_amount": null,
|
19
|
+
"application_fee_percent": null,
|
20
|
+
"automatic_tax": {
|
21
|
+
"enabled": false
|
22
|
+
},
|
23
|
+
"billing_address_collection": "auto",
|
24
|
+
"livemode": false,
|
25
|
+
"metadata": {
|
26
|
+
},
|
27
|
+
"on_behalf_of": null,
|
28
|
+
"payment_method_types": null,
|
29
|
+
"phone_number_collection": {
|
30
|
+
"enabled": false
|
31
|
+
},
|
32
|
+
"shipping_address_collection": null,
|
33
|
+
"subscription_data": {
|
34
|
+
"trial_period_days": null
|
35
|
+
},
|
36
|
+
"transfer_data": null,
|
37
|
+
"url": "https://buy.stripe.com/test_000000000000000000"
|
38
|
+
}
|
39
|
+
},
|
40
|
+
"livemode": false,
|
41
|
+
"pending_webhooks": 2,
|
42
|
+
"request": {
|
43
|
+
"id": "req_00000000000000",
|
44
|
+
"idempotency_key": "753b9128-4591-4a12-9392-86732e352266"
|
45
|
+
},
|
46
|
+
"type": "payment_link.created"
|
47
|
+
}
|
@@ -0,0 +1,50 @@
|
|
1
|
+
{
|
2
|
+
"id": "evt_000000000000000000000000",
|
3
|
+
"object": "event",
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320038,
|
6
|
+
"data": {
|
7
|
+
"object": {
|
8
|
+
"id": "plink_000000000000000000000000",
|
9
|
+
"object": "payment_link",
|
10
|
+
"active": true,
|
11
|
+
"after_completion": {
|
12
|
+
"hosted_confirmation": {
|
13
|
+
"custom_message": null
|
14
|
+
},
|
15
|
+
"type": "hosted_confirmation"
|
16
|
+
},
|
17
|
+
"allow_promotion_codes": true,
|
18
|
+
"application_fee_amount": null,
|
19
|
+
"application_fee_percent": null,
|
20
|
+
"automatic_tax": {
|
21
|
+
"enabled": false
|
22
|
+
},
|
23
|
+
"billing_address_collection": "auto",
|
24
|
+
"livemode": false,
|
25
|
+
"metadata": {
|
26
|
+
},
|
27
|
+
"on_behalf_of": null,
|
28
|
+
"payment_method_types": null,
|
29
|
+
"phone_number_collection": {
|
30
|
+
"enabled": false
|
31
|
+
},
|
32
|
+
"shipping_address_collection": null,
|
33
|
+
"subscription_data": {
|
34
|
+
"trial_period_days": null
|
35
|
+
},
|
36
|
+
"transfer_data": null,
|
37
|
+
"url": "https://buy.stripe.com/test_000000000000000000"
|
38
|
+
},
|
39
|
+
"previous_attributes": {
|
40
|
+
"allow_promotion_codes": false
|
41
|
+
}
|
42
|
+
},
|
43
|
+
"livemode": false,
|
44
|
+
"pending_webhooks": 2,
|
45
|
+
"request": {
|
46
|
+
"id": "req_00000000000000",
|
47
|
+
"idempotency_key": "81dafec6-4d31-4bc8-b45b-0ab21772c793"
|
48
|
+
},
|
49
|
+
"type": "payment_link.updated"
|
50
|
+
}
|
@@ -0,0 +1,63 @@
|
|
1
|
+
{
|
2
|
+
"id": "evt_000000000000000000000000",
|
3
|
+
"object": "event",
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320107,
|
6
|
+
"data": {
|
7
|
+
"object": {
|
8
|
+
"id": "card_000000000000000000000000",
|
9
|
+
"object": "payment_method",
|
10
|
+
"billing_details": {
|
11
|
+
"address": {
|
12
|
+
"city": null,
|
13
|
+
"country": null,
|
14
|
+
"line1": null,
|
15
|
+
"line2": null,
|
16
|
+
"postal_code": null,
|
17
|
+
"state": null
|
18
|
+
},
|
19
|
+
"email": null,
|
20
|
+
"name": null,
|
21
|
+
"phone": null
|
22
|
+
},
|
23
|
+
"card": {
|
24
|
+
"brand": "visa",
|
25
|
+
"checks": {
|
26
|
+
"address_line1_check": null,
|
27
|
+
"address_postal_code_check": null,
|
28
|
+
"cvc_check": null
|
29
|
+
},
|
30
|
+
"country": "US",
|
31
|
+
"exp_month": 3,
|
32
|
+
"exp_year": 2023,
|
33
|
+
"fingerprint": "ZoVSX2dK5igWt2SB",
|
34
|
+
"funding": "credit",
|
35
|
+
"generated_from": null,
|
36
|
+
"last4": "4242",
|
37
|
+
"networks": {
|
38
|
+
"available": [
|
39
|
+
"visa"
|
40
|
+
],
|
41
|
+
"preferred": null
|
42
|
+
},
|
43
|
+
"three_d_secure_usage": {
|
44
|
+
"supported": true
|
45
|
+
},
|
46
|
+
"wallet": null
|
47
|
+
},
|
48
|
+
"created": 1648320107,
|
49
|
+
"customer": "cus_00000000000000",
|
50
|
+
"livemode": false,
|
51
|
+
"metadata": {
|
52
|
+
},
|
53
|
+
"type": "card"
|
54
|
+
}
|
55
|
+
},
|
56
|
+
"livemode": false,
|
57
|
+
"pending_webhooks": 2,
|
58
|
+
"request": {
|
59
|
+
"id": "req_00000000000000",
|
60
|
+
"idempotency_key": "381c7773-97ac-4c18-8fbe-e8bff5e6bbad"
|
61
|
+
},
|
62
|
+
"type": "payment_method.attached"
|
63
|
+
}
|
@@ -0,0 +1,62 @@
|
|
1
|
+
{
|
2
|
+
"id": "evt_000000000000000000000000",
|
3
|
+
"object": "event",
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320107,
|
6
|
+
"data": {
|
7
|
+
"object": {
|
8
|
+
"id" : "pm_000000000000000000000000",
|
9
|
+
"object" : "payment_method",
|
10
|
+
"created" : 1678559798,
|
11
|
+
"billing_details" : {
|
12
|
+
"address" : {
|
13
|
+
"city" : null,
|
14
|
+
"country" : "US",
|
15
|
+
"line1" : null,
|
16
|
+
"line2" : null,
|
17
|
+
"postal_code" : "42424",
|
18
|
+
"state" : null
|
19
|
+
},
|
20
|
+
"email" : null,
|
21
|
+
"name" : null,
|
22
|
+
"phone" : null
|
23
|
+
},
|
24
|
+
"card" : {
|
25
|
+
"brand" : "visa",
|
26
|
+
"checks" : {
|
27
|
+
"address_line1_check" : null,
|
28
|
+
"address_postal_code_check" : "pass",
|
29
|
+
"cvc_check" : "pass"
|
30
|
+
},
|
31
|
+
"country" : "US",
|
32
|
+
"exp_month" : 4,
|
33
|
+
"exp_year" : 2024,
|
34
|
+
"fingerprint" : "ZoVSX2dK5igWt2SB",
|
35
|
+
"funding" : "credit",
|
36
|
+
"generated_from" : null,
|
37
|
+
"last4" : "4242",
|
38
|
+
"networks" : {
|
39
|
+
"available" : [
|
40
|
+
"visa"
|
41
|
+
],
|
42
|
+
"preferred" : null
|
43
|
+
},
|
44
|
+
"three_d_secure_usage" : {
|
45
|
+
"supported" : true
|
46
|
+
},
|
47
|
+
"wallet" : null
|
48
|
+
},
|
49
|
+
"customer" : null,
|
50
|
+
"livemode" : false,
|
51
|
+
"metadata" : {},
|
52
|
+
"type" : "card"
|
53
|
+
}
|
54
|
+
},
|
55
|
+
"livemode": false,
|
56
|
+
"pending_webhooks": 2,
|
57
|
+
"request": {
|
58
|
+
"id": "req_00000000000000",
|
59
|
+
"idempotency_key": "381c7773-97ac-4c18-8fbe-e8bff5e6bbad"
|
60
|
+
},
|
61
|
+
"type": "payment_method.detached"
|
62
|
+
}
|
@@ -0,0 +1,40 @@
|
|
1
|
+
{
|
2
|
+
"id": "evt_000000000000000000000000",
|
3
|
+
"object": "event",
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320045,
|
6
|
+
"data": {
|
7
|
+
"object": {
|
8
|
+
"id": "po_000000000000000000000000",
|
9
|
+
"object": "payout",
|
10
|
+
"amount": 1100,
|
11
|
+
"arrival_date": 1648425600,
|
12
|
+
"automatic": false,
|
13
|
+
"balance_transaction": "txn_000000000000000000000000",
|
14
|
+
"created": 1648320044,
|
15
|
+
"currency": "usd",
|
16
|
+
"description": "(created by Stripe CLI)",
|
17
|
+
"destination": "ba_000000000000000000000000",
|
18
|
+
"failure_balance_transaction": null,
|
19
|
+
"failure_code": null,
|
20
|
+
"failure_message": null,
|
21
|
+
"livemode": false,
|
22
|
+
"metadata": {
|
23
|
+
},
|
24
|
+
"method": "standard",
|
25
|
+
"original_payout": null,
|
26
|
+
"reversed_by": null,
|
27
|
+
"source_type": "card",
|
28
|
+
"statement_descriptor": null,
|
29
|
+
"status": "paid",
|
30
|
+
"type": "bank_account"
|
31
|
+
}
|
32
|
+
},
|
33
|
+
"livemode": false,
|
34
|
+
"pending_webhooks": 2,
|
35
|
+
"request": {
|
36
|
+
"id": "req_00000000000000",
|
37
|
+
"idempotency_key": "ae68e2e7-0edb-4181-a35f-f36dcc9148c9"
|
38
|
+
},
|
39
|
+
"type": "payout.created"
|
40
|
+
}
|
@@ -0,0 +1,40 @@
|
|
1
|
+
{
|
2
|
+
"id": "evt_000000000000000000000000",
|
3
|
+
"object": "event",
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320045,
|
6
|
+
"data": {
|
7
|
+
"object": {
|
8
|
+
"id": "po_000000000000000000000000",
|
9
|
+
"object": "payout",
|
10
|
+
"amount": 1100,
|
11
|
+
"arrival_date": 1648425600,
|
12
|
+
"automatic": false,
|
13
|
+
"balance_transaction": "txn_000000000000000000000000",
|
14
|
+
"created": 1648320044,
|
15
|
+
"currency": "usd",
|
16
|
+
"description": "(created by Stripe CLI)",
|
17
|
+
"destination": "ba_000000000000000000000000",
|
18
|
+
"failure_balance_transaction": null,
|
19
|
+
"failure_code": null,
|
20
|
+
"failure_message": null,
|
21
|
+
"livemode": false,
|
22
|
+
"metadata": {
|
23
|
+
},
|
24
|
+
"method": "standard",
|
25
|
+
"original_payout": null,
|
26
|
+
"reversed_by": null,
|
27
|
+
"source_type": "card",
|
28
|
+
"statement_descriptor": null,
|
29
|
+
"status": "paid",
|
30
|
+
"type": "bank_account"
|
31
|
+
}
|
32
|
+
},
|
33
|
+
"livemode": false,
|
34
|
+
"pending_webhooks": 2,
|
35
|
+
"request": {
|
36
|
+
"id": "req_00000000000000",
|
37
|
+
"idempotency_key": "ae68e2e7-0edb-4181-a35f-f36dcc9148c9"
|
38
|
+
},
|
39
|
+
"type": "payout.paid"
|
40
|
+
}
|
@@ -0,0 +1,46 @@
|
|
1
|
+
{
|
2
|
+
"id": "evt_000000000000000000000000",
|
3
|
+
"object": "event",
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320046,
|
6
|
+
"data": {
|
7
|
+
"object": {
|
8
|
+
"id": "po_000000000000000000000000",
|
9
|
+
"object": "payout",
|
10
|
+
"amount": 1100,
|
11
|
+
"arrival_date": 1648425600,
|
12
|
+
"automatic": false,
|
13
|
+
"balance_transaction": "txn_000000000000000000000000",
|
14
|
+
"created": 1648320044,
|
15
|
+
"currency": "usd",
|
16
|
+
"description": "(created by Stripe CLI)",
|
17
|
+
"destination": "ba_000000000000000000000000",
|
18
|
+
"failure_balance_transaction": null,
|
19
|
+
"failure_code": null,
|
20
|
+
"failure_message": null,
|
21
|
+
"livemode": false,
|
22
|
+
"metadata": {
|
23
|
+
"foo": "bar"
|
24
|
+
},
|
25
|
+
"method": "standard",
|
26
|
+
"original_payout": null,
|
27
|
+
"reversed_by": null,
|
28
|
+
"source_type": "card",
|
29
|
+
"statement_descriptor": null,
|
30
|
+
"status": "paid",
|
31
|
+
"type": "bank_account"
|
32
|
+
},
|
33
|
+
"previous_attributes": {
|
34
|
+
"metadata": {
|
35
|
+
"foo": null
|
36
|
+
}
|
37
|
+
}
|
38
|
+
},
|
39
|
+
"livemode": false,
|
40
|
+
"pending_webhooks": 2,
|
41
|
+
"request": {
|
42
|
+
"id": "req_00000000000000",
|
43
|
+
"idempotency_key": "0d30bd53-9777-49de-8893-882fd2914757"
|
44
|
+
},
|
45
|
+
"type": "payout.updated"
|
46
|
+
}
|
@@ -1,20 +1,37 @@
|
|
1
1
|
{
|
2
|
-
"
|
3
|
-
"livemode": false,
|
4
|
-
"id": "evt_00000000000000",
|
5
|
-
"type": "plan.created",
|
2
|
+
"id": "evt_000000000000000000000000",
|
6
3
|
"object": "event",
|
4
|
+
"api_version": "2020-08-27",
|
5
|
+
"created": 1648320109,
|
7
6
|
"data": {
|
8
7
|
"object": {
|
9
|
-
"
|
10
|
-
"product": "pr_00000000000000",
|
11
|
-
"amount": 100,
|
12
|
-
"currency": "usd",
|
13
|
-
"id": "fkx0AFo_00000000000000",
|
8
|
+
"id": "price_000000000000000000000000",
|
14
9
|
"object": "plan",
|
15
|
-
"
|
10
|
+
"active": true,
|
11
|
+
"aggregate_usage": null,
|
12
|
+
"amount": 1500,
|
13
|
+
"amount_decimal": "1500",
|
14
|
+
"billing_scheme": "per_unit",
|
15
|
+
"created": 1648320109,
|
16
|
+
"currency": "usd",
|
17
|
+
"interval": "month",
|
16
18
|
"interval_count": 1,
|
17
|
-
"
|
19
|
+
"livemode": false,
|
20
|
+
"metadata": {
|
21
|
+
},
|
22
|
+
"nickname": null,
|
23
|
+
"product": "prod_00000000000000",
|
24
|
+
"tiers_mode": null,
|
25
|
+
"transform_usage": null,
|
26
|
+
"trial_period_days": null,
|
27
|
+
"usage_type": "licensed"
|
18
28
|
}
|
19
|
-
}
|
20
|
-
|
29
|
+
},
|
30
|
+
"livemode": false,
|
31
|
+
"pending_webhooks": 2,
|
32
|
+
"request": {
|
33
|
+
"id": "req_00000000000000",
|
34
|
+
"idempotency_key": "64c22132-7234-47d6-a803-4e34ac0e883b"
|
35
|
+
},
|
36
|
+
"type": "plan.created"
|
37
|
+
}
|