Skip to content

Commit 1f8362e

Browse files
committed
Add payment_intent.canceled fixture
1 parent 4fae19d commit 1f8362e

File tree

2 files changed

+69
-0
lines changed

2 files changed

+69
-0
lines changed

lib/stripe_mock/api/webhooks.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ def self.event_list
7474
'invoiceitem.created',
7575
'invoiceitem.updated',
7676
'invoiceitem.deleted',
77+
'payment_intent.canceled',
7778
'payment_intent.processing',
7879
'payment_intent.succeeded',
7980
'payment_intent.payment_failed',
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
{
2+
"id": "evt_00000000000000",
3+
"object": "event",
4+
"api_version": "2018-02-28",
5+
"created": 1578499109,
6+
"data": {
7+
"object": {
8+
"id": "pi_00000000000000",
9+
"object": "payment_intent",
10+
"amount": 900,
11+
"amount_capturable": 0,
12+
"amount_received": 0,
13+
"application": null,
14+
"application_fee_amount": null,
15+
"canceled_at": 1578499109,
16+
"cancellation_reason": null,
17+
"capture_method": "automatic",
18+
"charges": {
19+
"object": "list",
20+
"data": [],
21+
"has_more": false,
22+
"total_count": 0,
23+
"url": "/v1/charges?payment_intent=pi_00000000000000"
24+
},
25+
"client_secret": "pi_00000000000000",
26+
"confirmation_method": "automatic",
27+
"created": 1578499108,
28+
"currency": "eur",
29+
"customer": "cus_00000000000000",
30+
"description": null,
31+
"invoice": null,
32+
"last_payment_error": null,
33+
"livemode": false,
34+
"metadata": {},
35+
"next_action": null,
36+
"on_behalf_of": null,
37+
"payment_method": "pm_00000000000000",
38+
"payment_method_options": {
39+
"card": {
40+
"installments": null,
41+
"network": null,
42+
"request_three_d_secure": "automatic"
43+
}
44+
},
45+
"payment_method_types": [
46+
"card",
47+
"sepa_debit"
48+
],
49+
"receipt_email": null,
50+
"review": null,
51+
"setup_future_usage": null,
52+
"shipping": null,
53+
"source": null,
54+
"statement_descriptor": null,
55+
"statement_descriptor_suffix": null,
56+
"status": "canceled",
57+
"transfer_data": null,
58+
"transfer_group": null
59+
}
60+
},
61+
"livemode": false,
62+
"pending_webhooks": 2,
63+
"request": {
64+
"id": "req_00000000000000",
65+
"idempotency_key": null
66+
},
67+
"type": "payment_intent.canceled"
68+
}

0 commit comments

Comments
 (0)