• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

stripe / stripe-java / #16565

23 Oct 2024 03:40AM CUT coverage: 12.56% (-0.05%) from 12.614%
#16565

Pull #1904

github

web-flow
Merge 52e2b4eac into 017594900
Pull Request #1904: Update generated code for beta

12 of 735 new or added lines in 34 files covered. (1.63%)

12 existing lines in 12 files now uncovered.

18810 of 149761 relevant lines covered (12.56%)

0.13 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/main/java/com/stripe/model/ConfirmationToken.java
1
// File generated from our OpenAPI spec
2
package com.stripe.model;
3

4
import com.google.gson.annotations.SerializedName;
5
import com.stripe.exception.StripeException;
6
import com.stripe.net.ApiRequest;
7
import com.stripe.net.ApiRequestParams;
8
import com.stripe.net.ApiResource;
9
import com.stripe.net.BaseAddress;
10
import com.stripe.net.RequestOptions;
11
import com.stripe.net.StripeResponseGetter;
12
import com.stripe.param.ConfirmationTokenCreateParams;
13
import com.stripe.param.ConfirmationTokenRetrieveParams;
14
import java.util.List;
15
import java.util.Map;
16
import lombok.EqualsAndHashCode;
17
import lombok.Getter;
18
import lombok.Setter;
19

20
/**
21
 * ConfirmationTokens help transport client side data collected by Stripe JS over to your server for
22
 * confirming a PaymentIntent or SetupIntent. If the confirmation is successful, values present on
23
 * the ConfirmationToken are written onto the Intent.
24
 *
25
 * <p>To learn more about how to use ConfirmationToken, visit the related guides: - <a
26
 * href="https://stripe.com/docs/payments/finalize-payments-on-the-server">Finalize payments on the
27
 * server</a> - <a href="https://stripe.com/docs/payments/build-a-two-step-confirmation">Build
28
 * two-step confirmation</a>.
29
 */
30
@Getter
31
@Setter
32
@EqualsAndHashCode(callSuper = false)
33
public class ConfirmationToken extends ApiResource implements HasId {
×
34
  /** Time at which the object was created. Measured in seconds since the Unix epoch. */
35
  @SerializedName("created")
36
  Long created;
37

38
  /**
39
   * Time at which this ConfirmationToken expires and can no longer be used to confirm a
40
   * PaymentIntent or SetupIntent.
41
   */
42
  @SerializedName("expires_at")
43
  Long expiresAt;
44

45
  /** Unique identifier for the object. */
46
  @Getter(onMethod_ = {@Override})
47
  @SerializedName("id")
48
  String id;
49

50
  /**
51
   * Has the value {@code true} if the object exists in live mode or the value {@code false} if the
52
   * object exists in test mode.
53
   */
54
  @SerializedName("livemode")
55
  Boolean livemode;
56

57
  /** Data used for generating a Mandate. */
58
  @SerializedName("mandate_data")
59
  MandateData mandateData;
60

61
  /**
62
   * String representing the object's type. Objects of the same type share the same value.
63
   *
64
   * <p>Equal to {@code confirmation_token}.
65
   */
66
  @SerializedName("object")
67
  String object;
68

69
  /**
70
   * ID of the PaymentIntent that this ConfirmationToken was used to confirm, or null if this
71
   * ConfirmationToken has not yet been used.
72
   */
73
  @SerializedName("payment_intent")
74
  String paymentIntent;
75

76
  /** Payment-method-specific configuration for this ConfirmationToken. */
77
  @SerializedName("payment_method_options")
78
  PaymentMethodOptions paymentMethodOptions;
79

80
  /**
81
   * Payment details collected by the Payment Element, used to create a PaymentMethod when a
82
   * PaymentIntent or SetupIntent is confirmed with this ConfirmationToken.
83
   */
84
  @SerializedName("payment_method_preview")
85
  PaymentMethodPreview paymentMethodPreview;
86

87
  /** Return URL used to confirm the Intent. */
88
  @SerializedName("return_url")
89
  String returnUrl;
90

91
  /**
92
   * Indicates that you intend to make future payments with this ConfirmationToken's payment method.
93
   *
94
   * <p>The presence of this property will <a
95
   * href="https://stripe.com/docs/payments/save-during-payment">attach the payment method</a> to
96
   * the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required
97
   * actions from the user are complete.
98
   *
99
   * <p>One of {@code off_session}, or {@code on_session}.
100
   */
101
  @SerializedName("setup_future_usage")
102
  String setupFutureUsage;
103

104
  /**
105
   * ID of the SetupIntent that this ConfirmationToken was used to confirm, or null if this
106
   * ConfirmationToken has not yet been used.
107
   */
108
  @SerializedName("setup_intent")
109
  String setupIntent;
110

111
  /** Shipping information collected on this ConfirmationToken. */
112
  @SerializedName("shipping")
113
  Shipping shipping;
114

115
  /**
116
   * Indicates whether the Stripe SDK is used to handle confirmation flow. Defaults to {@code true}
117
   * on ConfirmationToken.
118
   */
119
  @SerializedName("use_stripe_sdk")
120
  Boolean useStripeSdk;
121

122
  /** Retrieves an existing ConfirmationToken object. */
123
  public static ConfirmationToken retrieve(String confirmationToken) throws StripeException {
124
    return retrieve(confirmationToken, (Map<String, Object>) null, (RequestOptions) null);
×
125
  }
126

127
  /** Retrieves an existing ConfirmationToken object. */
128
  public static ConfirmationToken retrieve(String confirmationToken, RequestOptions options)
129
      throws StripeException {
130
    return retrieve(confirmationToken, (Map<String, Object>) null, options);
×
131
  }
132

133
  /** Retrieves an existing ConfirmationToken object. */
134
  public static ConfirmationToken retrieve(
135
      String confirmationToken, Map<String, Object> params, RequestOptions options)
136
      throws StripeException {
137
    String path =
×
138
        String.format("/v1/confirmation_tokens/%s", ApiResource.urlEncodeId(confirmationToken));
×
139
    ApiRequest request =
×
140
        new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.GET, path, params, options);
141
    return getGlobalResponseGetter().request(request, ConfirmationToken.class);
×
142
  }
143

144
  /** Retrieves an existing ConfirmationToken object. */
145
  public static ConfirmationToken retrieve(
146
      String confirmationToken, ConfirmationTokenRetrieveParams params, RequestOptions options)
147
      throws StripeException {
148
    String path =
×
149
        String.format("/v1/confirmation_tokens/%s", ApiResource.urlEncodeId(confirmationToken));
×
150
    ApiResource.checkNullTypedParams(path, params);
×
151
    ApiRequest request =
×
152
        new ApiRequest(
153
            BaseAddress.API,
154
            ApiResource.RequestMethod.GET,
155
            path,
156
            ApiRequestParams.paramsToMap(params),
×
157
            options);
158
    return getGlobalResponseGetter().request(request, ConfirmationToken.class);
×
159
  }
160

161
  /** Data used for generating a Mandate. */
162
  @Getter
163
  @Setter
164
  @EqualsAndHashCode(callSuper = false)
165
  public static class MandateData extends StripeObject {
×
166
    /** This hash contains details about the customer acceptance of the Mandate. */
167
    @SerializedName("customer_acceptance")
168
    CustomerAcceptance customerAcceptance;
169

170
    /** This hash contains details about the customer acceptance of the Mandate. */
171
    @Getter
172
    @Setter
173
    @EqualsAndHashCode(callSuper = false)
174
    public static class CustomerAcceptance extends StripeObject {
×
175
      /**
176
       * If this is a Mandate accepted online, this hash contains details about the online
177
       * acceptance.
178
       */
179
      @SerializedName("online")
180
      Online online;
181

182
      /** The type of customer acceptance information included with the Mandate. */
183
      @SerializedName("type")
184
      String type;
185

186
      /** This hash contains details about the online acceptance. */
187
      @Getter
188
      @Setter
189
      @EqualsAndHashCode(callSuper = false)
190
      public static class Online extends StripeObject {
×
191
        /** The IP address from which the Mandate was accepted by the customer. */
192
        @SerializedName("ip_address")
193
        String ipAddress;
194

195
        /** The user agent of the browser from which the Mandate was accepted by the customer. */
196
        @SerializedName("user_agent")
197
        String userAgent;
198
      }
199
    }
200
  }
201

202
  /** Payment-method-specific configuration. */
203
  @Getter
204
  @Setter
205
  @EqualsAndHashCode(callSuper = false)
206
  public static class PaymentMethodOptions extends StripeObject {
×
207
    /** This hash contains the card payment method options. */
208
    @SerializedName("card")
209
    Card card;
210

211
    /** This hash contains the card payment method options. */
212
    @Getter
213
    @Setter
214
    @EqualsAndHashCode(callSuper = false)
215
    public static class Card extends StripeObject {
×
216
      /** The {@code cvc_update} Token collected from the Payment Element. */
217
      @SerializedName("cvc_token")
218
      String cvcToken;
219
    }
220
  }
221

222
  /** Details of the PaymentMethod collected by Payment Element. */
223
  @Getter
224
  @Setter
225
  @EqualsAndHashCode(callSuper = false)
226
  public static class PaymentMethodPreview extends StripeObject {
×
227
    @SerializedName("acss_debit")
228
    AcssDebit acssDebit;
229

230
    @SerializedName("affirm")
231
    Affirm affirm;
232

233
    @SerializedName("afterpay_clearpay")
234
    AfterpayClearpay afterpayClearpay;
235

236
    @SerializedName("alipay")
237
    Alipay alipay;
238

239
    /**
240
     * This field indicates whether this payment method can be shown again to its customer in a
241
     * checkout flow. Stripe products such as Checkout and Elements use this field to determine
242
     * whether a payment method can be shown as a saved payment method in a checkout flow. The field
243
     * defaults to “unspecified”.
244
     *
245
     * <p>One of {@code always}, {@code limited}, or {@code unspecified}.
246
     */
247
    @SerializedName("allow_redisplay")
248
    String allowRedisplay;
249

250
    @SerializedName("alma")
251
    Alma alma;
252

253
    @SerializedName("amazon_pay")
254
    AmazonPay amazonPay;
255

256
    @SerializedName("au_becs_debit")
257
    AuBecsDebit auBecsDebit;
258

259
    @SerializedName("bacs_debit")
260
    BacsDebit bacsDebit;
261

262
    @SerializedName("bancontact")
263
    Bancontact bancontact;
264

265
    @SerializedName("billing_details")
266
    BillingDetails billingDetails;
267

268
    @SerializedName("blik")
269
    Blik blik;
270

271
    @SerializedName("boleto")
272
    Boleto boleto;
273

274
    @SerializedName("card")
275
    Card card;
276

277
    @SerializedName("card_present")
278
    CardPresent cardPresent;
279

280
    @SerializedName("cashapp")
281
    Cashapp cashapp;
282

283
    /**
284
     * The ID of the Customer to which this PaymentMethod is saved. This will not be set when the
285
     * PaymentMethod has not been saved to a Customer.
286
     */
287
    @SerializedName("customer")
288
    @Getter(lombok.AccessLevel.NONE)
289
    @Setter(lombok.AccessLevel.NONE)
290
    ExpandableField<Customer> customer;
291

292
    @SerializedName("customer_balance")
293
    CustomerBalance customerBalance;
294

295
    @SerializedName("eps")
296
    Eps eps;
297

298
    @SerializedName("fpx")
299
    Fpx fpx;
300

301
    @SerializedName("giropay")
302
    Giropay giropay;
303

304
    @SerializedName("gopay")
305
    Gopay gopay;
306

307
    @SerializedName("grabpay")
308
    Grabpay grabpay;
309

310
    @SerializedName("id_bank_transfer")
311
    IdBankTransfer idBankTransfer;
312

313
    @SerializedName("ideal")
314
    Ideal ideal;
315

316
    @SerializedName("interac_present")
317
    InteracPresent interacPresent;
318

319
    @SerializedName("kakao_pay")
320
    KakaoPay kakaoPay;
321

322
    @SerializedName("klarna")
323
    Klarna klarna;
324

325
    @SerializedName("konbini")
326
    Konbini konbini;
327

328
    @SerializedName("kr_card")
329
    KrCard krCard;
330

331
    @SerializedName("link")
332
    Link link;
333

334
    @SerializedName("mb_way")
335
    MbWay mbWay;
336

337
    @SerializedName("mobilepay")
338
    Mobilepay mobilepay;
339

340
    @SerializedName("multibanco")
341
    Multibanco multibanco;
342

343
    @SerializedName("naver_pay")
344
    NaverPay naverPay;
345

346
    @SerializedName("oxxo")
347
    Oxxo oxxo;
348

349
    @SerializedName("p24")
350
    P24 p24;
351

352
    @SerializedName("payco")
353
    Payco payco;
354

355
    @SerializedName("paynow")
356
    Paynow paynow;
357

358
    @SerializedName("paypal")
359
    Paypal paypal;
360

361
    @SerializedName("payto")
362
    Payto payto;
363

364
    @SerializedName("pix")
365
    Pix pix;
366

367
    @SerializedName("promptpay")
368
    Promptpay promptpay;
369

370
    @SerializedName("qris")
371
    Qris qris;
372

373
    @SerializedName("rechnung")
374
    Rechnung rechnung;
375

376
    @SerializedName("revolut_pay")
377
    RevolutPay revolutPay;
378

379
    @SerializedName("samsung_pay")
380
    SamsungPay samsungPay;
381

382
    @SerializedName("sepa_debit")
383
    SepaDebit sepaDebit;
384

385
    @SerializedName("shopeepay")
386
    Shopeepay shopeepay;
387

388
    @SerializedName("sofort")
389
    Sofort sofort;
390

391
    @SerializedName("swish")
392
    Swish swish;
393

394
    @SerializedName("twint")
395
    Twint twint;
396

397
    /**
398
     * The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a
399
     * name matching this value. It contains additional information specific to the PaymentMethod
400
     * type.
401
     *
402
     * <p>One of {@code acss_debit}, {@code affirm}, {@code afterpay_clearpay}, {@code alipay},
403
     * {@code alma}, {@code amazon_pay}, {@code au_becs_debit}, {@code bacs_debit}, {@code
404
     * bancontact}, {@code blik}, {@code boleto}, {@code card}, {@code card_present}, {@code
405
     * cashapp}, {@code customer_balance}, {@code eps}, {@code fpx}, {@code giropay}, {@code gopay},
406
     * {@code grabpay}, {@code id_bank_transfer}, {@code ideal}, {@code interac_present}, {@code
407
     * kakao_pay}, {@code klarna}, {@code konbini}, {@code kr_card}, {@code link}, {@code mb_way},
408
     * {@code mobilepay}, {@code multibanco}, {@code naver_pay}, {@code oxxo}, {@code p24}, {@code
409
     * payco}, {@code paynow}, {@code paypal}, {@code payto}, {@code pix}, {@code promptpay}, {@code
410
     * qris}, {@code rechnung}, {@code revolut_pay}, {@code samsung_pay}, {@code sepa_debit}, {@code
411
     * shopeepay}, {@code sofort}, {@code swish}, {@code twint}, {@code us_bank_account}, {@code
412
     * wechat_pay}, or {@code zip}.
413
     */
414
    @SerializedName("type")
415
    String type;
416

417
    @SerializedName("us_bank_account")
418
    UsBankAccount usBankAccount;
419

420
    @SerializedName("wechat_pay")
421
    WechatPay wechatPay;
422

423
    @SerializedName("zip")
424
    Zip zip;
425

426
    /** Get ID of expandable {@code customer} object. */
427
    public String getCustomer() {
428
      return (this.customer != null) ? this.customer.getId() : null;
×
429
    }
430

431
    public void setCustomer(String id) {
432
      this.customer = ApiResource.setExpandableFieldId(id, this.customer);
×
433
    }
×
434

435
    /** Get expanded {@code customer}. */
436
    public Customer getCustomerObject() {
437
      return (this.customer != null) ? this.customer.getExpanded() : null;
×
438
    }
439

440
    public void setCustomerObject(Customer expandableObject) {
441
      this.customer = new ExpandableField<Customer>(expandableObject.getId(), expandableObject);
×
442
    }
×
443

444
    /**
445
     * For more details about AcssDebit, please refer to the <a
446
     * href="https://docs.stripe.com/api">API Reference.</a>
447
     */
448
    @Getter
449
    @Setter
450
    @EqualsAndHashCode(callSuper = false)
451
    public static class AcssDebit extends StripeObject {
×
452
      /** Name of the bank associated with the bank account. */
453
      @SerializedName("bank_name")
454
      String bankName;
455

456
      /**
457
       * Uniquely identifies this particular bank account. You can use this attribute to check
458
       * whether two bank accounts are the same.
459
       */
460
      @SerializedName("fingerprint")
461
      String fingerprint;
462

463
      /** Institution number of the bank account. */
464
      @SerializedName("institution_number")
465
      String institutionNumber;
466

467
      /** Last four digits of the bank account number. */
468
      @SerializedName("last4")
469
      String last4;
470

471
      /** Transit number of the bank account. */
472
      @SerializedName("transit_number")
473
      String transitNumber;
474
    }
475

476
    /**
477
     * For more details about Affirm, please refer to the <a href="https://docs.stripe.com/api">API
478
     * Reference.</a>
479
     */
480
    @Getter
481
    @Setter
482
    @EqualsAndHashCode(callSuper = false)
483
    public static class Affirm extends StripeObject {}
×
484

485
    /**
486
     * For more details about AfterpayClearpay, please refer to the <a
487
     * href="https://docs.stripe.com/api">API Reference.</a>
488
     */
489
    @Getter
490
    @Setter
491
    @EqualsAndHashCode(callSuper = false)
492
    public static class AfterpayClearpay extends StripeObject {}
×
493

494
    /**
495
     * For more details about Alipay, please refer to the <a href="https://docs.stripe.com/api">API
496
     * Reference.</a>
497
     */
498
    @Getter
499
    @Setter
500
    @EqualsAndHashCode(callSuper = false)
501
    public static class Alipay extends StripeObject {}
×
502

503
    /**
504
     * For more details about Alma, please refer to the <a href="https://docs.stripe.com/api">API
505
     * Reference.</a>
506
     */
507
    @Getter
508
    @Setter
509
    @EqualsAndHashCode(callSuper = false)
510
    public static class Alma extends StripeObject {}
×
511

512
    /**
513
     * For more details about AmazonPay, please refer to the <a
514
     * href="https://docs.stripe.com/api">API Reference.</a>
515
     */
516
    @Getter
517
    @Setter
518
    @EqualsAndHashCode(callSuper = false)
519
    public static class AmazonPay extends StripeObject {}
×
520

521
    /**
522
     * For more details about AuBecsDebit, please refer to the <a
523
     * href="https://docs.stripe.com/api">API Reference.</a>
524
     */
525
    @Getter
526
    @Setter
527
    @EqualsAndHashCode(callSuper = false)
528
    public static class AuBecsDebit extends StripeObject {
×
529
      /** Six-digit number identifying bank and branch associated with this bank account. */
530
      @SerializedName("bsb_number")
531
      String bsbNumber;
532

533
      /**
534
       * Uniquely identifies this particular bank account. You can use this attribute to check
535
       * whether two bank accounts are the same.
536
       */
537
      @SerializedName("fingerprint")
538
      String fingerprint;
539

540
      /** Last four digits of the bank account number. */
541
      @SerializedName("last4")
542
      String last4;
543
    }
544

545
    /**
546
     * For more details about BacsDebit, please refer to the <a
547
     * href="https://docs.stripe.com/api">API Reference.</a>
548
     */
549
    @Getter
550
    @Setter
551
    @EqualsAndHashCode(callSuper = false)
552
    public static class BacsDebit extends StripeObject {
×
553
      /**
554
       * Uniquely identifies this particular bank account. You can use this attribute to check
555
       * whether two bank accounts are the same.
556
       */
557
      @SerializedName("fingerprint")
558
      String fingerprint;
559

560
      /** Last four digits of the bank account number. */
561
      @SerializedName("last4")
562
      String last4;
563

564
      /** Sort code of the bank account. (e.g., {@code 10-20-30}) */
565
      @SerializedName("sort_code")
566
      String sortCode;
567
    }
568

569
    /**
570
     * For more details about Bancontact, please refer to the <a
571
     * href="https://docs.stripe.com/api">API Reference.</a>
572
     */
573
    @Getter
574
    @Setter
575
    @EqualsAndHashCode(callSuper = false)
576
    public static class Bancontact extends StripeObject {}
×
577

578
    /**
579
     * For more details about BillingDetails, please refer to the <a
580
     * href="https://docs.stripe.com/api">API Reference.</a>
581
     */
582
    @Getter
583
    @Setter
584
    @EqualsAndHashCode(callSuper = false)
585
    public static class BillingDetails extends StripeObject {
×
586
      /** Billing address. */
587
      @SerializedName("address")
588
      Address address;
589

590
      /** Email address. */
591
      @SerializedName("email")
592
      String email;
593

594
      /** Full name. */
595
      @SerializedName("name")
596
      String name;
597

598
      /** Billing phone number (including extension). */
599
      @SerializedName("phone")
600
      String phone;
601
    }
602

603
    /**
604
     * For more details about Blik, please refer to the <a href="https://docs.stripe.com/api">API
605
     * Reference.</a>
606
     */
607
    @Getter
608
    @Setter
609
    @EqualsAndHashCode(callSuper = false)
610
    public static class Blik extends StripeObject {}
×
611

612
    /**
613
     * For more details about Boleto, please refer to the <a href="https://docs.stripe.com/api">API
614
     * Reference.</a>
615
     */
616
    @Getter
617
    @Setter
618
    @EqualsAndHashCode(callSuper = false)
619
    public static class Boleto extends StripeObject {
×
620
      /** Uniquely identifies the customer tax id (CNPJ or CPF). */
621
      @SerializedName("tax_id")
622
      String taxId;
623
    }
624

625
    /**
626
     * For more details about Card, please refer to the <a href="https://docs.stripe.com/api">API
627
     * Reference.</a>
628
     */
629
    @Getter
630
    @Setter
631
    @EqualsAndHashCode(callSuper = false)
632
    public static class Card extends StripeObject {
×
633
      /**
634
       * Card brand. Can be {@code amex}, {@code diners}, {@code discover}, {@code eftpos_au},
635
       * {@code jcb}, {@code mastercard}, {@code unionpay}, {@code visa}, or {@code unknown}.
636
       */
637
      @SerializedName("brand")
638
      String brand;
639

640
      /** Checks on Card address and CVC if provided. */
641
      @SerializedName("checks")
642
      Checks checks;
643

644
      /**
645
       * Two-letter ISO code representing the country of the card. You could use this attribute to
646
       * get a sense of the international breakdown of cards you've collected.
647
       */
648
      @SerializedName("country")
649
      String country;
650

651
      /**
652
       * A high-level description of the type of cards issued in this range. (For internal use only
653
       * and not typically available in standard API requests.)
654
       */
655
      @SerializedName("description")
656
      String description;
657

658
      /**
659
       * The brand to use when displaying the card, this accounts for customer's brand choice on
660
       * dual-branded cards. Can be {@code american_express}, {@code cartes_bancaires}, {@code
661
       * diners_club}, {@code discover}, {@code eftpos_australia}, {@code interac}, {@code jcb},
662
       * {@code mastercard}, {@code union_pay}, {@code visa}, or {@code other} and may contain more
663
       * values in the future.
664
       */
665
      @SerializedName("display_brand")
666
      String displayBrand;
667

668
      /** Two-digit number representing the card's expiration month. */
669
      @SerializedName("exp_month")
670
      Long expMonth;
671

672
      /** Four-digit number representing the card's expiration year. */
673
      @SerializedName("exp_year")
674
      Long expYear;
675

676
      /**
677
       * Uniquely identifies this particular card number. You can use this attribute to check
678
       * whether two customers who’ve signed up with you are using the same card number, for
679
       * example. For payment methods that tokenize card information (Apple Pay, Google Pay), the
680
       * tokenized number might be provided instead of the underlying card number.
681
       *
682
       * <p><em>As of May 1, 2021, card fingerprint in India for Connect changed to allow two
683
       * fingerprints for the same card---one for India and one for the rest of the world.</em>
684
       */
685
      @SerializedName("fingerprint")
686
      String fingerprint;
687

688
      /**
689
       * Card funding type. Can be {@code credit}, {@code debit}, {@code prepaid}, or {@code
690
       * unknown}.
691
       */
692
      @SerializedName("funding")
693
      String funding;
694

695
      /** Details of the original PaymentMethod that created this object. */
696
      @SerializedName("generated_from")
697
      GeneratedFrom generatedFrom;
698

699
      /**
700
       * Issuer identification number of the card. (For internal use only and not typically
701
       * available in standard API requests.)
702
       */
703
      @SerializedName("iin")
704
      String iin;
705

706
      /**
707
       * The name of the card's issuing bank. (For internal use only and not typically available in
708
       * standard API requests.)
709
       */
710
      @SerializedName("issuer")
711
      String issuer;
712

713
      /** The last four digits of the card. */
714
      @SerializedName("last4")
715
      String last4;
716

717
      /** Contains information about card networks that can be used to process the payment. */
718
      @SerializedName("networks")
719
      Networks networks;
720

721
      /** Contains details on how this Card may be used for 3D Secure authentication. */
722
      @SerializedName("three_d_secure_usage")
723
      ThreeDSecureUsage threeDSecureUsage;
724

725
      /** If this Card is part of a card wallet, this contains the details of the card wallet. */
726
      @SerializedName("wallet")
727
      Wallet wallet;
728

729
      /**
730
       * For more details about Checks, please refer to the <a
731
       * href="https://docs.stripe.com/api">API Reference.</a>
732
       */
733
      @Getter
734
      @Setter
735
      @EqualsAndHashCode(callSuper = false)
736
      public static class Checks extends StripeObject {
×
737
        /**
738
         * If a address line1 was provided, results of the check, one of {@code pass}, {@code fail},
739
         * {@code unavailable}, or {@code unchecked}.
740
         */
741
        @SerializedName("address_line1_check")
742
        String addressLine1Check;
743

744
        /**
745
         * If a address postal code was provided, results of the check, one of {@code pass}, {@code
746
         * fail}, {@code unavailable}, or {@code unchecked}.
747
         */
748
        @SerializedName("address_postal_code_check")
749
        String addressPostalCodeCheck;
750

751
        /**
752
         * If a CVC was provided, results of the check, one of {@code pass}, {@code fail}, {@code
753
         * unavailable}, or {@code unchecked}.
754
         */
755
        @SerializedName("cvc_check")
756
        String cvcCheck;
757
      }
758

759
      /**
760
       * For more details about GeneratedFrom, please refer to the <a
761
       * href="https://docs.stripe.com/api">API Reference.</a>
762
       */
763
      @Getter
764
      @Setter
765
      @EqualsAndHashCode(callSuper = false)
766
      public static class GeneratedFrom extends StripeObject {
×
767
        /** The charge that created this object. */
768
        @SerializedName("charge")
769
        String charge;
770

771
        /** Transaction-specific details of the payment method used in the payment. */
772
        @SerializedName("payment_method_details")
773
        PaymentMethodDetails paymentMethodDetails;
774

775
        /** The ID of the SetupAttempt that generated this PaymentMethod, if any. */
776
        @SerializedName("setup_attempt")
777
        @Getter(lombok.AccessLevel.NONE)
778
        @Setter(lombok.AccessLevel.NONE)
779
        ExpandableField<SetupAttempt> setupAttempt;
780

781
        /** Get ID of expandable {@code setupAttempt} object. */
782
        public String getSetupAttempt() {
783
          return (this.setupAttempt != null) ? this.setupAttempt.getId() : null;
×
784
        }
785

786
        public void setSetupAttempt(String id) {
787
          this.setupAttempt = ApiResource.setExpandableFieldId(id, this.setupAttempt);
×
788
        }
×
789

790
        /** Get expanded {@code setupAttempt}. */
791
        public SetupAttempt getSetupAttemptObject() {
792
          return (this.setupAttempt != null) ? this.setupAttempt.getExpanded() : null;
×
793
        }
794

795
        public void setSetupAttemptObject(SetupAttempt expandableObject) {
796
          this.setupAttempt =
×
797
              new ExpandableField<SetupAttempt>(expandableObject.getId(), expandableObject);
×
798
        }
×
799

800
        /**
801
         * For more details about PaymentMethodDetails, please refer to the <a
802
         * href="https://docs.stripe.com/api">API Reference.</a>
803
         */
804
        @Getter
805
        @Setter
806
        @EqualsAndHashCode(callSuper = false)
807
        public static class PaymentMethodDetails extends StripeObject {
×
808
          @SerializedName("card_present")
809
          CardPresent cardPresent;
810

811
          /**
812
           * The type of payment method transaction-specific details from the transaction that
813
           * generated this {@code card} payment method. Always {@code card_present}.
814
           */
815
          @SerializedName("type")
816
          String type;
817

818
          /**
819
           * For more details about CardPresent, please refer to the <a
820
           * href="https://docs.stripe.com/api">API Reference.</a>
821
           */
822
          @Getter
823
          @Setter
824
          @EqualsAndHashCode(callSuper = false)
825
          public static class CardPresent extends StripeObject {
×
826
            /** The authorized amount. */
827
            @SerializedName("amount_authorized")
828
            Long amountAuthorized;
829

830
            /**
831
             * Card brand. Can be {@code amex}, {@code diners}, {@code discover}, {@code eftpos_au},
832
             * {@code jcb}, {@code mastercard}, {@code unionpay}, {@code visa}, or {@code unknown}.
833
             */
834
            @SerializedName("brand")
835
            String brand;
836

837
            /**
838
             * The <a href="https://stripe.com/docs/card-product-codes">product code</a> that
839
             * identifies the specific program or product associated with a card.
840
             */
841
            @SerializedName("brand_product")
842
            String brandProduct;
843

844
            /**
845
             * When using manual capture, a future timestamp after which the charge will be
846
             * automatically refunded if uncaptured.
847
             */
848
            @SerializedName("capture_before")
849
            Long captureBefore;
850

851
            /**
852
             * The cardholder name as read from the card, in <a
853
             * href="https://en.wikipedia.org/wiki/ISO/IEC_7813">ISO 7813</a> format. May include
854
             * alphanumeric characters, special characters and first/last name separator ({@code
855
             * /}). In some cases, the cardholder name may not be available depending on how the
856
             * issuer has configured the card. Cardholder name is typically not available on swipe
857
             * or contactless payments, such as those made with Apple Pay and Google Pay.
858
             */
859
            @SerializedName("cardholder_name")
860
            String cardholderName;
861

862
            /**
863
             * Two-letter ISO code representing the country of the card. You could use this
864
             * attribute to get a sense of the international breakdown of cards you've collected.
865
             */
866
            @SerializedName("country")
867
            String country;
868

869
            /**
870
             * A high-level description of the type of cards issued in this range. (For internal use
871
             * only and not typically available in standard API requests.)
872
             */
873
            @SerializedName("description")
874
            String description;
875

876
            /** Authorization response cryptogram. */
877
            @SerializedName("emv_auth_data")
878
            String emvAuthData;
879

880
            /** Two-digit number representing the card's expiration month. */
881
            @SerializedName("exp_month")
882
            Long expMonth;
883

884
            /** Four-digit number representing the card's expiration year. */
885
            @SerializedName("exp_year")
886
            Long expYear;
887

888
            /**
889
             * Uniquely identifies this particular card number. You can use this attribute to check
890
             * whether two customers who’ve signed up with you are using the same card number, for
891
             * example. For payment methods that tokenize card information (Apple Pay, Google Pay),
892
             * the tokenized number might be provided instead of the underlying card number.
893
             *
894
             * <p><em>As of May 1, 2021, card fingerprint in India for Connect changed to allow two
895
             * fingerprints for the same card---one for India and one for the rest of the
896
             * world.</em>
897
             */
898
            @SerializedName("fingerprint")
899
            String fingerprint;
900

901
            /**
902
             * Card funding type. Can be {@code credit}, {@code debit}, {@code prepaid}, or {@code
903
             * unknown}.
904
             */
905
            @SerializedName("funding")
906
            String funding;
907

908
            /**
909
             * ID of a card PaymentMethod generated from the card_present PaymentMethod that may be
910
             * attached to a Customer for future transactions. Only present if it was possible to
911
             * generate a card PaymentMethod.
912
             */
913
            @SerializedName("generated_card")
914
            String generatedCard;
915

916
            /**
917
             * Issuer identification number of the card. (For internal use only and not typically
918
             * available in standard API requests.)
919
             */
920
            @SerializedName("iin")
921
            String iin;
922

923
            /**
924
             * Whether this <a href="https://stripe.com/docs/api/payment_intents">PaymentIntent</a>
925
             * is eligible for incremental authorizations. Request support using <a
926
             * href="https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card_present-request_incremental_authorization_support">request_incremental_authorization_support</a>.
927
             */
928
            @SerializedName("incremental_authorization_supported")
929
            Boolean incrementalAuthorizationSupported;
930

931
            /**
932
             * The name of the card's issuing bank. (For internal use only and not typically
933
             * available in standard API requests.)
934
             */
935
            @SerializedName("issuer")
936
            String issuer;
937

938
            /** The last four digits of the card. */
939
            @SerializedName("last4")
940
            String last4;
941

942
            /**
943
             * Identifies which network this charge was processed on. Can be {@code amex}, {@code
944
             * cartes_bancaires}, {@code diners}, {@code discover}, {@code eftpos_au}, {@code
945
             * interac}, {@code jcb}, {@code mastercard}, {@code unionpay}, {@code visa}, or {@code
946
             * unknown}.
947
             */
948
            @SerializedName("network")
949
            String network;
950

951
            /**
952
             * This is used by the financial networks to identify a transaction. Visa calls this the
953
             * Transaction ID, Mastercard calls this the Trace ID, and American Express calls this
954
             * the Acquirer Reference Data. The first three digits of the Trace ID is the Financial
955
             * Network Code, the next 6 digits is the Banknet Reference Number, and the last 4
956
             * digits represent the date (MM/DD). This field will be available for successful Visa,
957
             * Mastercard, or American Express transactions and always null for other card brands.
958
             */
959
            @SerializedName("network_transaction_id")
960
            String networkTransactionId;
961

962
            /** Details about payments collected offline. */
963
            @SerializedName("offline")
964
            Offline offline;
965

966
            /** Defines whether the authorized amount can be over-captured or not. */
967
            @SerializedName("overcapture_supported")
968
            Boolean overcaptureSupported;
969

970
            /** EMV tag 5F2D. Preferred languages specified by the integrated circuit chip. */
971
            @SerializedName("preferred_locales")
972
            List<String> preferredLocales;
973

974
            /**
975
             * How card details were read in this transaction.
976
             *
977
             * <p>One of {@code contact_emv}, {@code contactless_emv}, {@code
978
             * contactless_magstripe_mode}, {@code magnetic_stripe_fallback}, or {@code
979
             * magnetic_stripe_track2}.
980
             */
981
            @SerializedName("read_method")
982
            String readMethod;
983

984
            /**
985
             * A collection of fields required to be displayed on receipts. Only required for EMV
986
             * transactions.
987
             */
988
            @SerializedName("receipt")
989
            Receipt receipt;
990

991
            @SerializedName("wallet")
992
            Wallet wallet;
993

994
            /**
995
             * For more details about Offline, please refer to the <a
996
             * href="https://docs.stripe.com/api">API Reference.</a>
997
             */
998
            @Getter
999
            @Setter
1000
            @EqualsAndHashCode(callSuper = false)
1001
            public static class Offline extends StripeObject {
×
1002
              /** Time at which the payment was collected while offline. */
1003
              @SerializedName("stored_at")
1004
              Long storedAt;
1005

1006
              /**
1007
               * The method used to process this payment method offline. Only deferred is allowed.
1008
               *
1009
               * <p>Equal to {@code deferred}.
1010
               */
1011
              @SerializedName("type")
1012
              String type;
1013
            }
1014

1015
            /**
1016
             * For more details about Receipt, please refer to the <a
1017
             * href="https://docs.stripe.com/api">API Reference.</a>
1018
             */
1019
            @Getter
1020
            @Setter
1021
            @EqualsAndHashCode(callSuper = false)
1022
            public static class Receipt extends StripeObject {
×
1023
              /**
1024
               * The type of account being debited or credited
1025
               *
1026
               * <p>One of {@code checking}, {@code credit}, {@code prepaid}, or {@code unknown}.
1027
               */
1028
              @SerializedName("account_type")
1029
              String accountType;
1030

1031
              /** EMV tag 9F26, cryptogram generated by the integrated circuit chip. */
1032
              @SerializedName("application_cryptogram")
1033
              String applicationCryptogram;
1034

1035
              /** Mnenomic of the Application Identifier. */
1036
              @SerializedName("application_preferred_name")
1037
              String applicationPreferredName;
1038

1039
              /** Identifier for this transaction. */
1040
              @SerializedName("authorization_code")
1041
              String authorizationCode;
1042

1043
              /** EMV tag 8A. A code returned by the card issuer. */
1044
              @SerializedName("authorization_response_code")
1045
              String authorizationResponseCode;
1046

1047
              /**
1048
               * Describes the method used by the cardholder to verify ownership of the card. One of
1049
               * the following: {@code approval}, {@code failure}, {@code none}, {@code
1050
               * offline_pin}, {@code offline_pin_and_signature}, {@code online_pin}, or {@code
1051
               * signature}.
1052
               */
1053
              @SerializedName("cardholder_verification_method")
1054
              String cardholderVerificationMethod;
1055

1056
              /**
1057
               * EMV tag 84. Similar to the application identifier stored on the integrated circuit
1058
               * chip.
1059
               */
1060
              @SerializedName("dedicated_file_name")
1061
              String dedicatedFileName;
1062

1063
              /** The outcome of a series of EMV functions performed by the card reader. */
1064
              @SerializedName("terminal_verification_results")
1065
              String terminalVerificationResults;
1066

1067
              /** An indication of various EMV functions performed during the transaction. */
1068
              @SerializedName("transaction_status_information")
1069
              String transactionStatusInformation;
1070
            }
1071

1072
            /**
1073
             * For more details about Wallet, please refer to the <a
1074
             * href="https://docs.stripe.com/api">API Reference.</a>
1075
             */
1076
            @Getter
1077
            @Setter
1078
            @EqualsAndHashCode(callSuper = false)
1079
            public static class Wallet extends StripeObject {
×
1080
              /**
1081
               * The type of mobile wallet, one of {@code apple_pay}, {@code google_pay}, {@code
1082
               * samsung_pay}, or {@code unknown}.
1083
               */
1084
              @SerializedName("type")
1085
              String type;
1086
            }
1087
          }
1088
        }
1089
      }
1090

1091
      /**
1092
       * For more details about Networks, please refer to the <a
1093
       * href="https://docs.stripe.com/api">API Reference.</a>
1094
       */
1095
      @Getter
1096
      @Setter
1097
      @EqualsAndHashCode(callSuper = false)
1098
      public static class Networks extends StripeObject {
×
1099
        /** All available networks for the card. */
1100
        @SerializedName("available")
1101
        List<String> available;
1102

1103
        /**
1104
         * The preferred network for co-branded cards. Can be {@code cartes_bancaires}, {@code
1105
         * mastercard}, {@code visa} or {@code invalid_preference} if requested network is not valid
1106
         * for the card.
1107
         */
1108
        @SerializedName("preferred")
1109
        String preferred;
1110
      }
1111

1112
      /**
1113
       * For more details about ThreeDSecureUsage, please refer to the <a
1114
       * href="https://docs.stripe.com/api">API Reference.</a>
1115
       */
1116
      @Getter
1117
      @Setter
1118
      @EqualsAndHashCode(callSuper = false)
1119
      public static class ThreeDSecureUsage extends StripeObject {
×
1120
        /** Whether 3D Secure is supported on this card. */
1121
        @SerializedName("supported")
1122
        Boolean supported;
1123
      }
1124

1125
      /**
1126
       * For more details about Wallet, please refer to the <a
1127
       * href="https://docs.stripe.com/api">API Reference.</a>
1128
       */
1129
      @Getter
1130
      @Setter
1131
      @EqualsAndHashCode(callSuper = false)
1132
      public static class Wallet extends StripeObject {
×
1133
        @SerializedName("amex_express_checkout")
1134
        AmexExpressCheckout amexExpressCheckout;
1135

1136
        @SerializedName("apple_pay")
1137
        ApplePay applePay;
1138

1139
        /** (For tokenized numbers only.) The last four digits of the device account number. */
1140
        @SerializedName("dynamic_last4")
1141
        String dynamicLast4;
1142

1143
        @SerializedName("google_pay")
1144
        GooglePay googlePay;
1145

1146
        @SerializedName("link")
1147
        Link link;
1148

1149
        @SerializedName("masterpass")
1150
        Masterpass masterpass;
1151

1152
        @SerializedName("samsung_pay")
1153
        SamsungPay samsungPay;
1154

1155
        /**
1156
         * The type of the card wallet, one of {@code amex_express_checkout}, {@code apple_pay},
1157
         * {@code google_pay}, {@code masterpass}, {@code samsung_pay}, {@code visa_checkout}, or
1158
         * {@code link}. An additional hash is included on the Wallet subhash with a name matching
1159
         * this value. It contains additional information specific to the card wallet type.
1160
         */
1161
        @SerializedName("type")
1162
        String type;
1163

1164
        @SerializedName("visa_checkout")
1165
        VisaCheckout visaCheckout;
1166

1167
        /**
1168
         * For more details about AmexExpressCheckout, please refer to the <a
1169
         * href="https://docs.stripe.com/api">API Reference.</a>
1170
         */
1171
        @Getter
1172
        @Setter
1173
        @EqualsAndHashCode(callSuper = false)
1174
        public static class AmexExpressCheckout extends StripeObject {}
×
1175

1176
        /**
1177
         * For more details about ApplePay, please refer to the <a
1178
         * href="https://docs.stripe.com/api">API Reference.</a>
1179
         */
1180
        @Getter
1181
        @Setter
1182
        @EqualsAndHashCode(callSuper = false)
1183
        public static class ApplePay extends StripeObject {}
×
1184

1185
        /**
1186
         * For more details about GooglePay, please refer to the <a
1187
         * href="https://docs.stripe.com/api">API Reference.</a>
1188
         */
1189
        @Getter
1190
        @Setter
1191
        @EqualsAndHashCode(callSuper = false)
1192
        public static class GooglePay extends StripeObject {}
×
1193

1194
        /**
1195
         * For more details about Link, please refer to the <a
1196
         * href="https://docs.stripe.com/api">API Reference.</a>
1197
         */
1198
        @Getter
1199
        @Setter
1200
        @EqualsAndHashCode(callSuper = false)
1201
        public static class Link extends StripeObject {}
×
1202

1203
        /**
1204
         * For more details about Masterpass, please refer to the <a
1205
         * href="https://docs.stripe.com/api">API Reference.</a>
1206
         */
1207
        @Getter
1208
        @Setter
1209
        @EqualsAndHashCode(callSuper = false)
1210
        public static class Masterpass extends StripeObject {
×
1211
          /**
1212
           * Owner's verified billing address. Values are verified or provided by the wallet
1213
           * directly (if supported) at the time of authorization or settlement. They cannot be set
1214
           * or mutated.
1215
           */
1216
          @SerializedName("billing_address")
1217
          Address billingAddress;
1218

1219
          /**
1220
           * Owner's verified email. Values are verified or provided by the wallet directly (if
1221
           * supported) at the time of authorization or settlement. They cannot be set or mutated.
1222
           */
1223
          @SerializedName("email")
1224
          String email;
1225

1226
          /**
1227
           * Owner's verified full name. Values are verified or provided by the wallet directly (if
1228
           * supported) at the time of authorization or settlement. They cannot be set or mutated.
1229
           */
1230
          @SerializedName("name")
1231
          String name;
1232

1233
          /**
1234
           * Owner's verified shipping address. Values are verified or provided by the wallet
1235
           * directly (if supported) at the time of authorization or settlement. They cannot be set
1236
           * or mutated.
1237
           */
1238
          @SerializedName("shipping_address")
1239
          Address shippingAddress;
1240
        }
1241

1242
        /**
1243
         * For more details about SamsungPay, please refer to the <a
1244
         * href="https://docs.stripe.com/api">API Reference.</a>
1245
         */
1246
        @Getter
1247
        @Setter
1248
        @EqualsAndHashCode(callSuper = false)
1249
        public static class SamsungPay extends StripeObject {}
×
1250

1251
        /**
1252
         * For more details about VisaCheckout, please refer to the <a
1253
         * href="https://docs.stripe.com/api">API Reference.</a>
1254
         */
1255
        @Getter
1256
        @Setter
1257
        @EqualsAndHashCode(callSuper = false)
1258
        public static class VisaCheckout extends StripeObject {
×
1259
          /**
1260
           * Owner's verified billing address. Values are verified or provided by the wallet
1261
           * directly (if supported) at the time of authorization or settlement. They cannot be set
1262
           * or mutated.
1263
           */
1264
          @SerializedName("billing_address")
1265
          Address billingAddress;
1266

1267
          /**
1268
           * Owner's verified email. Values are verified or provided by the wallet directly (if
1269
           * supported) at the time of authorization or settlement. They cannot be set or mutated.
1270
           */
1271
          @SerializedName("email")
1272
          String email;
1273

1274
          /**
1275
           * Owner's verified full name. Values are verified or provided by the wallet directly (if
1276
           * supported) at the time of authorization or settlement. They cannot be set or mutated.
1277
           */
1278
          @SerializedName("name")
1279
          String name;
1280

1281
          /**
1282
           * Owner's verified shipping address. Values are verified or provided by the wallet
1283
           * directly (if supported) at the time of authorization or settlement. They cannot be set
1284
           * or mutated.
1285
           */
1286
          @SerializedName("shipping_address")
1287
          Address shippingAddress;
1288
        }
1289
      }
1290
    }
1291

1292
    /**
1293
     * For more details about CardPresent, please refer to the <a
1294
     * href="https://docs.stripe.com/api">API Reference.</a>
1295
     */
1296
    @Getter
1297
    @Setter
1298
    @EqualsAndHashCode(callSuper = false)
1299
    public static class CardPresent extends StripeObject {
×
1300
      /**
1301
       * Card brand. Can be {@code amex}, {@code diners}, {@code discover}, {@code eftpos_au},
1302
       * {@code jcb}, {@code mastercard}, {@code unionpay}, {@code visa}, or {@code unknown}.
1303
       */
1304
      @SerializedName("brand")
1305
      String brand;
1306

1307
      /**
1308
       * The <a href="https://stripe.com/docs/card-product-codes">product code</a> that identifies
1309
       * the specific program or product associated with a card.
1310
       */
1311
      @SerializedName("brand_product")
1312
      String brandProduct;
1313

1314
      /**
1315
       * The cardholder name as read from the card, in <a
1316
       * href="https://en.wikipedia.org/wiki/ISO/IEC_7813">ISO 7813</a> format. May include
1317
       * alphanumeric characters, special characters and first/last name separator ({@code /}). In
1318
       * some cases, the cardholder name may not be available depending on how the issuer has
1319
       * configured the card. Cardholder name is typically not available on swipe or contactless
1320
       * payments, such as those made with Apple Pay and Google Pay.
1321
       */
1322
      @SerializedName("cardholder_name")
1323
      String cardholderName;
1324

1325
      /**
1326
       * Two-letter ISO code representing the country of the card. You could use this attribute to
1327
       * get a sense of the international breakdown of cards you've collected.
1328
       */
1329
      @SerializedName("country")
1330
      String country;
1331

1332
      /**
1333
       * A high-level description of the type of cards issued in this range. (For internal use only
1334
       * and not typically available in standard API requests.)
1335
       */
1336
      @SerializedName("description")
1337
      String description;
1338

1339
      /** Two-digit number representing the card's expiration month. */
1340
      @SerializedName("exp_month")
1341
      Long expMonth;
1342

1343
      /** Four-digit number representing the card's expiration year. */
1344
      @SerializedName("exp_year")
1345
      Long expYear;
1346

1347
      /**
1348
       * Uniquely identifies this particular card number. You can use this attribute to check
1349
       * whether two customers who’ve signed up with you are using the same card number, for
1350
       * example. For payment methods that tokenize card information (Apple Pay, Google Pay), the
1351
       * tokenized number might be provided instead of the underlying card number.
1352
       *
1353
       * <p><em>As of May 1, 2021, card fingerprint in India for Connect changed to allow two
1354
       * fingerprints for the same card---one for India and one for the rest of the world.</em>
1355
       */
1356
      @SerializedName("fingerprint")
1357
      String fingerprint;
1358

1359
      /**
1360
       * Card funding type. Can be {@code credit}, {@code debit}, {@code prepaid}, or {@code
1361
       * unknown}.
1362
       */
1363
      @SerializedName("funding")
1364
      String funding;
1365

1366
      /**
1367
       * Issuer identification number of the card. (For internal use only and not typically
1368
       * available in standard API requests.)
1369
       */
1370
      @SerializedName("iin")
1371
      String iin;
1372

1373
      /**
1374
       * The name of the card's issuing bank. (For internal use only and not typically available in
1375
       * standard API requests.)
1376
       */
1377
      @SerializedName("issuer")
1378
      String issuer;
1379

1380
      /** The last four digits of the card. */
1381
      @SerializedName("last4")
1382
      String last4;
1383

1384
      /** Contains information about card networks that can be used to process the payment. */
1385
      @SerializedName("networks")
1386
      Networks networks;
1387

1388
      /** Details about payment methods collected offline. */
1389
      @SerializedName("offline")
1390
      Offline offline;
1391

1392
      /** EMV tag 5F2D. Preferred languages specified by the integrated circuit chip. */
1393
      @SerializedName("preferred_locales")
1394
      List<String> preferredLocales;
1395

1396
      /**
1397
       * How card details were read in this transaction.
1398
       *
1399
       * <p>One of {@code contact_emv}, {@code contactless_emv}, {@code contactless_magstripe_mode},
1400
       * {@code magnetic_stripe_fallback}, or {@code magnetic_stripe_track2}.
1401
       */
1402
      @SerializedName("read_method")
1403
      String readMethod;
1404

1405
      @SerializedName("wallet")
1406
      Wallet wallet;
1407

1408
      /**
1409
       * For more details about Networks, please refer to the <a
1410
       * href="https://docs.stripe.com/api">API Reference.</a>
1411
       */
1412
      @Getter
1413
      @Setter
1414
      @EqualsAndHashCode(callSuper = false)
1415
      public static class Networks extends StripeObject {
×
1416
        /** All available networks for the card. */
1417
        @SerializedName("available")
1418
        List<String> available;
1419

1420
        /** The preferred network for the card. */
1421
        @SerializedName("preferred")
1422
        String preferred;
1423
      }
1424

1425
      /**
1426
       * For more details about Offline, please refer to the <a
1427
       * href="https://docs.stripe.com/api">API Reference.</a>
1428
       */
1429
      @Getter
1430
      @Setter
1431
      @EqualsAndHashCode(callSuper = false)
1432
      public static class Offline extends StripeObject {
×
1433
        /** Time at which the payment was collected while offline. */
1434
        @SerializedName("stored_at")
1435
        Long storedAt;
1436

1437
        /**
1438
         * The method used to process this payment method offline. Only deferred is allowed.
1439
         *
1440
         * <p>Equal to {@code deferred}.
1441
         */
1442
        @SerializedName("type")
1443
        String type;
1444
      }
1445

1446
      /**
1447
       * For more details about Wallet, please refer to the <a
1448
       * href="https://docs.stripe.com/api">API Reference.</a>
1449
       */
1450
      @Getter
1451
      @Setter
1452
      @EqualsAndHashCode(callSuper = false)
1453
      public static class Wallet extends StripeObject {
×
1454
        /**
1455
         * The type of mobile wallet, one of {@code apple_pay}, {@code google_pay}, {@code
1456
         * samsung_pay}, or {@code unknown}.
1457
         */
1458
        @SerializedName("type")
1459
        String type;
1460
      }
1461
    }
1462

1463
    /**
1464
     * For more details about Cashapp, please refer to the <a href="https://docs.stripe.com/api">API
1465
     * Reference.</a>
1466
     */
1467
    @Getter
1468
    @Setter
1469
    @EqualsAndHashCode(callSuper = false)
1470
    public static class Cashapp extends StripeObject {
×
1471
      /** A unique and immutable identifier assigned by Cash App to every buyer. */
1472
      @SerializedName("buyer_id")
1473
      String buyerId;
1474

1475
      /** A public identifier for buyers using Cash App. */
1476
      @SerializedName("cashtag")
1477
      String cashtag;
1478
    }
1479

1480
    /**
1481
     * For more details about CustomerBalance, please refer to the <a
1482
     * href="https://docs.stripe.com/api">API Reference.</a>
1483
     */
1484
    @Getter
1485
    @Setter
1486
    @EqualsAndHashCode(callSuper = false)
1487
    public static class CustomerBalance extends StripeObject {}
×
1488

1489
    /**
1490
     * For more details about Eps, please refer to the <a href="https://docs.stripe.com/api">API
1491
     * Reference.</a>
1492
     */
1493
    @Getter
1494
    @Setter
1495
    @EqualsAndHashCode(callSuper = false)
1496
    public static class Eps extends StripeObject {
×
1497
      /**
1498
       * The customer's bank. Should be one of {@code arzte_und_apotheker_bank}, {@code
1499
       * austrian_anadi_bank_ag}, {@code bank_austria}, {@code bankhaus_carl_spangler}, {@code
1500
       * bankhaus_schelhammer_und_schattera_ag}, {@code bawag_psk_ag}, {@code bks_bank_ag}, {@code
1501
       * brull_kallmus_bank_ag}, {@code btv_vier_lander_bank}, {@code capital_bank_grawe_gruppe_ag},
1502
       * {@code deutsche_bank_ag}, {@code dolomitenbank}, {@code easybank_ag}, {@code
1503
       * erste_bank_und_sparkassen}, {@code hypo_alpeadriabank_international_ag}, {@code
1504
       * hypo_noe_lb_fur_niederosterreich_u_wien}, {@code hypo_oberosterreich_salzburg_steiermark},
1505
       * {@code hypo_tirol_bank_ag}, {@code hypo_vorarlberg_bank_ag}, {@code
1506
       * hypo_bank_burgenland_aktiengesellschaft}, {@code marchfelder_bank}, {@code oberbank_ag},
1507
       * {@code raiffeisen_bankengruppe_osterreich}, {@code schoellerbank_ag}, {@code
1508
       * sparda_bank_wien}, {@code volksbank_gruppe}, {@code volkskreditbank_ag}, or {@code
1509
       * vr_bank_braunau}.
1510
       */
1511
      @SerializedName("bank")
1512
      String bank;
1513
    }
1514

1515
    /**
1516
     * For more details about Fpx, please refer to the <a href="https://docs.stripe.com/api">API
1517
     * Reference.</a>
1518
     */
1519
    @Getter
1520
    @Setter
1521
    @EqualsAndHashCode(callSuper = false)
1522
    public static class Fpx extends StripeObject {
×
1523
      /** Account holder type, if provided. Can be one of {@code individual} or {@code company}. */
1524
      @SerializedName("account_holder_type")
1525
      String accountHolderType;
1526

1527
      /**
1528
       * The customer's bank, if provided. Can be one of {@code affin_bank}, {@code agrobank},
1529
       * {@code alliance_bank}, {@code ambank}, {@code bank_islam}, {@code bank_muamalat}, {@code
1530
       * bank_rakyat}, {@code bsn}, {@code cimb}, {@code hong_leong_bank}, {@code hsbc}, {@code
1531
       * kfh}, {@code maybank2u}, {@code ocbc}, {@code public_bank}, {@code rhb}, {@code
1532
       * standard_chartered}, {@code uob}, {@code deutsche_bank}, {@code maybank2e}, {@code
1533
       * pb_enterprise}, or {@code bank_of_china}.
1534
       */
1535
      @SerializedName("bank")
1536
      String bank;
1537
    }
1538

1539
    /**
1540
     * For more details about Giropay, please refer to the <a href="https://docs.stripe.com/api">API
1541
     * Reference.</a>
1542
     */
1543
    @Getter
1544
    @Setter
1545
    @EqualsAndHashCode(callSuper = false)
1546
    public static class Giropay extends StripeObject {}
×
1547

1548
    /**
1549
     * For more details about Gopay, please refer to the <a href="https://docs.stripe.com/api">API
1550
     * Reference.</a>
1551
     */
1552
    @Getter
1553
    @Setter
1554
    @EqualsAndHashCode(callSuper = false)
1555
    public static class Gopay extends StripeObject {}
×
1556

1557
    /**
1558
     * For more details about Grabpay, please refer to the <a href="https://docs.stripe.com/api">API
1559
     * Reference.</a>
1560
     */
1561
    @Getter
1562
    @Setter
1563
    @EqualsAndHashCode(callSuper = false)
1564
    public static class Grabpay extends StripeObject {}
×
1565

1566
    /**
1567
     * For more details about IdBankTransfer, please refer to the <a
1568
     * href="https://docs.stripe.com/api">API Reference.</a>
1569
     */
1570
    @Getter
1571
    @Setter
1572
    @EqualsAndHashCode(callSuper = false)
NEW
1573
    public static class IdBankTransfer extends StripeObject {
×
1574
      @SerializedName("bank")
1575
      String bank;
1576

1577
      @SerializedName("bank_code")
1578
      String bankCode;
1579

1580
      @SerializedName("bank_name")
1581
      String bankName;
1582

1583
      @SerializedName("display_name")
1584
      String displayName;
1585
    }
1586

1587
    /**
1588
     * For more details about Ideal, please refer to the <a href="https://docs.stripe.com/api">API
1589
     * Reference.</a>
1590
     */
1591
    @Getter
1592
    @Setter
1593
    @EqualsAndHashCode(callSuper = false)
1594
    public static class Ideal extends StripeObject {
×
1595
      /**
1596
       * The customer's bank, if provided. Can be one of {@code abn_amro}, {@code asn_bank}, {@code
1597
       * bunq}, {@code handelsbanken}, {@code ing}, {@code knab}, {@code moneyou}, {@code n26},
1598
       * {@code nn}, {@code rabobank}, {@code regiobank}, {@code revolut}, {@code sns_bank}, {@code
1599
       * triodos_bank}, {@code van_lanschot}, or {@code yoursafe}.
1600
       */
1601
      @SerializedName("bank")
1602
      String bank;
1603

1604
      /**
1605
       * The Bank Identifier Code of the customer's bank, if the bank was provided.
1606
       *
1607
       * <p>One of {@code ABNANL2A}, {@code ASNBNL21}, {@code BITSNL2A}, {@code BUNQNL2A}, {@code
1608
       * FVLBNL22}, {@code HANDNL2A}, {@code INGBNL2A}, {@code KNABNL2H}, {@code MOYONL21}, {@code
1609
       * NNBANL2G}, {@code NTSBDEB1}, {@code RABONL2U}, {@code RBRBNL21}, {@code REVOIE23}, {@code
1610
       * REVOLT21}, {@code SNSBNL2A}, or {@code TRIONL2U}.
1611
       */
1612
      @SerializedName("bic")
1613
      String bic;
1614
    }
1615

1616
    /**
1617
     * For more details about InteracPresent, please refer to the <a
1618
     * href="https://docs.stripe.com/api">API Reference.</a>
1619
     */
1620
    @Getter
1621
    @Setter
1622
    @EqualsAndHashCode(callSuper = false)
1623
    public static class InteracPresent extends StripeObject {
×
1624
      /** Card brand. Can be {@code interac}, {@code mastercard} or {@code visa}. */
1625
      @SerializedName("brand")
1626
      String brand;
1627

1628
      /**
1629
       * The cardholder name as read from the card, in <a
1630
       * href="https://en.wikipedia.org/wiki/ISO/IEC_7813">ISO 7813</a> format. May include
1631
       * alphanumeric characters, special characters and first/last name separator ({@code /}). In
1632
       * some cases, the cardholder name may not be available depending on how the issuer has
1633
       * configured the card. Cardholder name is typically not available on swipe or contactless
1634
       * payments, such as those made with Apple Pay and Google Pay.
1635
       */
1636
      @SerializedName("cardholder_name")
1637
      String cardholderName;
1638

1639
      /**
1640
       * Two-letter ISO code representing the country of the card. You could use this attribute to
1641
       * get a sense of the international breakdown of cards you've collected.
1642
       */
1643
      @SerializedName("country")
1644
      String country;
1645

1646
      /**
1647
       * A high-level description of the type of cards issued in this range. (For internal use only
1648
       * and not typically available in standard API requests.)
1649
       */
1650
      @SerializedName("description")
1651
      String description;
1652

1653
      /** Two-digit number representing the card's expiration month. */
1654
      @SerializedName("exp_month")
1655
      Long expMonth;
1656

1657
      /** Four-digit number representing the card's expiration year. */
1658
      @SerializedName("exp_year")
1659
      Long expYear;
1660

1661
      /**
1662
       * Uniquely identifies this particular card number. You can use this attribute to check
1663
       * whether two customers who’ve signed up with you are using the same card number, for
1664
       * example. For payment methods that tokenize card information (Apple Pay, Google Pay), the
1665
       * tokenized number might be provided instead of the underlying card number.
1666
       *
1667
       * <p><em>As of May 1, 2021, card fingerprint in India for Connect changed to allow two
1668
       * fingerprints for the same card---one for India and one for the rest of the world.</em>
1669
       */
1670
      @SerializedName("fingerprint")
1671
      String fingerprint;
1672

1673
      /**
1674
       * Card funding type. Can be {@code credit}, {@code debit}, {@code prepaid}, or {@code
1675
       * unknown}.
1676
       */
1677
      @SerializedName("funding")
1678
      String funding;
1679

1680
      /**
1681
       * Issuer identification number of the card. (For internal use only and not typically
1682
       * available in standard API requests.)
1683
       */
1684
      @SerializedName("iin")
1685
      String iin;
1686

1687
      /**
1688
       * The name of the card's issuing bank. (For internal use only and not typically available in
1689
       * standard API requests.)
1690
       */
1691
      @SerializedName("issuer")
1692
      String issuer;
1693

1694
      /** The last four digits of the card. */
1695
      @SerializedName("last4")
1696
      String last4;
1697

1698
      /** Contains information about card networks that can be used to process the payment. */
1699
      @SerializedName("networks")
1700
      Networks networks;
1701

1702
      /** EMV tag 5F2D. Preferred languages specified by the integrated circuit chip. */
1703
      @SerializedName("preferred_locales")
1704
      List<String> preferredLocales;
1705

1706
      /**
1707
       * How card details were read in this transaction.
1708
       *
1709
       * <p>One of {@code contact_emv}, {@code contactless_emv}, {@code contactless_magstripe_mode},
1710
       * {@code magnetic_stripe_fallback}, or {@code magnetic_stripe_track2}.
1711
       */
1712
      @SerializedName("read_method")
1713
      String readMethod;
1714

1715
      /**
1716
       * For more details about Networks, please refer to the <a
1717
       * href="https://docs.stripe.com/api">API Reference.</a>
1718
       */
1719
      @Getter
1720
      @Setter
1721
      @EqualsAndHashCode(callSuper = false)
1722
      public static class Networks extends StripeObject {
×
1723
        /** All available networks for the card. */
1724
        @SerializedName("available")
1725
        List<String> available;
1726

1727
        /** The preferred network for the card. */
1728
        @SerializedName("preferred")
1729
        String preferred;
1730
      }
1731
    }
1732

1733
    /**
1734
     * For more details about KakaoPay, please refer to the <a
1735
     * href="https://docs.stripe.com/api">API Reference.</a>
1736
     */
1737
    @Getter
1738
    @Setter
1739
    @EqualsAndHashCode(callSuper = false)
1740
    public static class KakaoPay extends StripeObject {}
×
1741

1742
    /**
1743
     * For more details about Klarna, please refer to the <a href="https://docs.stripe.com/api">API
1744
     * Reference.</a>
1745
     */
1746
    @Getter
1747
    @Setter
1748
    @EqualsAndHashCode(callSuper = false)
1749
    public static class Klarna extends StripeObject {
×
1750
      /** The customer's date of birth, if provided. */
1751
      @SerializedName("dob")
1752
      Dob dob;
1753

1754
      /**
1755
       * For more details about Dob, please refer to the <a href="https://docs.stripe.com/api">API
1756
       * Reference.</a>
1757
       */
1758
      @Getter
1759
      @Setter
1760
      @EqualsAndHashCode(callSuper = false)
1761
      public static class Dob extends StripeObject {
×
1762
        /** The day of birth, between 1 and 31. */
1763
        @SerializedName("day")
1764
        Long day;
1765

1766
        /** The month of birth, between 1 and 12. */
1767
        @SerializedName("month")
1768
        Long month;
1769

1770
        /** The four-digit year of birth. */
1771
        @SerializedName("year")
1772
        Long year;
1773
      }
1774
    }
1775

1776
    /**
1777
     * For more details about Konbini, please refer to the <a href="https://docs.stripe.com/api">API
1778
     * Reference.</a>
1779
     */
1780
    @Getter
1781
    @Setter
1782
    @EqualsAndHashCode(callSuper = false)
1783
    public static class Konbini extends StripeObject {}
×
1784

1785
    /**
1786
     * For more details about KrCard, please refer to the <a href="https://docs.stripe.com/api">API
1787
     * Reference.</a>
1788
     */
1789
    @Getter
1790
    @Setter
1791
    @EqualsAndHashCode(callSuper = false)
1792
    public static class KrCard extends StripeObject {
×
1793
      /**
1794
       * The local credit or debit card brand.
1795
       *
1796
       * <p>One of {@code bc}, {@code citi}, {@code hana}, {@code hyundai}, {@code jeju}, {@code
1797
       * jeonbuk}, {@code kakaobank}, {@code kbank}, {@code kdbbank}, {@code kookmin}, {@code
1798
       * kwangju}, {@code lotte}, {@code mg}, {@code nh}, {@code post}, {@code samsung}, {@code
1799
       * savingsbank}, {@code shinhan}, {@code shinhyup}, {@code suhyup}, {@code tossbank}, or
1800
       * {@code woori}.
1801
       */
1802
      @SerializedName("brand")
1803
      String brand;
1804

1805
      /** The last four digits of the card. This may not be present for American Express cards. */
1806
      @SerializedName("last4")
1807
      String last4;
1808
    }
1809

1810
    /**
1811
     * For more details about Link, please refer to the <a href="https://docs.stripe.com/api">API
1812
     * Reference.</a>
1813
     */
1814
    @Getter
1815
    @Setter
1816
    @EqualsAndHashCode(callSuper = false)
1817
    public static class Link extends StripeObject {
×
1818
      /** Account owner's email address. */
1819
      @SerializedName("email")
1820
      String email;
1821

1822
      /** [Deprecated] This is a legacy parameter that no longer has any function. */
1823
      @SerializedName("persistent_token")
1824
      @Deprecated
1825
      String persistentToken;
1826
    }
1827

1828
    /**
1829
     * For more details about MbWay, please refer to the <a href="https://docs.stripe.com/api">API
1830
     * Reference.</a>
1831
     */
1832
    @Getter
1833
    @Setter
1834
    @EqualsAndHashCode(callSuper = false)
1835
    public static class MbWay extends StripeObject {}
×
1836

1837
    /**
1838
     * For more details about Mobilepay, please refer to the <a
1839
     * href="https://docs.stripe.com/api">API Reference.</a>
1840
     */
1841
    @Getter
1842
    @Setter
1843
    @EqualsAndHashCode(callSuper = false)
1844
    public static class Mobilepay extends StripeObject {}
×
1845

1846
    /**
1847
     * For more details about Multibanco, please refer to the <a
1848
     * href="https://docs.stripe.com/api">API Reference.</a>
1849
     */
1850
    @Getter
1851
    @Setter
1852
    @EqualsAndHashCode(callSuper = false)
1853
    public static class Multibanco extends StripeObject {}
×
1854

1855
    /**
1856
     * For more details about NaverPay, please refer to the <a
1857
     * href="https://docs.stripe.com/api">API Reference.</a>
1858
     */
1859
    @Getter
1860
    @Setter
1861
    @EqualsAndHashCode(callSuper = false)
1862
    public static class NaverPay extends StripeObject {
×
1863
      /**
1864
       * Whether to fund this transaction with Naver Pay points or a card.
1865
       *
1866
       * <p>One of {@code card}, or {@code points}.
1867
       */
1868
      @SerializedName("funding")
1869
      String funding;
1870
    }
1871

1872
    /**
1873
     * For more details about Oxxo, please refer to the <a href="https://docs.stripe.com/api">API
1874
     * Reference.</a>
1875
     */
1876
    @Getter
1877
    @Setter
1878
    @EqualsAndHashCode(callSuper = false)
1879
    public static class Oxxo extends StripeObject {}
×
1880

1881
    /**
1882
     * For more details about P24, please refer to the <a href="https://docs.stripe.com/api">API
1883
     * Reference.</a>
1884
     */
1885
    @Getter
1886
    @Setter
1887
    @EqualsAndHashCode(callSuper = false)
1888
    public static class P24 extends StripeObject {
×
1889
      /**
1890
       * The customer's bank, if provided.
1891
       *
1892
       * <p>One of {@code alior_bank}, {@code bank_millennium}, {@code bank_nowy_bfg_sa}, {@code
1893
       * bank_pekao_sa}, {@code banki_spbdzielcze}, {@code blik}, {@code bnp_paribas}, {@code boz},
1894
       * {@code citi_handlowy}, {@code credit_agricole}, {@code envelobank}, {@code
1895
       * etransfer_pocztowy24}, {@code getin_bank}, {@code ideabank}, {@code ing}, {@code inteligo},
1896
       * {@code mbank_mtransfer}, {@code nest_przelew}, {@code noble_pay}, {@code pbac_z_ipko},
1897
       * {@code plus_bank}, {@code santander_przelew24}, {@code tmobile_usbugi_bankowe}, {@code
1898
       * toyota_bank}, {@code velobank}, or {@code volkswagen_bank}.
1899
       */
1900
      @SerializedName("bank")
1901
      String bank;
1902
    }
1903

1904
    /**
1905
     * For more details about Payco, please refer to the <a href="https://docs.stripe.com/api">API
1906
     * Reference.</a>
1907
     */
1908
    @Getter
1909
    @Setter
1910
    @EqualsAndHashCode(callSuper = false)
1911
    public static class Payco extends StripeObject {}
×
1912

1913
    /**
1914
     * For more details about Paynow, please refer to the <a href="https://docs.stripe.com/api">API
1915
     * Reference.</a>
1916
     */
1917
    @Getter
1918
    @Setter
1919
    @EqualsAndHashCode(callSuper = false)
1920
    public static class Paynow extends StripeObject {}
×
1921

1922
    /**
1923
     * For more details about Paypal, please refer to the <a href="https://docs.stripe.com/api">API
1924
     * Reference.</a>
1925
     */
1926
    @Getter
1927
    @Setter
1928
    @EqualsAndHashCode(callSuper = false)
1929
    public static class Paypal extends StripeObject {
×
1930
      /**
1931
       * Uniquely identifies this particular PayPal account. You can use this attribute to check
1932
       * whether two PayPal accounts are the same.
1933
       */
1934
      @SerializedName("fingerprint")
1935
      String fingerprint;
1936

1937
      /**
1938
       * Owner's email. Values are provided by PayPal directly (if supported) at the time of
1939
       * authorization or settlement. They cannot be set or mutated.
1940
       */
1941
      @SerializedName("payer_email")
1942
      String payerEmail;
1943

1944
      /** PayPal account PayerID. This identifier uniquely identifies the PayPal customer. */
1945
      @SerializedName("payer_id")
1946
      String payerId;
1947

1948
      /**
1949
       * Owner's verified email. Values are verified or provided by PayPal directly (if supported)
1950
       * at the time of authorization or settlement. They cannot be set or mutated.
1951
       */
1952
      @SerializedName("verified_email")
1953
      String verifiedEmail;
1954
    }
1955

1956
    /**
1957
     * For more details about Payto, please refer to the <a href="https://docs.stripe.com/api">API
1958
     * Reference.</a>
1959
     */
1960
    @Getter
1961
    @Setter
1962
    @EqualsAndHashCode(callSuper = false)
1963
    public static class Payto extends StripeObject {
×
1964
      /** Bank-State-Branch number of the bank account. */
1965
      @SerializedName("bsb_number")
1966
      String bsbNumber;
1967

1968
      /** Last four digits of the bank account number. */
1969
      @SerializedName("last4")
1970
      String last4;
1971

1972
      /** The PayID alias for the bank account. */
1973
      @SerializedName("pay_id")
1974
      String payId;
1975
    }
1976

1977
    /**
1978
     * For more details about Pix, please refer to the <a href="https://docs.stripe.com/api">API
1979
     * Reference.</a>
1980
     */
1981
    @Getter
1982
    @Setter
1983
    @EqualsAndHashCode(callSuper = false)
1984
    public static class Pix extends StripeObject {}
×
1985

1986
    /**
1987
     * For more details about Promptpay, please refer to the <a
1988
     * href="https://docs.stripe.com/api">API Reference.</a>
1989
     */
1990
    @Getter
1991
    @Setter
1992
    @EqualsAndHashCode(callSuper = false)
1993
    public static class Promptpay extends StripeObject {}
×
1994

1995
    /**
1996
     * For more details about Qris, please refer to the <a href="https://docs.stripe.com/api">API
1997
     * Reference.</a>
1998
     */
1999
    @Getter
2000
    @Setter
2001
    @EqualsAndHashCode(callSuper = false)
2002
    public static class Qris extends StripeObject {}
×
2003

2004
    /**
2005
     * For more details about Rechnung, please refer to the <a
2006
     * href="https://docs.stripe.com/api">API Reference.</a>
2007
     */
2008
    @Getter
2009
    @Setter
2010
    @EqualsAndHashCode(callSuper = false)
2011
    public static class Rechnung extends StripeObject {
×
2012
      @SerializedName("dob")
2013
      Dob dob;
2014

2015
      /**
2016
       * For more details about Dob, please refer to the <a href="https://docs.stripe.com/api">API
2017
       * Reference.</a>
2018
       */
2019
      @Getter
2020
      @Setter
2021
      @EqualsAndHashCode(callSuper = false)
2022
      public static class Dob extends StripeObject {
×
2023
        /** The day of birth, between 1 and 31. */
2024
        @SerializedName("day")
2025
        Long day;
2026

2027
        /** The month of birth, between 1 and 12. */
2028
        @SerializedName("month")
2029
        Long month;
2030

2031
        /** The four-digit year of birth. */
2032
        @SerializedName("year")
2033
        Long year;
2034
      }
2035
    }
2036

2037
    /**
2038
     * For more details about RevolutPay, please refer to the <a
2039
     * href="https://docs.stripe.com/api">API Reference.</a>
2040
     */
2041
    @Getter
2042
    @Setter
2043
    @EqualsAndHashCode(callSuper = false)
2044
    public static class RevolutPay extends StripeObject {}
×
2045

2046
    /**
2047
     * For more details about SamsungPay, please refer to the <a
2048
     * href="https://docs.stripe.com/api">API Reference.</a>
2049
     */
2050
    @Getter
2051
    @Setter
2052
    @EqualsAndHashCode(callSuper = false)
2053
    public static class SamsungPay extends StripeObject {}
×
2054

2055
    /**
2056
     * For more details about SepaDebit, please refer to the <a
2057
     * href="https://docs.stripe.com/api">API Reference.</a>
2058
     */
2059
    @Getter
2060
    @Setter
2061
    @EqualsAndHashCode(callSuper = false)
2062
    public static class SepaDebit extends StripeObject {
×
2063
      /** Bank code of bank associated with the bank account. */
2064
      @SerializedName("bank_code")
2065
      String bankCode;
2066

2067
      /** Branch code of bank associated with the bank account. */
2068
      @SerializedName("branch_code")
2069
      String branchCode;
2070

2071
      /** Two-letter ISO code representing the country the bank account is located in. */
2072
      @SerializedName("country")
2073
      String country;
2074

2075
      /**
2076
       * Uniquely identifies this particular bank account. You can use this attribute to check
2077
       * whether two bank accounts are the same.
2078
       */
2079
      @SerializedName("fingerprint")
2080
      String fingerprint;
2081

2082
      /** Information about the object that generated this PaymentMethod. */
2083
      @SerializedName("generated_from")
2084
      GeneratedFrom generatedFrom;
2085

2086
      /** Last four characters of the IBAN. */
2087
      @SerializedName("last4")
2088
      String last4;
2089

2090
      /**
2091
       * For more details about GeneratedFrom, please refer to the <a
2092
       * href="https://docs.stripe.com/api">API Reference.</a>
2093
       */
2094
      @Getter
2095
      @Setter
2096
      @EqualsAndHashCode(callSuper = false)
2097
      public static class GeneratedFrom extends StripeObject {
×
2098
        /** The ID of the Charge that generated this PaymentMethod, if any. */
2099
        @SerializedName("charge")
2100
        @Getter(lombok.AccessLevel.NONE)
2101
        @Setter(lombok.AccessLevel.NONE)
2102
        ExpandableField<Charge> charge;
2103

2104
        /** The ID of the SetupAttempt that generated this PaymentMethod, if any. */
2105
        @SerializedName("setup_attempt")
2106
        @Getter(lombok.AccessLevel.NONE)
2107
        @Setter(lombok.AccessLevel.NONE)
2108
        ExpandableField<SetupAttempt> setupAttempt;
2109

2110
        /** Get ID of expandable {@code charge} object. */
2111
        public String getCharge() {
2112
          return (this.charge != null) ? this.charge.getId() : null;
×
2113
        }
2114

2115
        public void setCharge(String id) {
2116
          this.charge = ApiResource.setExpandableFieldId(id, this.charge);
×
2117
        }
×
2118

2119
        /** Get expanded {@code charge}. */
2120
        public Charge getChargeObject() {
2121
          return (this.charge != null) ? this.charge.getExpanded() : null;
×
2122
        }
2123

2124
        public void setChargeObject(Charge expandableObject) {
2125
          this.charge = new ExpandableField<Charge>(expandableObject.getId(), expandableObject);
×
2126
        }
×
2127

2128
        /** Get ID of expandable {@code setupAttempt} object. */
2129
        public String getSetupAttempt() {
2130
          return (this.setupAttempt != null) ? this.setupAttempt.getId() : null;
×
2131
        }
2132

2133
        public void setSetupAttempt(String id) {
2134
          this.setupAttempt = ApiResource.setExpandableFieldId(id, this.setupAttempt);
×
2135
        }
×
2136

2137
        /** Get expanded {@code setupAttempt}. */
2138
        public SetupAttempt getSetupAttemptObject() {
2139
          return (this.setupAttempt != null) ? this.setupAttempt.getExpanded() : null;
×
2140
        }
2141

2142
        public void setSetupAttemptObject(SetupAttempt expandableObject) {
2143
          this.setupAttempt =
×
2144
              new ExpandableField<SetupAttempt>(expandableObject.getId(), expandableObject);
×
2145
        }
×
2146
      }
2147
    }
2148

2149
    /**
2150
     * For more details about Shopeepay, please refer to the <a
2151
     * href="https://docs.stripe.com/api">API Reference.</a>
2152
     */
2153
    @Getter
2154
    @Setter
2155
    @EqualsAndHashCode(callSuper = false)
2156
    public static class Shopeepay extends StripeObject {}
×
2157

2158
    /**
2159
     * For more details about Sofort, please refer to the <a href="https://docs.stripe.com/api">API
2160
     * Reference.</a>
2161
     */
2162
    @Getter
2163
    @Setter
2164
    @EqualsAndHashCode(callSuper = false)
2165
    public static class Sofort extends StripeObject {
×
2166
      /** Two-letter ISO code representing the country the bank account is located in. */
2167
      @SerializedName("country")
2168
      String country;
2169
    }
2170

2171
    /**
2172
     * For more details about Swish, please refer to the <a href="https://docs.stripe.com/api">API
2173
     * Reference.</a>
2174
     */
2175
    @Getter
2176
    @Setter
2177
    @EqualsAndHashCode(callSuper = false)
2178
    public static class Swish extends StripeObject {}
×
2179

2180
    /**
2181
     * For more details about Twint, please refer to the <a href="https://docs.stripe.com/api">API
2182
     * Reference.</a>
2183
     */
2184
    @Getter
2185
    @Setter
2186
    @EqualsAndHashCode(callSuper = false)
2187
    public static class Twint extends StripeObject {}
×
2188

2189
    /**
2190
     * For more details about UsBankAccount, please refer to the <a
2191
     * href="https://docs.stripe.com/api">API Reference.</a>
2192
     */
2193
    @Getter
2194
    @Setter
2195
    @EqualsAndHashCode(callSuper = false)
2196
    public static class UsBankAccount extends StripeObject {
×
2197
      /**
2198
       * Account holder type: individual or company.
2199
       *
2200
       * <p>One of {@code company}, or {@code individual}.
2201
       */
2202
      @SerializedName("account_holder_type")
2203
      String accountHolderType;
2204

2205
      /** Account number of the bank account. */
2206
      @SerializedName("account_number")
2207
      String accountNumber;
2208

2209
      /**
2210
       * Account type: checkings or savings. Defaults to checking if omitted.
2211
       *
2212
       * <p>One of {@code checking}, or {@code savings}.
2213
       */
2214
      @SerializedName("account_type")
2215
      String accountType;
2216

2217
      /** The name of the bank. */
2218
      @SerializedName("bank_name")
2219
      String bankName;
2220

2221
      /** The ID of the Financial Connections Account used to create the payment method. */
2222
      @SerializedName("financial_connections_account")
2223
      String financialConnectionsAccount;
2224

2225
      /**
2226
       * Uniquely identifies this particular bank account. You can use this attribute to check
2227
       * whether two bank accounts are the same.
2228
       */
2229
      @SerializedName("fingerprint")
2230
      String fingerprint;
2231

2232
      /** Last four digits of the bank account number. */
2233
      @SerializedName("last4")
2234
      String last4;
2235

2236
      /** Contains information about US bank account networks that can be used. */
2237
      @SerializedName("networks")
2238
      Networks networks;
2239

2240
      /** Routing number of the bank account. */
2241
      @SerializedName("routing_number")
2242
      String routingNumber;
2243

2244
      /** Contains information about the future reusability of this PaymentMethod. */
2245
      @SerializedName("status_details")
2246
      StatusDetails statusDetails;
2247

2248
      /**
2249
       * For more details about Networks, please refer to the <a
2250
       * href="https://docs.stripe.com/api">API Reference.</a>
2251
       */
2252
      @Getter
2253
      @Setter
2254
      @EqualsAndHashCode(callSuper = false)
2255
      public static class Networks extends StripeObject {
×
2256
        /** The preferred network. */
2257
        @SerializedName("preferred")
2258
        String preferred;
2259

2260
        /** All supported networks. */
2261
        @SerializedName("supported")
2262
        List<String> supported;
2263
      }
2264

2265
      /**
2266
       * For more details about StatusDetails, please refer to the <a
2267
       * href="https://docs.stripe.com/api">API Reference.</a>
2268
       */
2269
      @Getter
2270
      @Setter
2271
      @EqualsAndHashCode(callSuper = false)
2272
      public static class StatusDetails extends StripeObject {
×
2273
        @SerializedName("blocked")
2274
        Blocked blocked;
2275

2276
        /**
2277
         * For more details about Blocked, please refer to the <a
2278
         * href="https://docs.stripe.com/api">API Reference.</a>
2279
         */
2280
        @Getter
2281
        @Setter
2282
        @EqualsAndHashCode(callSuper = false)
2283
        public static class Blocked extends StripeObject {
×
2284
          /**
2285
           * The ACH network code that resulted in this block.
2286
           *
2287
           * <p>One of {@code R02}, {@code R03}, {@code R04}, {@code R05}, {@code R07}, {@code R08},
2288
           * {@code R10}, {@code R11}, {@code R16}, {@code R20}, {@code R29}, or {@code R31}.
2289
           */
2290
          @SerializedName("network_code")
2291
          String networkCode;
2292

2293
          /**
2294
           * The reason why this PaymentMethod's fingerprint has been blocked
2295
           *
2296
           * <p>One of {@code bank_account_closed}, {@code bank_account_frozen}, {@code
2297
           * bank_account_invalid_details}, {@code bank_account_restricted}, {@code
2298
           * bank_account_unusable}, or {@code debit_not_authorized}.
2299
           */
2300
          @SerializedName("reason")
2301
          String reason;
2302
        }
2303
      }
2304
    }
2305

2306
    /**
2307
     * For more details about WechatPay, please refer to the <a
2308
     * href="https://docs.stripe.com/api">API Reference.</a>
2309
     */
2310
    @Getter
2311
    @Setter
2312
    @EqualsAndHashCode(callSuper = false)
2313
    public static class WechatPay extends StripeObject {}
×
2314

2315
    /**
2316
     * For more details about Zip, please refer to the <a href="https://docs.stripe.com/api">API
2317
     * Reference.</a>
2318
     */
2319
    @Getter
2320
    @Setter
2321
    @EqualsAndHashCode(callSuper = false)
2322
    public static class Zip extends StripeObject {}
×
2323
  }
2324

2325
  /**
2326
   * For more details about Shipping, please refer to the <a href="https://docs.stripe.com/api">API
2327
   * Reference.</a>
2328
   */
2329
  @Getter
2330
  @Setter
2331
  @EqualsAndHashCode(callSuper = false)
2332
  public static class Shipping extends StripeObject {
×
2333
    @SerializedName("address")
2334
    Address address;
2335

2336
    /** Recipient name. */
2337
    @SerializedName("name")
2338
    String name;
2339

2340
    /** Recipient phone (including extension). */
2341
    @SerializedName("phone")
2342
    String phone;
2343
  }
2344

2345
  public static class TestHelpers {
2346
    private TestHelpers() {}
2347

2348
    /** Creates a test mode Confirmation Token server side for your integration tests. */
2349
    public static ConfirmationToken create(Map<String, Object> params) throws StripeException {
2350
      return create(params, (RequestOptions) null);
×
2351
    }
2352

2353
    /** Creates a test mode Confirmation Token server side for your integration tests. */
2354
    public static ConfirmationToken create(Map<String, Object> params, RequestOptions options)
2355
        throws StripeException {
2356
      String path = "/v1/test_helpers/confirmation_tokens";
×
2357
      ApiRequest request =
×
2358
          new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.POST, path, params, options);
2359
      return getGlobalResponseGetter().request(request, ConfirmationToken.class);
×
2360
    }
2361

2362
    /** Creates a test mode Confirmation Token server side for your integration tests. */
2363
    public static ConfirmationToken create(ConfirmationTokenCreateParams params)
2364
        throws StripeException {
2365
      return create(params, (RequestOptions) null);
×
2366
    }
2367

2368
    /** Creates a test mode Confirmation Token server side for your integration tests. */
2369
    public static ConfirmationToken create(
2370
        ConfirmationTokenCreateParams params, RequestOptions options) throws StripeException {
2371
      String path = "/v1/test_helpers/confirmation_tokens";
×
2372
      ApiResource.checkNullTypedParams(path, params);
×
2373
      ApiRequest request =
×
2374
          new ApiRequest(
2375
              BaseAddress.API,
2376
              ApiResource.RequestMethod.POST,
2377
              path,
2378
              ApiRequestParams.paramsToMap(params),
×
2379
              options);
2380
      return getGlobalResponseGetter().request(request, ConfirmationToken.class);
×
2381
    }
2382
  }
2383

2384
  @Override
2385
  public void setResponseGetter(StripeResponseGetter responseGetter) {
2386
    super.setResponseGetter(responseGetter);
×
2387
    trySetResponseGetter(mandateData, responseGetter);
×
2388
    trySetResponseGetter(paymentMethodOptions, responseGetter);
×
2389
    trySetResponseGetter(paymentMethodPreview, responseGetter);
×
2390
    trySetResponseGetter(shipping, responseGetter);
×
2391
  }
×
2392
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2024 Coveralls, Inc