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

stripe / stripe-java / #16517

08 Oct 2024 06:27PM UTC coverage: 12.74% (-0.2%) from 12.899%
#16517

push

github

web-flow
Merge pull request #1872 from stripe/latest-codegen-beta

Update generated code for beta

53 of 2404 new or added lines in 50 files covered. (2.2%)

91 existing lines in 27 files now uncovered.

18753 of 147196 relevant lines covered (12.74%)

0.13 hits per line

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

15.49
/src/main/java/com/stripe/model/SetupAttempt.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.SetupAttemptListParams;
13
import java.util.List;
14
import java.util.Map;
15
import lombok.EqualsAndHashCode;
16
import lombok.Getter;
17
import lombok.Setter;
18

19
/**
20
 * A SetupAttempt describes one attempted confirmation of a SetupIntent, whether that confirmation
21
 * is successful or unsuccessful. You can use SetupAttempts to inspect details of a specific attempt
22
 * at setting up a payment method using a SetupIntent.
23
 */
24
@Getter
25
@Setter
26
@EqualsAndHashCode(callSuper = false)
27
public class SetupAttempt extends ApiResource implements HasId {
1✔
28
  /**
29
   * The value of <a
30
   * href="https://stripe.com/docs/api/setup_intents/object#setup_intent_object-application">application</a>
31
   * on the SetupIntent at the time of this confirmation.
32
   */
33
  @SerializedName("application")
34
  @Getter(lombok.AccessLevel.NONE)
35
  @Setter(lombok.AccessLevel.NONE)
36
  ExpandableField<Application> application;
37

38
  /**
39
   * If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
40
   *
41
   * <p>It can only be used for this Stripe Account’s own money movement flows like InboundTransfer
42
   * and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer,
43
   * and defaults to false when attaching a PaymentMethod to a Customer.
44
   */
45
  @SerializedName("attach_to_self")
46
  Boolean attachToSelf;
47

48
  /** Time at which the object was created. Measured in seconds since the Unix epoch. */
49
  @SerializedName("created")
50
  Long created;
51

52
  /**
53
   * The value of <a
54
   * href="https://stripe.com/docs/api/setup_intents/object#setup_intent_object-customer">customer</a>
55
   * on the SetupIntent at the time of this confirmation.
56
   */
57
  @SerializedName("customer")
58
  @Getter(lombok.AccessLevel.NONE)
59
  @Setter(lombok.AccessLevel.NONE)
60
  ExpandableField<Customer> customer;
61

62
  /**
63
   * Indicates the directions of money movement for which this payment method is intended to be
64
   * used.
65
   *
66
   * <p>Include {@code inbound} if you intend to use the payment method as the origin to pull funds
67
   * from. Include {@code outbound} if you intend to use the payment method as the destination to
68
   * send funds to. You can include both if you intend to use the payment method for both purposes.
69
   */
70
  @SerializedName("flow_directions")
71
  List<String> flowDirections;
72

73
  /** Unique identifier for the object. */
74
  @Getter(onMethod_ = {@Override})
75
  @SerializedName("id")
76
  String id;
77

78
  /**
79
   * Has the value {@code true} if the object exists in live mode or the value {@code false} if the
80
   * object exists in test mode.
81
   */
82
  @SerializedName("livemode")
83
  Boolean livemode;
84

85
  /**
86
   * String representing the object's type. Objects of the same type share the same value.
87
   *
88
   * <p>Equal to {@code setup_attempt}.
89
   */
90
  @SerializedName("object")
91
  String object;
92

93
  /**
94
   * The value of <a
95
   * href="https://stripe.com/docs/api/setup_intents/object#setup_intent_object-on_behalf_of">on_behalf_of</a>
96
   * on the SetupIntent at the time of this confirmation.
97
   */
98
  @SerializedName("on_behalf_of")
99
  @Getter(lombok.AccessLevel.NONE)
100
  @Setter(lombok.AccessLevel.NONE)
101
  ExpandableField<Account> onBehalfOf;
102

103
  /** ID of the payment method used with this SetupAttempt. */
104
  @SerializedName("payment_method")
105
  @Getter(lombok.AccessLevel.NONE)
106
  @Setter(lombok.AccessLevel.NONE)
107
  ExpandableField<PaymentMethod> paymentMethod;
108

109
  @SerializedName("payment_method_details")
110
  PaymentMethodDetails paymentMethodDetails;
111

112
  /** The error encountered during this attempt to confirm the SetupIntent, if any. */
113
  @SerializedName("setup_error")
114
  StripeError setupError;
115

116
  /** ID of the SetupIntent that this attempt belongs to. */
117
  @SerializedName("setup_intent")
118
  @Getter(lombok.AccessLevel.NONE)
119
  @Setter(lombok.AccessLevel.NONE)
120
  ExpandableField<SetupIntent> setupIntent;
121

122
  /**
123
   * Status of this SetupAttempt, one of {@code requires_confirmation}, {@code requires_action},
124
   * {@code processing}, {@code succeeded}, {@code failed}, or {@code abandoned}.
125
   */
126
  @SerializedName("status")
127
  String status;
128

129
  /**
130
   * The value of <a
131
   * href="https://stripe.com/docs/api/setup_intents/object#setup_intent_object-usage">usage</a> on
132
   * the SetupIntent at the time of this confirmation, one of {@code off_session} or {@code
133
   * on_session}.
134
   */
135
  @SerializedName("usage")
136
  String usage;
137

138
  /** Get ID of expandable {@code application} object. */
139
  public String getApplication() {
140
    return (this.application != null) ? this.application.getId() : null;
×
141
  }
142

143
  public void setApplication(String id) {
144
    this.application = ApiResource.setExpandableFieldId(id, this.application);
×
145
  }
×
146

147
  /** Get expanded {@code application}. */
148
  public Application getApplicationObject() {
149
    return (this.application != null) ? this.application.getExpanded() : null;
×
150
  }
151

152
  public void setApplicationObject(Application expandableObject) {
153
    this.application = new ExpandableField<Application>(expandableObject.getId(), expandableObject);
×
154
  }
×
155

156
  /** Get ID of expandable {@code customer} object. */
157
  public String getCustomer() {
158
    return (this.customer != null) ? this.customer.getId() : null;
×
159
  }
160

161
  public void setCustomer(String id) {
162
    this.customer = ApiResource.setExpandableFieldId(id, this.customer);
×
163
  }
×
164

165
  /** Get expanded {@code customer}. */
166
  public Customer getCustomerObject() {
167
    return (this.customer != null) ? this.customer.getExpanded() : null;
×
168
  }
169

170
  public void setCustomerObject(Customer expandableObject) {
171
    this.customer = new ExpandableField<Customer>(expandableObject.getId(), expandableObject);
×
172
  }
×
173

174
  /** Get ID of expandable {@code onBehalfOf} object. */
175
  public String getOnBehalfOf() {
176
    return (this.onBehalfOf != null) ? this.onBehalfOf.getId() : null;
×
177
  }
178

179
  public void setOnBehalfOf(String id) {
180
    this.onBehalfOf = ApiResource.setExpandableFieldId(id, this.onBehalfOf);
×
181
  }
×
182

183
  /** Get expanded {@code onBehalfOf}. */
184
  public Account getOnBehalfOfObject() {
185
    return (this.onBehalfOf != null) ? this.onBehalfOf.getExpanded() : null;
×
186
  }
187

188
  public void setOnBehalfOfObject(Account expandableObject) {
189
    this.onBehalfOf = new ExpandableField<Account>(expandableObject.getId(), expandableObject);
×
190
  }
×
191

192
  /** Get ID of expandable {@code paymentMethod} object. */
193
  public String getPaymentMethod() {
194
    return (this.paymentMethod != null) ? this.paymentMethod.getId() : null;
×
195
  }
196

197
  public void setPaymentMethod(String id) {
198
    this.paymentMethod = ApiResource.setExpandableFieldId(id, this.paymentMethod);
×
199
  }
×
200

201
  /** Get expanded {@code paymentMethod}. */
202
  public PaymentMethod getPaymentMethodObject() {
203
    return (this.paymentMethod != null) ? this.paymentMethod.getExpanded() : null;
×
204
  }
205

206
  public void setPaymentMethodObject(PaymentMethod expandableObject) {
207
    this.paymentMethod =
×
208
        new ExpandableField<PaymentMethod>(expandableObject.getId(), expandableObject);
×
209
  }
×
210

211
  /** Get ID of expandable {@code setupIntent} object. */
212
  public String getSetupIntent() {
213
    return (this.setupIntent != null) ? this.setupIntent.getId() : null;
×
214
  }
215

216
  public void setSetupIntent(String id) {
217
    this.setupIntent = ApiResource.setExpandableFieldId(id, this.setupIntent);
×
218
  }
×
219

220
  /** Get expanded {@code setupIntent}. */
221
  public SetupIntent getSetupIntentObject() {
222
    return (this.setupIntent != null) ? this.setupIntent.getExpanded() : null;
×
223
  }
224

225
  public void setSetupIntentObject(SetupIntent expandableObject) {
226
    this.setupIntent = new ExpandableField<SetupIntent>(expandableObject.getId(), expandableObject);
×
227
  }
×
228

229
  /** Returns a list of SetupAttempts that associate with a provided SetupIntent. */
230
  public static SetupAttemptCollection list(Map<String, Object> params) throws StripeException {
231
    return list(params, (RequestOptions) null);
1✔
232
  }
233

234
  /** Returns a list of SetupAttempts that associate with a provided SetupIntent. */
235
  public static SetupAttemptCollection list(Map<String, Object> params, RequestOptions options)
236
      throws StripeException {
237
    String path = "/v1/setup_attempts";
1✔
238
    ApiRequest request =
1✔
239
        new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.GET, path, params, options);
240
    return getGlobalResponseGetter().request(request, SetupAttemptCollection.class);
1✔
241
  }
242

243
  /** Returns a list of SetupAttempts that associate with a provided SetupIntent. */
244
  public static SetupAttemptCollection list(SetupAttemptListParams params) throws StripeException {
245
    return list(params, (RequestOptions) null);
1✔
246
  }
247

248
  /** Returns a list of SetupAttempts that associate with a provided SetupIntent. */
249
  public static SetupAttemptCollection list(SetupAttemptListParams params, RequestOptions options)
250
      throws StripeException {
251
    String path = "/v1/setup_attempts";
1✔
252
    ApiResource.checkNullTypedParams(path, params);
1✔
253
    ApiRequest request =
1✔
254
        new ApiRequest(
255
            BaseAddress.API,
256
            ApiResource.RequestMethod.GET,
257
            path,
258
            ApiRequestParams.paramsToMap(params),
1✔
259
            options);
260
    return getGlobalResponseGetter().request(request, SetupAttemptCollection.class);
1✔
261
  }
262

263
  @Getter
264
  @Setter
265
  @EqualsAndHashCode(callSuper = false)
266
  public static class PaymentMethodDetails extends StripeObject {
1✔
267
    @SerializedName("acss_debit")
268
    AcssDebit acssDebit;
269

270
    @SerializedName("amazon_pay")
271
    AmazonPay amazonPay;
272

273
    @SerializedName("au_becs_debit")
274
    AuBecsDebit auBecsDebit;
275

276
    @SerializedName("bacs_debit")
277
    BacsDebit bacsDebit;
278

279
    @SerializedName("bancontact")
280
    Bancontact bancontact;
281

282
    @SerializedName("boleto")
283
    Boleto boleto;
284

285
    @SerializedName("card")
286
    Card card;
287

288
    @SerializedName("card_present")
289
    CardPresent cardPresent;
290

291
    @SerializedName("cashapp")
292
    Cashapp cashapp;
293

294
    @SerializedName("ideal")
295
    Ideal ideal;
296

297
    @SerializedName("kakao_pay")
298
    KakaoPay kakaoPay;
299

300
    @SerializedName("klarna")
301
    Klarna klarna;
302

303
    @SerializedName("kr_card")
304
    KrCard krCard;
305

306
    @SerializedName("link")
307
    Link link;
308

309
    @SerializedName("paypal")
310
    Paypal paypal;
311

312
    @SerializedName("payto")
313
    Payto payto;
314

315
    @SerializedName("revolut_pay")
316
    RevolutPay revolutPay;
317

318
    @SerializedName("sepa_debit")
319
    SepaDebit sepaDebit;
320

321
    @SerializedName("sofort")
322
    Sofort sofort;
323

324
    /**
325
     * The type of the payment method used in the SetupIntent (e.g., {@code card}). An additional
326
     * hash is included on {@code payment_method_details} with a name matching this value. It
327
     * contains confirmation-specific information for the payment method.
328
     */
329
    @SerializedName("type")
330
    String type;
331

332
    @SerializedName("us_bank_account")
333
    UsBankAccount usBankAccount;
334

335
    @Getter
336
    @Setter
337
    @EqualsAndHashCode(callSuper = false)
338
    public static class AcssDebit extends StripeObject {}
×
339

340
    @Getter
341
    @Setter
342
    @EqualsAndHashCode(callSuper = false)
343
    public static class AmazonPay extends StripeObject {}
×
344

345
    @Getter
346
    @Setter
347
    @EqualsAndHashCode(callSuper = false)
348
    public static class AuBecsDebit extends StripeObject {}
×
349

350
    @Getter
351
    @Setter
352
    @EqualsAndHashCode(callSuper = false)
353
    public static class BacsDebit extends StripeObject {}
×
354

355
    @Getter
356
    @Setter
357
    @EqualsAndHashCode(callSuper = false)
358
    public static class Bancontact extends StripeObject {
×
359
      /** Bank code of bank associated with the bank account. */
360
      @SerializedName("bank_code")
361
      String bankCode;
362

363
      /** Name of the bank associated with the bank account. */
364
      @SerializedName("bank_name")
365
      String bankName;
366

367
      /** Bank Identifier Code of the bank associated with the bank account. */
368
      @SerializedName("bic")
369
      String bic;
370

371
      /** The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt. */
372
      @SerializedName("generated_sepa_debit")
373
      @Getter(lombok.AccessLevel.NONE)
374
      @Setter(lombok.AccessLevel.NONE)
375
      ExpandableField<PaymentMethod> generatedSepaDebit;
376

377
      /**
378
       * The mandate for the SEPA Direct Debit PaymentMethod which was generated by this
379
       * SetupAttempt.
380
       */
381
      @SerializedName("generated_sepa_debit_mandate")
382
      @Getter(lombok.AccessLevel.NONE)
383
      @Setter(lombok.AccessLevel.NONE)
384
      ExpandableField<Mandate> generatedSepaDebitMandate;
385

386
      /** Last four characters of the IBAN. */
387
      @SerializedName("iban_last4")
388
      String ibanLast4;
389

390
      /**
391
       * Preferred language of the Bancontact authorization page that the customer is redirected to.
392
       * Can be one of {@code en}, {@code de}, {@code fr}, or {@code nl}
393
       */
394
      @SerializedName("preferred_language")
395
      String preferredLanguage;
396

397
      /**
398
       * Owner's verified full name. Values are verified or provided by Bancontact directly (if
399
       * supported) at the time of authorization or settlement. They cannot be set or mutated.
400
       */
401
      @SerializedName("verified_name")
402
      String verifiedName;
403

404
      /** Get ID of expandable {@code generatedSepaDebit} object. */
405
      public String getGeneratedSepaDebit() {
406
        return (this.generatedSepaDebit != null) ? this.generatedSepaDebit.getId() : null;
×
407
      }
408

409
      public void setGeneratedSepaDebit(String id) {
410
        this.generatedSepaDebit = ApiResource.setExpandableFieldId(id, this.generatedSepaDebit);
×
411
      }
×
412

413
      /** Get expanded {@code generatedSepaDebit}. */
414
      public PaymentMethod getGeneratedSepaDebitObject() {
415
        return (this.generatedSepaDebit != null) ? this.generatedSepaDebit.getExpanded() : null;
×
416
      }
417

418
      public void setGeneratedSepaDebitObject(PaymentMethod expandableObject) {
419
        this.generatedSepaDebit =
×
420
            new ExpandableField<PaymentMethod>(expandableObject.getId(), expandableObject);
×
421
      }
×
422

423
      /** Get ID of expandable {@code generatedSepaDebitMandate} object. */
424
      public String getGeneratedSepaDebitMandate() {
425
        return (this.generatedSepaDebitMandate != null)
×
426
            ? this.generatedSepaDebitMandate.getId()
×
427
            : null;
×
428
      }
429

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

435
      /** Get expanded {@code generatedSepaDebitMandate}. */
436
      public Mandate getGeneratedSepaDebitMandateObject() {
437
        return (this.generatedSepaDebitMandate != null)
×
438
            ? this.generatedSepaDebitMandate.getExpanded()
×
439
            : null;
×
440
      }
441

442
      public void setGeneratedSepaDebitMandateObject(Mandate expandableObject) {
443
        this.generatedSepaDebitMandate =
×
444
            new ExpandableField<Mandate>(expandableObject.getId(), expandableObject);
×
445
      }
×
446
    }
447

448
    @Getter
449
    @Setter
450
    @EqualsAndHashCode(callSuper = false)
451
    public static class Boleto extends StripeObject {}
×
452

453
    @Getter
454
    @Setter
455
    @EqualsAndHashCode(callSuper = false)
456
    public static class Card extends StripeObject {
1✔
457
      /**
458
       * Card brand. Can be {@code amex}, {@code diners}, {@code discover}, {@code eftpos_au},
459
       * {@code jcb}, {@code mastercard}, {@code unionpay}, {@code visa}, or {@code unknown}.
460
       */
461
      @SerializedName("brand")
462
      String brand;
463

464
      /** Check results by Card networks on Card address and CVC at the time of authorization. */
465
      @SerializedName("checks")
466
      Checks checks;
467

468
      /**
469
       * Two-letter ISO code representing the country of the card. You could use this attribute to
470
       * get a sense of the international breakdown of cards you've collected.
471
       */
472
      @SerializedName("country")
473
      String country;
474

475
      /**
476
       * A high-level description of the type of cards issued in this range. (For internal use only
477
       * and not typically available in standard API requests.)
478
       */
479
      @SerializedName("description")
480
      String description;
481

482
      /** Two-digit number representing the card's expiration month. */
483
      @SerializedName("exp_month")
484
      Long expMonth;
485

486
      /** Four-digit number representing the card's expiration year. */
487
      @SerializedName("exp_year")
488
      Long expYear;
489

490
      /**
491
       * Uniquely identifies this particular card number. You can use this attribute to check
492
       * whether two customers who’ve signed up with you are using the same card number, for
493
       * example. For payment methods that tokenize card information (Apple Pay, Google Pay), the
494
       * tokenized number might be provided instead of the underlying card number.
495
       *
496
       * <p><em>As of May 1, 2021, card fingerprint in India for Connect changed to allow two
497
       * fingerprints for the same card---one for India and one for the rest of the world.</em>
498
       */
499
      @SerializedName("fingerprint")
500
      String fingerprint;
501

502
      /**
503
       * Card funding type. Can be {@code credit}, {@code debit}, {@code prepaid}, or {@code
504
       * unknown}.
505
       */
506
      @SerializedName("funding")
507
      String funding;
508

509
      /**
510
       * Issuer identification number of the card. (For internal use only and not typically
511
       * available in standard API requests.)
512
       */
513
      @SerializedName("iin")
514
      String iin;
515

516
      /**
517
       * The name of the card's issuing bank. (For internal use only and not typically available in
518
       * standard API requests.)
519
       */
520
      @SerializedName("issuer")
521
      String issuer;
522

523
      /** The last four digits of the card. */
524
      @SerializedName("last4")
525
      String last4;
526

527
      /**
528
       * Identifies which network this charge was processed on. Can be {@code amex}, {@code
529
       * cartes_bancaires}, {@code diners}, {@code discover}, {@code eftpos_au}, {@code interac},
530
       * {@code jcb}, {@code mastercard}, {@code unionpay}, {@code visa}, or {@code unknown}.
531
       */
532
      @SerializedName("network")
533
      String network;
534

535
      /** Populated if this authorization used 3D Secure authentication. */
536
      @SerializedName("three_d_secure")
537
      ThreeDSecure threeDSecure;
538

539
      /** If this Card is part of a card wallet, this contains the details of the card wallet. */
540
      @SerializedName("wallet")
541
      Wallet wallet;
542

543
      @Getter
544
      @Setter
545
      @EqualsAndHashCode(callSuper = false)
546
      public static class Checks extends StripeObject {
×
547
        /**
548
         * If a address line1 was provided, results of the check, one of {@code pass}, {@code fail},
549
         * {@code unavailable}, or {@code unchecked}.
550
         */
551
        @SerializedName("address_line1_check")
552
        String addressLine1Check;
553

554
        /**
555
         * If a address postal code was provided, results of the check, one of {@code pass}, {@code
556
         * fail}, {@code unavailable}, or {@code unchecked}.
557
         */
558
        @SerializedName("address_postal_code_check")
559
        String addressPostalCodeCheck;
560

561
        /**
562
         * If a CVC was provided, results of the check, one of {@code pass}, {@code fail}, {@code
563
         * unavailable}, or {@code unchecked}.
564
         */
565
        @SerializedName("cvc_check")
566
        String cvcCheck;
567
      }
568

569
      @Getter
570
      @Setter
571
      @EqualsAndHashCode(callSuper = false)
572
      public static class ThreeDSecure extends StripeObject {
×
573
        /**
574
         * For authenticated transactions: how the customer was authenticated by the issuing bank.
575
         *
576
         * <p>One of {@code challenge}, or {@code frictionless}.
577
         */
578
        @SerializedName("authentication_flow")
579
        String authenticationFlow;
580

581
        /**
582
         * The Electronic Commerce Indicator (ECI). A protocol-level field indicating what degree of
583
         * authentication was performed.
584
         *
585
         * <p>One of {@code 01}, {@code 02}, {@code 05}, {@code 06}, or {@code 07}.
586
         */
587
        @SerializedName("electronic_commerce_indicator")
588
        String electronicCommerceIndicator;
589

590
        /**
591
         * Indicates the outcome of 3D Secure authentication.
592
         *
593
         * <p>One of {@code attempt_acknowledged}, {@code authenticated}, {@code exempted}, {@code
594
         * failed}, {@code not_supported}, or {@code processing_error}.
595
         */
596
        @SerializedName("result")
597
        String result;
598

599
        /**
600
         * Additional information about why 3D Secure succeeded or failed based on the {@code
601
         * result}.
602
         *
603
         * <p>One of {@code abandoned}, {@code bypassed}, {@code canceled}, {@code
604
         * card_not_enrolled}, {@code network_not_supported}, {@code protocol_error}, or {@code
605
         * rejected}.
606
         */
607
        @SerializedName("result_reason")
608
        String resultReason;
609

610
        /**
611
         * The 3D Secure 1 XID or 3D Secure 2 Directory Server Transaction ID (dsTransId) for this
612
         * payment.
613
         */
614
        @SerializedName("transaction_id")
615
        String transactionId;
616

617
        /**
618
         * The version of 3D Secure that was used.
619
         *
620
         * <p>One of {@code 1.0.2}, {@code 2.1.0}, or {@code 2.2.0}.
621
         */
622
        @SerializedName("version")
623
        String version;
624
      }
625

626
      @Getter
627
      @Setter
628
      @EqualsAndHashCode(callSuper = false)
629
      public static class Wallet extends StripeObject {
×
630
        @SerializedName("apple_pay")
631
        ApplePay applePay;
632

633
        @SerializedName("google_pay")
634
        GooglePay googlePay;
635

636
        /**
637
         * The type of the card wallet, one of {@code apple_pay}, {@code google_pay}, or {@code
638
         * link}. An additional hash is included on the Wallet subhash with a name matching this
639
         * value. It contains additional information specific to the card wallet type.
640
         */
641
        @SerializedName("type")
642
        String type;
643

644
        @Getter
645
        @Setter
646
        @EqualsAndHashCode(callSuper = false)
647
        public static class ApplePay extends StripeObject {}
×
648

649
        @Getter
650
        @Setter
651
        @EqualsAndHashCode(callSuper = false)
652
        public static class GooglePay extends StripeObject {}
×
653
      }
654
    }
655

656
    @Getter
657
    @Setter
658
    @EqualsAndHashCode(callSuper = false)
659
    public static class CardPresent extends StripeObject {
×
660
      /** The ID of the Card PaymentMethod which was generated by this SetupAttempt. */
661
      @SerializedName("generated_card")
662
      @Getter(lombok.AccessLevel.NONE)
663
      @Setter(lombok.AccessLevel.NONE)
664
      ExpandableField<PaymentMethod> generatedCard;
665

666
      /** Details about payments collected offline. */
667
      @SerializedName("offline")
668
      Offline offline;
669

670
      /** Get ID of expandable {@code generatedCard} object. */
671
      public String getGeneratedCard() {
672
        return (this.generatedCard != null) ? this.generatedCard.getId() : null;
×
673
      }
674

675
      public void setGeneratedCard(String id) {
676
        this.generatedCard = ApiResource.setExpandableFieldId(id, this.generatedCard);
×
677
      }
×
678

679
      /** Get expanded {@code generatedCard}. */
680
      public PaymentMethod getGeneratedCardObject() {
681
        return (this.generatedCard != null) ? this.generatedCard.getExpanded() : null;
×
682
      }
683

684
      public void setGeneratedCardObject(PaymentMethod expandableObject) {
685
        this.generatedCard =
×
686
            new ExpandableField<PaymentMethod>(expandableObject.getId(), expandableObject);
×
687
      }
×
688

689
      @Getter
690
      @Setter
691
      @EqualsAndHashCode(callSuper = false)
692
      public static class Offline extends StripeObject {
×
693
        /** Time at which the payment was collected while offline. */
694
        @SerializedName("stored_at")
695
        Long storedAt;
696

697
        /**
698
         * The method used to process this payment method offline. Only deferred is allowed.
699
         *
700
         * <p>Equal to {@code deferred}.
701
         */
702
        @SerializedName("type")
703
        String type;
704
      }
705
    }
706

707
    @Getter
708
    @Setter
709
    @EqualsAndHashCode(callSuper = false)
710
    public static class Cashapp extends StripeObject {}
×
711

712
    @Getter
713
    @Setter
714
    @EqualsAndHashCode(callSuper = false)
715
    public static class Ideal extends StripeObject {
×
716
      /**
717
       * The customer's bank. Can be one of {@code abn_amro}, {@code asn_bank}, {@code bunq}, {@code
718
       * handelsbanken}, {@code ing}, {@code knab}, {@code moneyou}, {@code n26}, {@code nn}, {@code
719
       * rabobank}, {@code regiobank}, {@code revolut}, {@code sns_bank}, {@code triodos_bank},
720
       * {@code van_lanschot}, or {@code yoursafe}.
721
       */
722
      @SerializedName("bank")
723
      String bank;
724

725
      /**
726
       * The Bank Identifier Code of the customer's bank.
727
       *
728
       * <p>One of {@code ABNANL2A}, {@code ASNBNL21}, {@code BITSNL2A}, {@code BUNQNL2A}, {@code
729
       * FVLBNL22}, {@code HANDNL2A}, {@code INGBNL2A}, {@code KNABNL2H}, {@code MOYONL21}, {@code
730
       * NNBANL2G}, {@code NTSBDEB1}, {@code RABONL2U}, {@code RBRBNL21}, {@code REVOIE23}, {@code
731
       * REVOLT21}, {@code SNSBNL2A}, or {@code TRIONL2U}.
732
       */
733
      @SerializedName("bic")
734
      String bic;
735

736
      /** The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt. */
737
      @SerializedName("generated_sepa_debit")
738
      @Getter(lombok.AccessLevel.NONE)
739
      @Setter(lombok.AccessLevel.NONE)
740
      ExpandableField<PaymentMethod> generatedSepaDebit;
741

742
      /**
743
       * The mandate for the SEPA Direct Debit PaymentMethod which was generated by this
744
       * SetupAttempt.
745
       */
746
      @SerializedName("generated_sepa_debit_mandate")
747
      @Getter(lombok.AccessLevel.NONE)
748
      @Setter(lombok.AccessLevel.NONE)
749
      ExpandableField<Mandate> generatedSepaDebitMandate;
750

751
      /** Last four characters of the IBAN. */
752
      @SerializedName("iban_last4")
753
      String ibanLast4;
754

755
      /**
756
       * Owner's verified full name. Values are verified or provided by iDEAL directly (if
757
       * supported) at the time of authorization or settlement. They cannot be set or mutated.
758
       */
759
      @SerializedName("verified_name")
760
      String verifiedName;
761

762
      /** Get ID of expandable {@code generatedSepaDebit} object. */
763
      public String getGeneratedSepaDebit() {
764
        return (this.generatedSepaDebit != null) ? this.generatedSepaDebit.getId() : null;
×
765
      }
766

767
      public void setGeneratedSepaDebit(String id) {
768
        this.generatedSepaDebit = ApiResource.setExpandableFieldId(id, this.generatedSepaDebit);
×
769
      }
×
770

771
      /** Get expanded {@code generatedSepaDebit}. */
772
      public PaymentMethod getGeneratedSepaDebitObject() {
773
        return (this.generatedSepaDebit != null) ? this.generatedSepaDebit.getExpanded() : null;
×
774
      }
775

776
      public void setGeneratedSepaDebitObject(PaymentMethod expandableObject) {
777
        this.generatedSepaDebit =
×
778
            new ExpandableField<PaymentMethod>(expandableObject.getId(), expandableObject);
×
779
      }
×
780

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

788
      public void setGeneratedSepaDebitMandate(String id) {
789
        this.generatedSepaDebitMandate =
×
790
            ApiResource.setExpandableFieldId(id, this.generatedSepaDebitMandate);
×
791
      }
×
792

793
      /** Get expanded {@code generatedSepaDebitMandate}. */
794
      public Mandate getGeneratedSepaDebitMandateObject() {
795
        return (this.generatedSepaDebitMandate != null)
×
796
            ? this.generatedSepaDebitMandate.getExpanded()
×
797
            : null;
×
798
      }
799

800
      public void setGeneratedSepaDebitMandateObject(Mandate expandableObject) {
801
        this.generatedSepaDebitMandate =
×
802
            new ExpandableField<Mandate>(expandableObject.getId(), expandableObject);
×
803
      }
×
804
    }
805

806
    @Getter
807
    @Setter
808
    @EqualsAndHashCode(callSuper = false)
NEW
809
    public static class KakaoPay extends StripeObject {}
×
810

811
    @Getter
812
    @Setter
813
    @EqualsAndHashCode(callSuper = false)
814
    public static class Klarna extends StripeObject {}
×
815

816
    @Getter
817
    @Setter
818
    @EqualsAndHashCode(callSuper = false)
NEW
819
    public static class KrCard extends StripeObject {}
×
820

821
    @Getter
822
    @Setter
823
    @EqualsAndHashCode(callSuper = false)
824
    public static class Link extends StripeObject {}
×
825

826
    @Getter
827
    @Setter
828
    @EqualsAndHashCode(callSuper = false)
829
    public static class Paypal extends StripeObject {}
×
830

831
    @Getter
832
    @Setter
833
    @EqualsAndHashCode(callSuper = false)
834
    public static class Payto extends StripeObject {}
×
835

836
    @Getter
837
    @Setter
838
    @EqualsAndHashCode(callSuper = false)
839
    public static class RevolutPay extends StripeObject {}
×
840

841
    @Getter
842
    @Setter
843
    @EqualsAndHashCode(callSuper = false)
844
    public static class SepaDebit extends StripeObject {}
×
845

846
    @Getter
847
    @Setter
848
    @EqualsAndHashCode(callSuper = false)
849
    public static class Sofort extends StripeObject {
×
850
      /** Bank code of bank associated with the bank account. */
851
      @SerializedName("bank_code")
852
      String bankCode;
853

854
      /** Name of the bank associated with the bank account. */
855
      @SerializedName("bank_name")
856
      String bankName;
857

858
      /** Bank Identifier Code of the bank associated with the bank account. */
859
      @SerializedName("bic")
860
      String bic;
861

862
      /** The ID of the SEPA Direct Debit PaymentMethod which was generated by this SetupAttempt. */
863
      @SerializedName("generated_sepa_debit")
864
      @Getter(lombok.AccessLevel.NONE)
865
      @Setter(lombok.AccessLevel.NONE)
866
      ExpandableField<PaymentMethod> generatedSepaDebit;
867

868
      /**
869
       * The mandate for the SEPA Direct Debit PaymentMethod which was generated by this
870
       * SetupAttempt.
871
       */
872
      @SerializedName("generated_sepa_debit_mandate")
873
      @Getter(lombok.AccessLevel.NONE)
874
      @Setter(lombok.AccessLevel.NONE)
875
      ExpandableField<Mandate> generatedSepaDebitMandate;
876

877
      /** Last four characters of the IBAN. */
878
      @SerializedName("iban_last4")
879
      String ibanLast4;
880

881
      /**
882
       * Preferred language of the Sofort authorization page that the customer is redirected to. Can
883
       * be one of {@code en}, {@code de}, {@code fr}, or {@code nl}
884
       */
885
      @SerializedName("preferred_language")
886
      String preferredLanguage;
887

888
      /**
889
       * Owner's verified full name. Values are verified or provided by Sofort directly (if
890
       * supported) at the time of authorization or settlement. They cannot be set or mutated.
891
       */
892
      @SerializedName("verified_name")
893
      String verifiedName;
894

895
      /** Get ID of expandable {@code generatedSepaDebit} object. */
896
      public String getGeneratedSepaDebit() {
897
        return (this.generatedSepaDebit != null) ? this.generatedSepaDebit.getId() : null;
×
898
      }
899

900
      public void setGeneratedSepaDebit(String id) {
901
        this.generatedSepaDebit = ApiResource.setExpandableFieldId(id, this.generatedSepaDebit);
×
902
      }
×
903

904
      /** Get expanded {@code generatedSepaDebit}. */
905
      public PaymentMethod getGeneratedSepaDebitObject() {
906
        return (this.generatedSepaDebit != null) ? this.generatedSepaDebit.getExpanded() : null;
×
907
      }
908

909
      public void setGeneratedSepaDebitObject(PaymentMethod expandableObject) {
910
        this.generatedSepaDebit =
×
911
            new ExpandableField<PaymentMethod>(expandableObject.getId(), expandableObject);
×
912
      }
×
913

914
      /** Get ID of expandable {@code generatedSepaDebitMandate} object. */
915
      public String getGeneratedSepaDebitMandate() {
916
        return (this.generatedSepaDebitMandate != null)
×
917
            ? this.generatedSepaDebitMandate.getId()
×
918
            : null;
×
919
      }
920

921
      public void setGeneratedSepaDebitMandate(String id) {
922
        this.generatedSepaDebitMandate =
×
923
            ApiResource.setExpandableFieldId(id, this.generatedSepaDebitMandate);
×
924
      }
×
925

926
      /** Get expanded {@code generatedSepaDebitMandate}. */
927
      public Mandate getGeneratedSepaDebitMandateObject() {
928
        return (this.generatedSepaDebitMandate != null)
×
929
            ? this.generatedSepaDebitMandate.getExpanded()
×
930
            : null;
×
931
      }
932

933
      public void setGeneratedSepaDebitMandateObject(Mandate expandableObject) {
934
        this.generatedSepaDebitMandate =
×
935
            new ExpandableField<Mandate>(expandableObject.getId(), expandableObject);
×
936
      }
×
937
    }
938

939
    @Getter
940
    @Setter
941
    @EqualsAndHashCode(callSuper = false)
942
    public static class UsBankAccount extends StripeObject {}
×
943
  }
944

945
  @Override
946
  public void setResponseGetter(StripeResponseGetter responseGetter) {
947
    super.setResponseGetter(responseGetter);
1✔
948
    trySetResponseGetter(application, responseGetter);
1✔
949
    trySetResponseGetter(customer, responseGetter);
1✔
950
    trySetResponseGetter(onBehalfOf, responseGetter);
1✔
951
    trySetResponseGetter(paymentMethod, responseGetter);
1✔
952
    trySetResponseGetter(paymentMethodDetails, responseGetter);
1✔
953
    trySetResponseGetter(setupError, responseGetter);
1✔
954
    trySetResponseGetter(setupIntent, responseGetter);
1✔
955
  }
1✔
956
}
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

© 2026 Coveralls, Inc