1 | <?php |
||
21 | final class PaymentIntent implements CreatableFromArray, ContainsMetadata |
||
22 | { |
||
23 | use LivemodeTrait, MetadataTrait; |
||
24 | |||
25 | const CAPTURE_METHOD_AUTOMATIC = 'automatic'; |
||
26 | const CAPTURE_METHOD_MANUAL = 'manual'; |
||
27 | |||
28 | const CONFIRMATION_METHOD_AUTOMATIC = 'automatic'; |
||
29 | const CONFIRMATION_METHOD_MANUAL = 'manual'; |
||
30 | |||
31 | const STATUS_REQUIRES_PAYMENT_METHOD = 'requires_payment_method'; |
||
32 | const STATUS_REQUIRES_CONFIRMATION = 'requires_confirmation'; |
||
33 | const STATUS_REQUIRES_ACTION = 'requires_action'; |
||
34 | const STATUS_PROCESSING = 'processing'; |
||
35 | const STATUS_REQUIRES_CAPTURE = 'requires_capture'; |
||
36 | const STATUS_CANCELED = 'canceled'; |
||
37 | const STATUS_SUCCEEDED = 'succeeded'; |
||
38 | |||
39 | /** |
||
40 | * @var ?string |
||
41 | */ |
||
42 | private $id; |
||
43 | |||
44 | /** |
||
45 | * @var Money |
||
46 | */ |
||
47 | private $amount; |
||
48 | |||
49 | /** |
||
50 | * @var Money |
||
51 | */ |
||
52 | private $amountCapturable; |
||
53 | |||
54 | /** |
||
55 | * @var Money |
||
56 | */ |
||
57 | private $amountReceived; |
||
58 | |||
59 | /** |
||
60 | * @var ?string |
||
61 | */ |
||
62 | private $applicationId; |
||
63 | |||
64 | /** |
||
65 | * @var ?Money |
||
66 | */ |
||
67 | private $applicationFeeAmount; |
||
68 | |||
69 | /** |
||
70 | * @var ?\DateTimeImmutable |
||
71 | */ |
||
72 | private $canceledAt; |
||
73 | |||
74 | /** |
||
75 | * @var ?string |
||
76 | */ |
||
77 | private $cancellationReason; |
||
78 | |||
79 | /** |
||
80 | * @var string |
||
81 | */ |
||
82 | private $captureMethod; |
||
83 | |||
84 | /** |
||
85 | * @var ChargeCollection |
||
86 | */ |
||
87 | private $charges; |
||
88 | |||
89 | /** |
||
90 | * @var string |
||
91 | */ |
||
92 | private $clientSecret; |
||
93 | |||
94 | /** |
||
95 | * @var string |
||
96 | */ |
||
97 | private $confirmationMethod; |
||
98 | |||
99 | /** |
||
100 | * @var \DateTimeImmutable |
||
101 | */ |
||
102 | private $createdAt; |
||
103 | |||
104 | /** |
||
105 | * @var Currency |
||
106 | */ |
||
107 | private $currency; |
||
108 | |||
109 | /** |
||
110 | * @var string |
||
111 | */ |
||
112 | private $customerId; |
||
113 | |||
114 | /** |
||
115 | * @var string |
||
116 | */ |
||
117 | private $description; |
||
118 | |||
119 | /** |
||
120 | * @var string |
||
121 | */ |
||
122 | private $invoiceId; |
||
123 | |||
124 | /** |
||
125 | * @var ?LastPaymentError |
||
126 | */ |
||
127 | private $lastPaymentError; |
||
128 | |||
129 | /** |
||
130 | * @var ?NextAction |
||
131 | */ |
||
132 | private $nextAction; |
||
133 | |||
134 | /** |
||
135 | * @var ?string |
||
136 | */ |
||
137 | private $onBehalfOfId; |
||
138 | |||
139 | /** |
||
140 | * @var ?string |
||
141 | */ |
||
142 | private $paymentMethodId; |
||
143 | |||
144 | /** |
||
145 | * @var array |
||
146 | */ |
||
147 | private $paymentMethodTypes; |
||
148 | |||
149 | /** |
||
150 | * @var ?string |
||
151 | */ |
||
152 | private $receiptEmail; |
||
153 | |||
154 | /** |
||
155 | * @var ?string |
||
156 | */ |
||
157 | private $reviewId; |
||
158 | |||
159 | /** |
||
160 | * @var ?Shipping |
||
161 | */ |
||
162 | private $shipping; |
||
163 | |||
164 | /** |
||
165 | * @var ?string |
||
166 | */ |
||
167 | private $statementDescriptor; |
||
168 | |||
169 | /** |
||
170 | * @var string |
||
171 | */ |
||
172 | private $status; |
||
173 | |||
174 | /** |
||
175 | * @var ?TransferData |
||
176 | */ |
||
177 | private $transferData; |
||
178 | |||
179 | /** |
||
180 | * @var ?string |
||
181 | */ |
||
182 | private $transferGroup; |
||
183 | |||
184 | 2 | public static function createFromArray(array $data): self |
|
222 | |||
223 | 1 | public function getId(): string |
|
227 | |||
228 | 1 | public function getAmount(): Money |
|
232 | |||
233 | 1 | public function getAmountCapturable(): Money |
|
237 | |||
238 | 1 | public function getAmountReceived(): Money |
|
242 | |||
243 | 1 | public function getApplicationId(): ?string |
|
247 | |||
248 | 1 | public function getApplicationFeeAmount(): ?Money |
|
252 | |||
253 | 1 | public function getCanceledAt(): \DateTimeInterface |
|
257 | |||
258 | 1 | public function getCancellationReason(): ?string |
|
262 | |||
263 | 1 | public function getCaptureMethod(): string |
|
267 | |||
268 | 1 | public function getCharges(): ChargeCollection |
|
272 | |||
273 | 1 | public function getClientSecret(): string |
|
277 | |||
278 | 1 | public function getConfirmationMethod(): string |
|
282 | |||
283 | 1 | public function getCreatedAt(): \DateTimeInterface |
|
287 | |||
288 | 1 | public function getCurrency(): Currency |
|
292 | |||
293 | 1 | public function getCustomerId(): ?string |
|
297 | |||
298 | 1 | public function getDescription(): ?string |
|
302 | |||
303 | 1 | public function getInvoiceId(): ?string |
|
307 | |||
308 | 1 | public function getLastPaymentError(): ?LastPaymentError |
|
312 | |||
313 | 1 | public function getNextAction(): ?NextAction |
|
317 | |||
318 | 1 | public function getOnBehalfOfId(): ?string |
|
322 | |||
323 | 1 | public function getPaymentMethodId(): ?string |
|
327 | |||
328 | 1 | public function getPaymentMethodTypes(): array |
|
332 | |||
333 | 1 | public function getReceiptEmail(): ?string |
|
337 | |||
338 | 1 | public function getReviewId(): ?string |
|
342 | |||
343 | 1 | public function getShipping(): ?Shipping |
|
347 | |||
348 | 1 | public function getStatementDescriptor(): ?string |
|
352 | |||
353 | 1 | public function getStatus(): string |
|
357 | |||
358 | 1 | public function getTransferData(): ?TransferData |
|
362 | |||
363 | 1 | public function getTransferGroup(): ?string |
|
367 | } |
||
368 |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..